×ðÁú¿­Ê±¹ÙÍøµÇ¼

Ã÷È·Linux ldconfigµÄ×÷ÓÃ

Linux ldconfigµÄ×÷Óü°´úÂëʾÀý

ÔÚLinuxϵͳÖУ¬¶¯Ì¬Á´½Ó¿â£¨Dynamic Link Library£¬¼ò³Æ¶¯Ì¬¿â£©ÊÇÒ»¸ö¹²ÏíµÄ¡¢¿ÉÖØÓõĿâÎļþ£¬¿ÉÒÔ±»Ó¦ÓóÌÐòÔÚÔËÐÐʱ¼ÓÔز¢Å²ÓÃÆäÖеĺ¯Êý¡£ÎªÁËʹϵͳÄܹ»×¼È·µØÕÒµ½²¢¼ÓÔØÕâЩ¶¯Ì¬¿â£¬LinuxÌṩÁËldconfig¹¤¾ßÀ´ÖÎÀíϵͳÖеĶ¯Ì¬Á´½Ó¿âÎļþ¡£

ldconfigÊÇLinuxϵͳÖÐÓÃÓÚ¸üж¯Ì¬Á´½Ó¿â»º´æµÄÏÂÁÆä×÷ÓÃÖ÷Òª°üÀ¨£º

¸üж¯Ì¬Á´½Ó¿â»º´æ£ºldconfig¿ÉÒÔ¼ì²éϵͳÖеĶ¯Ì¬Á´½Ó¿âÎļþ£¬²¢¸üÐÂϵͳµÄ¶¯Ì¬Á´½Ó¿â»º´æÎļþ£¬Ê¹ÏµÍ³ÔÚ¼ÓÔض¯Ì¬¿âʱÄܹ»ÕÒµ½×¼È·µÄ·¾¶¡£

½â¾ö¶¯Ì¬¿âµÄÒÀÀµ¹Øϵ£ºldconfig»áƾ֤¶¯Ì¬¿âÎļþÖеÄÒÀÀµ¹Øϵ£¬×¼È·µØ½¨Éè¿âÎļþÖ®¼äµÄÁ´½Ó¹Øϵ£¬È·±£³ÌÐòÄܹ»×¼È·µØŲÓÃÏà¹Ø¿âÎļþ¡£

ÏÂÃæÊÇÒ»¸öÏêϸµÄ´úÂëʾÀý£¬ÑÝʾÔõÑùʹÓÃldconfigÏÂÁîÀ´¸üÐÂϵͳµÄ¶¯Ì¬Á´½Ó¿â»º´æ£º

¼ÙÉèÎÒÃÇÓÐÒ»¸ö¶¯Ì¬Á´½Ó¿âÎļþlibexample.so£¬´æ·ÅÔÚĿ¼/usr/local/libÖС£

Ê×ÏÈ£¬ÎÒÃÇ¿ÉÒÔ½«¸Ã¶¯Ì¬Á´½Ó¿âÎļþµÄ·¾¶Ìí¼Óµ½/etc/ld.so.confÎļþÖУ¬ÕâÑùldconfigÔÚ¸üлº´æʱ»á¼ì²éÕâ¸öĿ¼£º

echo "/usr/local/lib" >> /etc/ld.so.conf

µÇ¼ºó¸´ÖÆ

È»ºó£¬ÔËÐÐldconfigÏÂÁîÀ´¸üÐÂϵͳµÄ¶¯Ì¬Á´½Ó¿â»º´æ£º

sudo ldconfig

µÇ¼ºó¸´ÖÆ

ͨ¹ýÉÏÊö²Ù×÷£¬ÏµÍ³½«»á¸üж¯Ì¬Á´½Ó¿â»º´æ£¬Ê¹ÏµÍ³Äܹ»×¼È·µØ¼ÓÔØlibexample.soÎļþ¡£

×ÜÖ®£¬Ã÷È·LinuxÖÐldconfigµÄ×÷ÓÿÉÒÔ×ÊÖúÎÒÃÇ׼ȷÖÎÀíºÍʹÓö¯Ì¬Á´½Ó¿âÎļþ£¬È·±£ÏµÍ³Äܹ»Ë³Ëì¼ÓÔغÍŲÓÃÐèÒªµÄ¿âº¯Êý¡£Í¨¹ýÉÏÃæµÄ´úÂëʾÀý£¬ÎÒÃÇ¿ÉÒÔÔ½·¢ÉîÈëµØÏàʶldconfigÏÂÁîµÄÏêϸÓ÷¨£¬Ìá¸ß¶Ô¶¯Ì¬Á´½Ó¿âÖÎÀíµÄÕÆÎÕÄÜÁ¦¡£

ÒÔÉϾÍÊÇÃ÷È·Linux ldconfigµÄ×÷ÓõÄÏêϸÄÚÈÝ£¬¸ü¶àÇë¹Ø×¢±¾ÍøÄÚÆäËüÏà¹ØÎÄÕ£¡

ÃâÔð˵Ã÷£ºÒÔÉÏչʾÄÚÈÝȪԴÓÚÏàÖúýÌå¡¢ÆóÒµ»ú¹¹¡¢ÍøÓÑÌṩ»òÍøÂçÍøÂçÕûÀí£¬°æȨÕùÒéÓë±¾Õ¾Î޹أ¬ÎÄÕÂÉæ¼°¿´·¨Óë¿´·¨²»´ú±í×ðÁú¿­Ê±¹ÙÍøµÇ¼ÂËÓÍ»úÍø¹Ù·½Ì¬¶È£¬Çë¶ÁÕß½ö×ö²Î¿¼¡£±¾ÎĽӴýתÔØ£¬×ªÔØÇë˵Ã÷À´ÓÉ¡£ÈôÄúÒÔΪ±¾ÎÄÇÖÕ¼ÁËÄúµÄ°æȨÐÅÏ¢£¬»òÄú·¢Ã÷¸ÃÄÚÈÝÓÐÈκÎÉæ¼°ÓÐÎ¥¹«µÂ¡¢Ã°·¸Ö´·¨µÈÎ¥·¨ÐÅÏ¢£¬ÇëÄúÁ¬Ã¦ÁªÏµ×ðÁú¿­Ê±¹ÙÍøµÇ¼ʵʱÐÞÕý»òɾ³ý¡£

Ïà¹ØÐÂÎÅ

ÁªÏµ×ðÁú¿­Ê±¹ÙÍøµÇ¼

18523999891

¿É΢ÐÅÔÚÏß×Éѯ

ÊÂÇéʱ¼ä£ºÖÜÒ»ÖÁÖÜÎ壬9:30-18:30£¬½ÚãåÈÕÐÝÏ¢

QR code
ÍøÕ¾µØͼ