1

I am trying to compile an Example but I am getting following errors/issues. I am not sure where the config file and make file is for this package and I don't want to make changes that wipe out everything I have done so far with packages such as "wiringPi" and " bcm2835-1.50" etc. I need to know what to add to what file and how to run "make" etc on my Raspberry Pi.

gcc -o elinux-example elinux-example.c In file included from elinux-example.c:11:0: /usr/include/glib-2.0/glib.h:30:26: fatal error: glib/galloca.h: No such file or directory compilation terminated.

gcc pkg-config --libs --cflags glib-2.0 elinux-example.c -o elinux-example elinux-example.c:14:43: fatal error: /usr/include/glib-2.0/galloca.h: No such file or directory compilation terminated.

gcc -l/usr/include/glib-2.0 pkg-config --libs glib elinux-example.c -o elinux-example Package glib was not found in the pkg-config search path. Perhaps you should add the directory containing `glib.pc' to the PKG_CONFIG_PATH environment variable No package 'glib' found In file included from elinux-example.c:13:0: /usr/include/glib-2.0/glib.h:30:26: fatal error: glib/galloca.h: No such file or directory compilation terminated.

Your assistance is appreciated.

  • How exactly does elinux-example.c include the glib header? as <glib.h> or as <glib/glib.h>? If posible, edit your question to include the relevant portion of the .c file – steeldriver May 22 '16 at 19:06
  • Thank you for getting back with me. Below is how it originally appears in the code. – Givi May 25 '16 at 0:30
  • #include </usr/include/glib-2.0/glib.h> #include <glib/gprintf.h> – Givi May 25 '16 at 0:30
  • Any update on this, anyone? – Givi Aug 11 '16 at 15:06
  • Please edit your question to include the outputs of pkg-config --libs --cflags glib-2.0 and dpkg -V libglib2.0-dev – steeldriver Aug 11 '16 at 15:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.