Download GODI User`s Manual
Transcript
The variables all start with CONF_<NAME> where <NAME> is the capitalized package name. The idea is that the using Makfile of the settings can simply include the file, and get all settings at once this way. Effectively, the TOTAL_CFLAGS and TOTAL_LDFLAGS variables count. Note however that there are many older conf packages not producing these variables. Actually, the set of variables evolved with the development of GODI, so there are now several styles. We document here the recommended one. The variables include more than TOTAL_CFLAGS and TOTAL_LDFLAGS because it is sometimes more convenient to use one of the other, more basic variables. There are two methods for determining the compiler options: • Config script method: Calling a config script (like freetype-config): This is easy and straight-forward. The script returns the CFLAGS and LDFLAGS settings. • Search method: Searching for the library and figuring out the compiler options. Depending on the method, only a subset of the variables are set. • INCDIRS: Directories where to look for include files. These are the directories later turned into -I options. System directories like /usr/include that are checked anyway for header files by the compiler must be omitted. Multiple directories are spaceseparated. This variable is usually only set by the search method. • LIBDIRS: Directories where to look for libraries. These are the directories later turned into -L, and sometimes -Wl,-rpath options. System directories like /usr/lib that are checked anyway for libraries by the linker must be omitted. Multiple directories are space-separated. This variable is usually only set by the search method. • LIBNAMES: The names of the libraries. These are the names later turned into -l options. Multiple names are space-separated. Following linker conventions, several libraries must be given in their reverse dependency order, i.e. when x needs y, the order is «x y». (Note that the order is usually only important for static linking.) This variable is usually only set by the search method. • CFLAGS: The flags for C-compiling. This variable is usually only set by the config script method. • LDFLAGS: The flags for linking. This variable is usually only set by the config script method. • NEED_RPATH: Either «yes» or «no». If «yes», it is required to pass a -Wl,-rpath option to the linker to instruct the loader where to find the library at runtime. (See comments below.) This variable should only be «yes» if LDFLAGS does not already include the -Wl,-rpath options. • TOTAL_CFLAGS: The «union» of INCDIRS and CFLAGS. For any method, this variable contains the effective options for C-compiling. 67