DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
Go to the first, previous, next, last section, table of contents.


3.1 @command{gimpprint-config}

Depending on the setup of the computer system GIMP-Print was installed on, as well as the options passed to @command{configure} when configuring the package when it was built, the @env{CFLAGS} and @env{LIBS} parameters needed to compile and link programs with libgimpprint may vary. To make it simple to determine what these are on any given system, the script @command{gimpprint-config} was created. It's job is to output the correct parameters for the setup on your system. The following options are available:

roger@whinlatter:~/gimpprint/devel$ gimpprint-config --help
Usage: gimpprint-config [OPTIONS] [LIBRARIES]
Options:
        [--prefix[=DIR]]
        [--exec-prefix[=DIR]]
        [--version]
        [--libs]
        [--cflags]
Libraries:
        gimpprint

The @option{--prefix} and @option{--exec-prefix} options are only needed if the installed locations of parts of GIMP-Print are different from the configured locations. These should never be needed if GIMP-Print was properly configured and installed.

The installed version of GIMP-Print can be obtained with the @option{--version} option:

roger@whinlatter:~/gimpprint/devel$ gimpprint-config --version
4.2.5

The correct @env{CFLAGS} to use can be obtained with the @option{--cflags} option:

roger@whinlatter:~/gimpprint/devel$ gimpprint-config --cflags

In this case, there are no special @env{CFLAGS} required to compile programs.

The correct @env{LIBS} to use can the obtained with the @option{--libs} option:

roger@whinlatter:~/gimpprint/devel$ gimpprint-config --libs
-L/usr/lib -lgimpprint -lm

The command can be used from the shell by enclosing it in backquotes ``':

gcc `gimpprint-config --cflags` -c prog.c
gcc `gimpprint-config --libs` -o prog prog.o

However, this is not the way it it typically used. Normally it is used in a `Makefile' (see section 3.2 @command{make}) or by an @command{m4} macro in a @command{configure} script (see section 3.3 @command{autoconf}).


Go to the first, previous, next, last section, table of contents.