#15132 closed defect (fixed)
Building gtk2 2.12.19 on 10.5 against the 10.4u SDK finds the wrong CUPS API version
Reported by: | rigahial@… | Owned by: | nox@… |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 1.7.0 |
Keywords: | cups-config 10.4u gtk2 CUPS_CONFIG | Cc: | |
Port: |
Description
I have a checkout of MacPorts r36289, configured as follows:
export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11/bin sudo mkdir /Library/Tcl/macports-universal-10.4 ./configure --prefix=/opt/local-universal-10.4 --with-tclpackage=/Library/Tcl/macports-universal-10.4 --with-universal-target=10.4 --with-universal-sysroot=/Developer/SDKs/MacOSX10.4u.sdk make sudo make install
Additionally I have added +universal to /opt/local-universal-10.4/etc/macports/variants.conf.
When I try to install gtk2, this is what I get:
$ sudo /opt/local-universal-10.4/bin/port install gtk2 ---> Building gtk2 with target all Error: Target org.macports.build returned: shell command " cd "/opt/local-universal-10.4/var/macports/build/_opt_local-universal-10.4_var_macports_sources_rsync.macports.org_release_ports_x11_gtk2/work/gtk+-2.12.9" && make all " returned error 2 Command output: gtkprintbackendcups.c:2123: warning: implicit declaration of function 'ppdFirstCustomParam' gtkprintbackendcups.c:2125: warning: implicit declaration of function 'ppdNextCustomParam' gtkprintbackendcups.c:2125: warning: comparison between pointer and integer gtkprintbackendcups.c:2129: error: 'PPD_CUSTOM_INT' undeclared (first use in this function) gtkprintbackendcups.c: In function 'create_pickone_option': gtkprintbackendcups.c:2099: error: 'ppd_coption_t' undeclared (first use in this function) gtkprintbackendcups.c:2099: error: (Each undeclared identifier is reported only once gtkprintbackendcups.c:2133: error: 'PPD_CUSTOM_PASSCODE' undeclared (first use in this function) gtkprintbackendcups.c:2099: error: for each function it appears in.) gtkprintbackendcups.c:2099: error: 'coption' undeclared (first use in this function) gtkprintbackendcups.c:2137: error: 'PPD_CUSTOM_PASSWORD' undeclared (first use in this function) gtkprintbackendcups.c:2141: error: 'PPD_CUSTOM_REAL' undeclared (first use in this function) gtkprintbackendcups.c:2145: error: 'PPD_CUSTOM_STRING' undeclared (first use in this function) gtkprintbackendcups.c:2117: warning: implicit declaration of function 'ppdFindCustomOption' gtkprintbackendcups.c:2121: error: 'ppd_cparam_t' undeclared (first use in this function) gtkprintbackendcups.c:2121: error: 'cparam' undeclared (first use in this function) gtkprintbackendcups.c:2123: warning: implicit declaration of function 'ppdFirstCustomParam' gtkprintbackendcups.c:2125: warning: implicit declaration of function 'ppdNextCustomParam' gtkprintbackendcups.c:2125: warning: comparison between pointer and integer gtkprintbackendcups.c:2129: error: 'PPD_CUSTOM_INT' undeclared (first use in this function) gtkprintbackendcups.c:2133: error: 'PPD_CUSTOM_PASSCODE' undeclared (first use in this function) gtkprintbackendcups.c:2137: error: 'PPD_CUSTOM_PASSWORD' undeclared (first use in this function) gtkprintbackendcups.c:2141: error: 'PPD_CUSTOM_REAL' undeclared (first use in this function) gtkprintbackendcups.c:2145: error: 'PPD_CUSTOM_STRING' undeclared (first use in this function) lipo: can't figure out the architecture type of: /var/tmp//ccbKSuYx.out make[4]: *** [gtkprintbackendcups.lo] Error 1 make[3]: *** [all-recursive] Error 1 make[2]: *** [all-recursive] Error 1 make[1]: *** [all-recursive] Error 1 make: *** [all] Error 2 Error: Status 1 encountered during processing.
The problem is that it's using the CUPS API version 1.2, while the version in the 10.4u SDK is API 1.1. It makes this mistake because it uses the cups-config program to find the API version, and it uses the one in /usr/bin instead of /Developer/SDKs/MacOSX10.4u/usr/bin:
$ /usr/bin/cups-config --api-version 1.3 $ /Developer/SDKs/MacOSX10.4u.sdk/usr/bin/cups-config --api-version 1.1
I have attached a patch that adds CUPS_CONFIG="${configure.universal_sysroot}/usr/bin/cups-config" to configure.env. That fixes this particular problem, but the build still fails with
gtkprintbackendcups.c: In function 'cups_dispatch_watch_check': gtkprintbackendcups.c:534: error: dereferencing pointer to incomplete type gtkprintbackendcups.c: In function 'cups_parse_user_default_printer': gtkprintbackendcups.c:1421: warning: implicit declaration of function 'g_fopen' gtkprintbackendcups.c:1421: warning: assignment makes pointer from integer without a cast gtkprintbackendcups.c: In function 'cups_parse_user_options': gtkprintbackendcups.c:1484: warning: assignment makes pointer from integer without a cast make[4]: *** [gtkprintbackendcups.lo] Error 1 make[3]: *** [all-recursive] Error 1 make[2]: *** [all-recursive] Error 1 make[1]: *** [all-recursive] Error 1 make: *** [all] Error 2 Warning: the following items did not execute (for gtk2): org.macports.activate org.macports.build org.macports.destroot org.macports.install Error: Status 1 encountered during processing.
Attachments (2)
Change History (6)
Changed 16 years ago by rigahial@…
Attachment: | gtk2-universal-10.4.diff added |
---|
comment:1 Changed 16 years ago by jmroot (Joshua Root)
Milestone: | → Port Bugs |
---|---|
Owner: | changed from macports-tickets@… to nox@… |
comment:2 Changed 16 years ago by rigahial@…
I have attached another patch that fixes the problem for me. This one uses "if {[variant_isset universal]}" instead of "variant universal". The previous patch was wiping out the universal configure arguments, so it was not compiling against the 104u SDK.
Changed 16 years ago by rigahial@…
Attachment: | gtk2-universal-10.4-corrected.diff added |
---|
Assigning to maintainer.