when attempting to compile gutenprint-5.3.3 (and even the older versions) with -with-gimp2 --with-gimp2-as-gutenprint, the compilation fails with this error:
Making all in gimp2
make[3]: Entering directory '/var/tmp/portage/net-print/gutenprint-5.3.3/work/gutenprint-5.3.3/src/gimp2'
x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../.. -I../../include -I../../include -march=native -O2 -pipe -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Wwrite-strings -Werror-implicit-function-declaration -Winline -Wformat=2 -finline-limit=131072 -Wformat -Werror=format-security -Wmissing-prototypes -Disfinite=finite -march=native -O2 -pipe -O3 -c -o print-image-gimp.o print-image-gimp.c
In file included from print_gimp.h:37,
from print-image-gimp.c:27:
../../include/gutenprintui2/gutenprintui.h:47:10: fatal error: gtk/gtk.h: No such file or directory
47 | #include <gtk gtk.h="">
| ^~~~~~~~~~~
compilation terminated.</gtk>
imo the reason is that the path for gtk include is missing in the command as the header file is located here:
/usr/include/gtk-2.0/gtk/gtk.h
instead of being it expected in:
/usr/include/gtk/gtk.h
more information to the bug can be found here: https://bugs.gentoo.org/613278 (though it was first reported for version 5.2.12, it still appears in 5.3.3).
My gtk headers are installed in /usr/include/gtk-2.0.
If you build it from the source tarball (https://sourceforge.net/projects/gimp-print/files/gutenprint-5.3/5.3.3/gutenprint-5.3.3.tar.xz/download), does it build properly? The problem might be with the emerge (I don't have a Gentoo system myself to check it on).
thank you for your reply.
i just tried to build it directly from the sources and the result is the same:
./configure --prefix=/usr --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --disable-dependency-tracking --disable-silent-rules --docdir=/usr/share/doc/gutenprint-5.3.3 --htmldir=/usr/share/doc/gutenprint-5.3.3/html --with-sysroot=/ --libdir=/usr/lib64 --enable-test --disable-translated-cups-ppds --enable-libgutenprintui2 --with-gimp2 --with-gimp2-as-gutenprint --with-cups --enable-nls --with-readline --disable-static --enable-cups-ppds --enable-cups-level3-ppds
...
make
...
make[3]: Vstupuje se do adresáře „/home/fordfrog/src/gentoo/gutenprint-5.3.3/src/gimp2“
x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../.. -I../../include -I../../include -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Wwrite-strings -Werror-implicit-function-declaration -Winline -Wformat=2 -finline-limit=131072 -Wformat -Werror=format-security -Wmissing-prototypes -Disfinite=finite -O3 -c -o print-image-gimp.o print-image-gimp.c
In file included from print_gimp.h:37,
from print-image-gimp.c:27:
../../include/gutenprintui2/gutenprintui.h:47:10: fatal error: gtk/gtk.h: Adresář nebo soubor neexistuje
47 | #include <gtk gtk.h="">
| ^~~~~~~~~~~
compilation terminated.</gtk>
I just installed it from said sources, and this is what i get:
Making all in gutenprintui2
make[3]: Entering directory '/home/khessels/gutenprint-5.3.3/src/gutenprintui2'
CC libgutenprintui2_la-printrcy.lo
In file included from printrcy.y:28:0:
../../include/gutenprintui2/gutenprintui.h:47:10: fatal error: gtk/gtk.h: No such file or directory
#include <gtk gtk.h="">
^~~~~~~~~~~
compilation terminated.
Makefile:646: recipe for target 'libgutenprintui2_la-printrcy.lo' failed
make[3]: *** [libgutenprintui2_la-printrcy.lo] Error 1
make[3]: Leaving directory '/home/khessels/gutenprint-5.3.3/src/gutenprintui2'
Makefile:481: recipe for target 'all-recursive' failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory '/home/khessels/gutenprint-5.3.3/src'
Makefile:597: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/khessels/gutenprint-5.3.3'
Makefile:528: recipe for target 'all' failed
make: *** [all] Error 2
khessels@kees-pc:~/gutenprint-5.3.3$ </gtk>
above error was created with following config:
./configure --with-gimp2 --with-gimp2-as-gutenprint --enable-user-install --enable-libgutenprintui2 --enable-cups-level3-ppds --enable-cups-ppds --enable-escputil --enable-cups-1_2-enhancements --enable-cups-ppds-at-top-level
after removing --enable-libgutenprintui2 and configure/make again still the same error
after removing --enable-escputil still the same error, probably after removing the gimp options it might work, but i need it as a gimp plugin
When you run configure at top level, it emits Configuration Summary at the end. Could you post that, please?
note even after
sudo apt-get install build-essential libgtk2.0-dev
still the same error
khessels@kees-pc:~/gutenprint-5.3.3$ ./configure --with-gimp2 --with-gimp2-as-gutenprint --enable-user-install --enable-libgutenprintui2 --enable-cups-level3-ppds --enable-cups-ppds --enable-escputil --enable-cups-1_2-enhancements --enable-cups-ppds-at-top-level
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether UID '1000' is supported by ustar format... yes
checking whether GID '1001' is supported by ustar format... yes
checking how to create a ustar tar archive... gnutar
checking whether make supports nested variables... (cached) yes
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking how to print strings... printf
checking whether make supports the include directive... yes (GNU style)
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking dependency style of gcc... gcc3
checking for a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for fgrep... /bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /usr/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for sysroot... no
checking for a working dd... /bin/dd
checking how to truncate binary pipes... /bin/dd bs=4096 count=1
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
./configure: line 12515: dlopen: command not found
checking whether to enable maintainer-specific portions of Makefiles... no
checking for cups-config... /usr/bin/cups-config
checking whether to whether to build CUPS driver... (automatic)
checking whether NLS is requested... yes
checking for msgfmt... /usr/bin/msgfmt
checking for gmsgfmt... /usr/bin/msgfmt
checking for xgettext... /usr/bin/xgettext
checking for msgmerge... /usr/bin/msgmerge
checking for ld used by GCC... /usr/bin/ld -m elf_x86_64
checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes
checking for shared library run path origin... done
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for GNU gettext in libc... yes
checking whether to use NLS... yes
checking where the gettext function comes from... libc
checking whether to build CUPS PPD files... (automatic)
checking whether to build CUPS PPD files... yes
checking whether to build CUPS 1.2 enhancements... yes
checking whether to build translated CUPS PPD files... yes
checking whether to build globalized CUPS PPD files... yes
checking whether to build simplified CUPS PPD files... no
checking whether to place CUPS PPD files at top level... yes
checking whether to generate PostScript level 3 PPD files... yes
checking whether to build a statically-linked cups-genppd and rastertogutenprint. WARNING: Please read the README and NEWS (release notes) CAREFULLY before using --disable-static-genppd!... yes
checking whether to enable loadable modules... (automatic)
checking whether to turn on debugging in build... no
checking whether to turn on profiling in build... no
checking whether to use readline... yes
checking for pkg-config... /usr/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for libusb-1.0... no
checking whether to install GIMP plugin in home directory... yes
checking for gimptool-2.0... no
checking for gtk+-2.0... yes
checking whether to build GIMP 2.x Print plugin... yes
checking whether to name GIMP 2.x Print plugin gutenprint (requires GIMP 2.2; normally used with GIMP 2.4 or above)... yes
checking whether to build Gutenprint GTK+-2.0 user interface library... yes
checking whether to install sample images... yes
checking whether to build escputil... yes
checking whether to build test programs... yes
checking whether to build Gutenprint documentation... yes
checking whether to build testpattern generator... yes
checking for iconv... yes
checking for library containing strerror... none required
checking for gawk... (cached) gawk
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking whether gcc understands -c and -o together... (cached) yes
checking dependency style of gcc... (cached) gcc3
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking whether gcc understands -c and -o together... (cached) yes
checking dependency style of gcc... (cached) gcc3
checking whether ln -s works... yes
checking for flex... no
checking for lex... no
checking for bison... no
checking for byacc... no
checking for test... /usr/bin/test
checking for true... /bin/true
checking for find... /usr/bin/find
checking for perl... /usr/bin/perl
checking for glib-mkenums... /usr/bin/glib-mkenums
checking for convert... /usr/bin/convert
checking for bash... /bin/bash
checking for texi2html... no
checking for dvips... no
checking for db2pdf... no
checking for dvipdf... /usr/bin/dvipdf
checking for db2ps... no
checking for db2html... no
checking for doxygen... no
checking for xz... /usr/bin/xz
checking for gzip... /bin/gzip
checking for bzip2... /bin/bzip2
checking for lrzip... no
checking for rzip... no
checking for zpaq... no
checking for bash... /bin/bash
checking if gcc supports -Wall... yes
checking if gcc supports -Wcast-align... yes
checking if gcc supports -Wstrict-prototypes... no
checking if gcc supports -Wmissing-prototypes... yes
checking if gcc supports -Wmissing-declarations... yes
checking if gcc supports -Wnested-externs... yes
checking if gcc supports -Wwrite-strings... yes
checking if gcc supports -Werror-implicit-function-declaration... yes
checking if gcc supports -Winline... yes
checking if gcc supports -Wformat=2... yes
checking if gcc supports -finline-limit=131072... yes
checking if gcc supports -Wformat... yes
checking if gcc supports -Werror=format-security... yes
checking if gcc supports -Wmissing-prototypes... yes
checking if gcc supports -O3... yes
checking if gcc supports attribute syntax... yes
checking for readline in -lreadline... no
checking for readline in -lreadline... no
checking for readline in -lreadline... no
checking for readline in -lreadline... no
checking for lt_dlopen in -lltdl... yes
checking for dlopen in -ldl... yes
checking for pow in -lm... yes
checking for pow in -lm... (cached) yes
checking for gzgets in -lz... yes
checking for cups-config... /usr/bin/cups-config
checking for ANSI C header files... (cached) yes
checking getopt.h usability... yes
checking getopt.h presence... yes
checking for getopt.h... yes
checking readline/readline.h usability... no
checking readline/readline.h presence... no
checking for readline/readline.h... no
checking for dlfcn.h... (cached) yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking ltdl.h usability... yes
checking ltdl.h presence... yes
checking for ltdl.h... yes
checking stdarg.h usability... yes
checking stdarg.h presence... yes
checking for stdarg.h... yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking for sys/types.h... (cached) yes
checking time.h usability... yes
checking time.h presence... yes
checking for time.h... yes
checking for unistd.h... (cached) yes
checking for an ANSI C-conforming const... yes
checking for inline... inline
checking for off_t... yes
checking for size_t... yes
checking for nanosleep... yes
checking for poll... yes
checking for usleep... yes
checking for getopt_long... yes
checking for library containing finite... none required
checking which module system will be used... static
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating doc/Makefile
config.status: creating doc/gutenprint.dox
config.status: creating doc/gutenprintui2.dox
config.status: creating doc/developer/Makefile
config.status: creating include/Makefile
config.status: creating include/gutenprint/Makefile
config.status: creating include/gutenprintui2/Makefile
config.status: creating include/gutenprint/gutenprint-version.h
config.status: creating man/Makefile
config.status: creating man/cups-calibrate.8
config.status: creating man/cups-genppd.8
config.status: creating man/cups-genppdupdate.8
config.status: creating man/escputil.1
config.status: creating po/Makefile.in
config.status: creating samples/Makefile
config.status: creating src/Makefile
config.status: creating src/cups/Makefile
config.status: creating src/cups/Info.plist
config.status: creating src/cups/cups-genppdupdate
config.status: creating src/cups/test-ppds.test
config.status: creating src/cups/min-pagesize
config.status: creating src/escputil/Makefile
config.status: creating src/testpattern/compare-image-files
config.status: creating src/testpattern/run-testpattern
config.status: creating src/testpattern/run-testpattern-1.test
config.status: creating src/testpattern/run-testpattern-2
config.status: creating src/testpattern/run-testpattern-2.test
config.status: creating src/testpattern/compare-checksums
config.status: creating src/testpattern/compress-checksums
config.status: creating src/cups/test-rastertogutenprint
config.status: creating src/cups/test-rastertogutenprint.test
config.status: creating src/testpattern/Makefile
config.status: creating src/gimp2/Makefile
config.status: creating src/main/Makefile
config.status: creating src/main/gutenprint.pc
config.status: creating src/xml/Makefile
config.status: creating src/xml/dither/Makefile
config.status: creating src/xml/papers/Makefile
config.status: creating src/xml/printers/Makefile
config.status: creating src/xml/escp2/Makefile
config.status: creating src/xml/escp2/media/Makefile
config.status: creating src/xml/escp2/mediasizes/Makefile
config.status: creating src/xml/escp2/model/Makefile
config.status: creating src/xml/escp2/model/base/Makefile
config.status: creating src/xml/escp2/inputslots/Makefile
config.status: creating src/xml/escp2/inks/Makefile
config.status: creating src/xml/escp2/weaves/Makefile
config.status: creating src/xml/escp2/qualitypresets/Makefile
config.status: creating src/xml/escp2/resolutions/Makefile
config.status: creating src/gutenprintui2/Makefile
config.status: creating src/gutenprintui2/gutenprintui2.pc
config.status: creating test/Makefile
config.status: creating test/compress-5level.sh
config.status: creating test/compress-6level.sh
config.status: creating test/uncompress-5level.sh
config.status: creating test/uncompress-6level.sh
config.status: creating test/parse-bjc
config.status: creating test/parse-escp2
config.status: creating test/run-testdither.test
config.status: creating test/run-weavetest.test
config.status: creating test/test-curve.test
config.status: creating scripts/Makefile
config.status: creating scripts/mkgitlog
config.status: creating scripts/gversion
config.status: creating scripts/test-gversion
config.status: creating scripts/wzpaq
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
rm: cannot remove 'libtoolT': No such file or directory
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile
config.status: executing default commands
Gutenprint Configuration Summary:
If you have any problems, please report the information below to
gimp-print-devel@lists.sourceforge.net
================================================================
Release: gutenprint 5.3.3 generated on 25 Aug 2019
Generated at Sun Feb 9 19:19:51 CST 2020 by khessels
Features:
Build CUPS: yes, installing in /usr
Build CUPS 1.2 enhancements: yes
Build CUPS PPD files: yes
Build translated CUPS PPD files: yes
Build global CUPS PPD files: yes
Build simplified CUPS PPD files: no
Install CUPS PPDs at top level: yes
Generate PS level 3 CUPS PPD files: yes
Build genppd statically: yes
Build CUPS dyesub USB backend: no
Build EPSON inkjet utility: yes
Build enhanced Print plugin for GIMP: yes
GIMP plugin will be named: gutenprint
Install plugin(s) in home directory: yes
Build test programs: yes
Build testpattern generator: yes
Installation summary:
Installation prefix: /usr/local
Exec prefix: /usr/local (${prefix})
Data directory: /usr/local/share/gutenprint
Library directory: /usr/local/lib/gutenprint (/usr/local/lib/gutenprint)
Executable directory: /usr/local/bin (/usr/local/bin)
XML data directory: /usr/local/share/gutenprint/5.3/xml
Module directory: /usr/local/lib/gutenprint/5.3/modules (/usr/local/lib/gutenprint/5.3/modules)
Install sample images: yes
General configuration:
Configure arguments: --with-gimp2 --with-gimp2-as-gutenprint --enable-user-install --enable-libgutenprintui2 --enable-cups-level3-ppds --enable-cups-ppds --enable-escputil --enable-cups-1_2-enhancements --enable-cups-ppds-at-top-level
Compiler: gcc
Compiler Version: gcc version 7.4.0 (Ubuntu 7.4.0-1ubuntu1~18.04.1)
Compiler options: -Disfinite=finite -O3 -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Wwrite-strings -Werror-implicit-function-declaration -Winline -Wformat=2 -finline-limit=131072 -Wformat -Werror=format-security -Wmissing-prototypes
Build static libraries: yes
Build shared libraries: yes
Maintainer mode: no
Use i18n: yes
Generate profiling information: no
Generate debugging symbols: no
Use modules: static
Use readline libraries: yes
uname -a output: Linux kees-pc 5.3.0-28-generic #30~18.04.1-Ubuntu SMP Fri Jan 17 06:14:09 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
================================================================
Finished configuring. Please review CAREFULLY the configuration summary above.
This summary is also stored in config.summary
Type 'make clean' followed by 'make' to build the package
then 'make install' to install it.
What does
pkg-config gtk+-2.0 --cflags
return?
pkg-config gtk+-2.0 --cflags
-pthread -I/usr/include/gtk-2.0 -I/usr/lib/x86_64-linux-gnu/gtk-2.0/include -I/usr/include/gio-unix-2.0/ -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng16 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/freetype2 -I/usr/include/libpng16
I am on neon-development (ubuntu 18.04 with plasma)
Could you try
V=1 make
?
It won't succeed; I'm interested in seeing the compile line.
let me run a make.... 2 min
Last edit: Kees Hessels 2020-02-10
V=1 make
(the V=1 turns on verbosity).
Interesting that the gtk cflags aren't being included here. What does
pkg-config --cflags gimpui-2.0
return?
Do you have the gimp development package installed? I notice that you explicitly mention the libgtk2.0-dev package, but did you install gimpui2.0-dev, gimp2.0-dev, or whatever?
hmm... let me try that...
On Sun, Feb 9, 2020 at 9:09 PM Robert Krawitz rlk@users.sourceforge.net
wrote:
Related
Bugs:
#725i installed accorduing to this page: apt-get build-dep gimp
https://wiki.gimp.org/wiki/Hacking:Developer_FAQ#Installing_needed_libraries_on_Ubuntu
make clean and make, same result...
i dont know about the other packages, couldnt find them...
Those are the packages needed to build GIMP; they aren't sufficient for building GIMP plugins. Per https://www.cyberciti.biz/faq/how-to-install-or-compile-gimp-filterspluginsextensions-on-linux/ you will also need to install libgimp2.0-dev.
No such luck.. installed libgimp2.0 libgimp2.0-dev and the gimp registry package
Still the same error with gtk
Please re-run configure (and you should not need the --with-gimp).
reconfigured without --with-gimp2, make clean and make...
Houston, we have lift off :)
I guess it was the libgimp2.0-dev, just had to reconfigure...
Thanks man, Super cool you did this on a Sunday night no less...
I guess we are all nerds here right ... Thanks again man