1
votes

I am trying to build glib-networking-2.40.1. I am having trouble with the make step.

Configure step

~/gstreamer/plugins/recommended/good/glib-networking-2.40.1 $ sudo ./configure --disable-glibtest --host=arm-linux-gnueabi --prefix=$DISCIMAGE/usr/local/ --includedir=$DISCIMAGE/usr/include/glib-2.0 --libdir=$DISCIMAGE/usr/lib/arm-linux-gnueabi --libdir=$DISCIMAGE/usr/lib --exec-prefix=$DISCIMAGE/usr/local/ --includedir=$DISCIMAGE/home/ubuntu/gstreamer/plugins/recommended/gstreamer/glib-2.40.0/include --includedir=$DISCIMAGE/home/ubuntu/gstreamer/plugins/recommended/gstreamer/glib-2.40.0/glib --with-ca-certificates=/etc/ssl/ca-bundle.crt --includedir=$DISCIMAGE/home/ubuntu/gstreamer/plugins/recommended/good/gnutls-3.3.7/ --includedir=$DISCIMAGE/home/ubuntu/gstreamer/plugins/recommended/gstreamer/glib-2.40.0/ --with-gnutls=/home/ubuntu/gstreamer/plugins/recommended/good/gnutls-3.3.7/ --libdir=/usr/lib/arm-linux-gnueabihf/ --libdir=/usr/lib --libdir=/usr/lib/arm-linux-gnueabi --libdir=/usr/lib/arm-linux-gnueabihf/ --libdir=/home/ubuntu/gstreamer/plugins/recommended/gstreamer/glib-2.40.0/gio/.libs/

then I try

sudo make

and I get the error

CC gnutls-module.lo gnutls-module.c:22:21: fatal error: gio/gio.h: No such file or directory

gio.h is located at

/home/ubuntu/gstreamer/plugins/recommended/gstreamer/glib-2.40.0/gio/

which is included in my configure step

also I have libgio-2.0.so located at

/usr/lib/libgio-2.0.so

and

/usr/lib/arm-linux-gnueabihf/gio/libgio-2.0.so.0

and

/usr/lib/libgio-2.0.so.0

all of which are included in configure

pkg-config gives

sudo pkg-config --libs --cflags gio-2.0

-pthread -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -lgio-2.0 -lgobject-2.0 -lglib-2.0

Any help would be greatly appreciated

1

1 Answers

0
votes

The --includedir and --libdir arguments to configure are supposed to tell your package where to install its own headers and libraries, not where to find other headers and libraries. You should not normally need to use those arguments.

Making that mistake when you compiled GLib is presumably why your gio.h is located at /home/ubuntu/gstreamer/plugins/recommended/gstreamer/glib-2.40.0/gio/ instead of at /usr/include or /usr/local/include.

Instead, the output of pkg-config should tell your program where to find headers and libraries. If you've installed your package properly, then pkg-config's output should be correct. The idea is that instead of you researching where all the libraries live and passing those paths to configure, each library installs a pkg-config file that has that information, so if you know where the pkg-config files are, then you don't need to know anything else.

So probably you should uninstall, recompile, and reinstall all the packages you've been compiling, reconfiguring them without the --include and --libdir arguments.