I am trying to build Plugins for Geany 1.33 under RHEL 7.3. Geany was already successfully built on this machine and is installed at:
/user/kklein/geany/1.33
From the directory where the geany plugins files were extracted I ran the
following commands:
setenv PKG_CONFIG_PATH /user/kklein/geany/1.33/lib/pkgconfig
setenv GLIB_CFLAGS -I/usr/include/glib-2.0
./configure --prefix=/user/kklein/geany/1.33 --exec-prefix=/user/kklein/geany/1.33 --with-geany-libdir=/user/kklein/geany/1.33/lib
make
The configure step produces the following header file errors, but nothing related to glib.h:
conftest.c:11:28: fatal error: ac_nonexistent.h: No such file or directory
conftest.c:26:42: fatal error: CoreFoundation/CFPreferences.h: No such file or directory
conftest.c:26:37: fatal error: CoreFoundation/CFLocale.h: No such file or directory
conftest.c:63:18: fatal error: util.h: No such file or directory
conftest.c:64:21: fatal error: libutil.h: No such file or directory
Here is the make output:
make all-recursive
make[1]: Entering directory `/user/kklein/geany-plugins-1.33'
Making all in po
make[2]: Entering directory `/user/kklein/geany-plugins-1.33/po'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/user/kklein/geany-plugins-1.33/po'
Making all in utils
make[2]: Entering directory `/user/kklein/geany-plugins-1.33/utils'
Making all in src
make[3]: Entering directory `/user/kklein/geany-plugins-1.33/utils/src'
CC libgeanypluginutils_la-filelist.lo
filelist.c:19:18: fatal error: glib.h: No such file or directory
#include <glib.h>
^
compilation terminated.
make[3]: *** [libgeanypluginutils_la-filelist.lo] Error 1
make[3]: Leaving directory `/user/kklein/geany-plugins-1.33/utils/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/user/kklein/geany-plugins-1.33/utils'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/user/kklein/geany-plugins-1.33'
make: *** [all] Error 2
I ran the following command:
cpp -v /dev/null -o /dev/null
Which produced the following (truncated) output:
/usr/local/include
/usr/include
If I run "locate glib.h", I receive the following (truncated) output:
/usr/include/glib-2.0/glib.h
Between that and my setting GLIB_CFLAGS to "-I/usr/include/glib-2.0", I am not sure why I am receiving this error. Does anyone have any suggestions?
Thanks
Hi,
Le 09/04/2018 à 17:29, Kevin Klein a écrit :
[…]
setenv PKG_CONFIG_PATH /user/kklein/geany/1.33/lib/pkgconfig____
setenv GLIB_CFLAGS -I/usr/include/glib-2.0____
Why are you setting GLIB_CFLAGS? You shouldn't do that manually but on *very* specific cases. Normally it should discover the appropriate flags through the pkg-config system, and those should be correct.
./configure --prefix=/user/kklein/geany/1.33 --exec-prefix=/user/kklein/geany/1.33 --with-geany-libdir=/user/kklein/geany/1.33/lib____
You shouldn't have to specify --exec-prefix manually if it matches `--prefix`, and you shouldn't have to specify --with-geany-libdir if the Geany package is properly found via pkg-config.
The configure step produces the following header file errors, but nothing related to glib.h:
conftest.c:11:28: fatal error: ac_nonexistent.h: No such file or directory
conftest.c:26:42: fatal error: CoreFoundation/CFPreferences.h: No such file or directory
conftest.c:26:37: fatal error: CoreFoundation/CFLocale.h: No such file or directory
conftest.c:63:18: fatal error: util.h: No such file or directory
conftest.c:64:21: fatal error: libutil.h: No such file or directory
Where do you see those? They look fine if they come from the config.log: they show you don't have ac_nonexistent.h (which is obviously expected), that you don't have some OSX headers (which is expected), and you don't have util.h and libutil.h, but you probably have pty.h which is an alternative (those are checked by the debugger and scope plugins).
Again, your issue is most likely due to incorrect GLIB_CFLAGS -- which, again, is normally auto-detected properly when it's not set.
Regards, Colomban