Changes between Version 3 and Version 4 of CompilationGuide/Generic

Dec 23, 2013, 4:31:47 PM (7 years ago)

add "LD_LIBRARY_PATH and ldconfig" section


  • CompilationGuide/Generic

    v3 v4  
    5959In case you installed a package in a non standard path, you need to update these environment libraries so that system tools will be able to detect the package components. This is especially required when running a configure script for a package relying on other installed libraries/headers/tools.
     61Environment variables are usually defined in the profile file, for example {{{.profile}}} defined in the user directory for sh/bash users, and in {{{/etc/profile}}}. You should probably update this file in order to set permanently your custom environment. Alternatively you can set the variables in a script or in a particular shell session.
     63Remember to export the variables to the child process, e.g. using the {{{export}}} command. Read the fine documentation of your shell for more detailed information. 
     65== LD_LIBRARY_PATH and ldconfig ==
     67When you link a library depending on other libraries, the tools will look for the libraries to link in a list of standard paths (typically, {{{/usr/lib}}}, and in other paths which are set in the system. Some systems rely on the {{{LD_LIBRARY_PATH}}} library. Alternatively you may set the global path through the {{{ldconfig}}} utility, which is done editing the {{{/etc/}}} system configuration file.
     69Note that on some systems the {{{LD_LIBRARY_PATH}}} variable defined in the shell profile is reset for security reasons (e.g. see, so you may need to reset it per-session or per-script.
    6272== Configuration prerequisites and distribution packages ==