Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 305111 - app-text/ghostscript-gpl fails to compile against media-libs/libpng-1.4.0
Summary: app-text/ghostscript-gpl fails to compile against media-libs/libpng-1.4.0
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Printing Team
URL: http://bugs.ghostscript.com/show_bug....
Whiteboard:
Keywords:
: 319269 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-02-14 18:50 UTC by Lars Wendler (Polynomial-C) (RETIRED)
Modified: 2010-07-18 13:40 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
ghostscript-gpl-8.70-r1.ebuild.diff (ghostscript-gpl-8.70-r1.ebuild.diff,465 bytes, patch)
2010-02-14 18:50 UTC, Lars Wendler (Polynomial-C) (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2010-02-14 18:50:27 UTC
./obj/../soobj/echogs -e .dev -w- -l-dev2 -b -s -l-include -l./obj/../soobj/page -l-obj ./obj/../soobj/pksmraw ./obj/../soobj/gdevpbm.o ./obj/../soobj/gdevppla.o ./obj/../soobj/gdevmpla.o                                                     
./obj/../soobj/echogs -e .dev -w- -l-dev2 -b -s -l-include -l./obj/../soobj/page -l-obj ./obj/../soobj/plan9bm ./obj/../soobj/gdevpbm.o ./obj/../soobj/gdevppla.o ./obj/../soobj/gdevmpla.o
make[1]: *** No rule to make target `src/png.c', needed by `obj/../soobj/png.o'.  Stop.
make[1]: Leaving directory `/var/tmp/portage/app-text/ghostscript-gpl-8.70-r1/work/ghostscript-8.70'
make: *** [so] Error 2


Reproducible: Always

Steps to Reproduce:
Comment 1 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2010-02-14 18:50:51 UTC
Created attachment 219677 [details, diff]
ghostscript-gpl-8.70-r1.ebuild.diff

quick'n'dirty fix
Comment 2 Timo Gurr (RETIRED) gentoo-dev 2010-02-15 21:43:37 UTC
Adding URL to the upstream bug.
Comment 3 Samuli Suominen (RETIRED) gentoo-dev 2010-03-08 10:25:48 UTC
Since it's been reported upstream, I've worked this around in ebuild.

+  08 Mar 2010; Samuli Suominen <ssuominen@gentoo.org>
+  ghostscript-gpl-8.71-r1.ebuild:
+  Fix libpng14 detection wrt #305111 by Lars Wendler.
Comment 4 Timo Gurr (RETIRED) gentoo-dev 2010-03-08 10:55:55 UTC
Reopening as the problem wasn't yet acknowledged and/or fixed upstream.
Comment 5 Samuli Suominen (RETIRED) gentoo-dev 2010-03-08 11:13:41 UTC
there's 3 files to patch

configure.ac
base/configure.ac
jbig2dec/configure.ac

so attached fix is here not enough

fixed properly in portage
Comment 6 Timo Gurr (RETIRED) gentoo-dev 2010-03-08 11:40:49 UTC
(In reply to comment #5)
> there's 3 files to patch

Thanks Samuli, I've updated the upstream patch accordingly.
Comment 7 Samuli Suominen (RETIRED) gentoo-dev 2010-03-09 04:38:41 UTC
doesn't block bug 305095 anymore. thanks for taking it to upstream
Comment 8 Justin Lecher (RETIRED) gentoo-dev 2010-05-11 12:12:24 UTC
*** Bug 319269 has been marked as a duplicate of this bug. ***
Comment 9 Andreas K. Hüttel archtester gentoo-dev 2010-05-22 15:38:45 UTC
(In reply to comment #8)
> *** Bug 319269 has been marked as a duplicate of this bug. ***
> 

Not a duplicate. app-text/ghostscript-gpl-8.64-r3 fails with the same error. 

./obj/../soobj/echogs -e .dev -w- -l-dev2 -b -s -l-include -l./obj/../soobj/page -l-obj ./obj/../soobj/plan9bm ./obj/../soobj/gdevpbm.o ./obj/../soobj/gdevppla.o ./obj/../soobj/gdevmpla.o
make[1]: *** Keine Regel vorhanden, um das Target »src/png.c«, 
  benötigt von »obj/../soobj/png.o«, zu erstellen.  Schluss.
make[1]: Leaving directory `/home/tmp/portage/app-text/ghostscript-gpl-8.64-r3/work/ghostscript-8.64'
make: *** [so] Fehler 2
 * ERROR: app-text/ghostscript-gpl-8.64-r3 failed:
 *   emake failed
 * 
 * Call stack:
 *     ebuild.sh, line  54:  Called src_compile
 *   environment, line 3464:  Called die
 * The specific snippet of code:
 *       emake -j1 so all || die "emake failed";
 * 
 * If you need support, post the output of 'emerge --info =app-text/ghostscript-gpl-8.64-r3',
 * the complete build log and the output of 'emerge -pqv =app-text/ghostscript-gpl-8.64-r3'.
 * The complete build log is located at '/home/tmp/portage/app-text/ghostscript-gpl-8.64-r3/temp/build.log'.
 * The ebuild environment file is located at '/home/tmp/portage/app-text/ghostscript-gpl-8.64-r3/temp/environment'.
 * S: '/home/tmp/portage/app-text/ghostscript-gpl-8.64-r3/work/ghostscript-8.64'
sandbox:main  signal SIGQUIT already had a handler ...
Comment 10 Andreas K. Hüttel archtester gentoo-dev 2010-05-23 16:38:34 UTC
The same patch applies also cleanly to app-text/ghostscript-gpl-8.64-r3, and I'm not seeing any obvious problems with the resulting binary. 

http://git.overlays.gentoo.org/gitweb/?p=user/dilfridge.git;a=tree;f=app-text/ghostscript-gpl;hb=HEAD

Please consider also applying the patch to this current stable version of ghostscript-gpl, at least before libpng-1.4 becomes stable.
Comment 11 Timo Gurr (RETIRED) gentoo-dev 2010-06-28 06:27:53 UTC
Upstream comment regarding the patch:

--- Comment #4 from Hin-Tak Leung <hintak@ghostscript.com> 2010-06-28 03:16:48 UTC ---
(In reply to comment #2)
> Created an attachment (id=6041)
 --> (http://bugs.ghostscript.com/attachment.cgi?id=6041) [details]
> ghostscript-gpl-8.71-libpng-1.4.0-compile-fix-v2.patch

Sorry, the patch is wrong - in 1.4.0, png_check_sig() is removed and replaced
by    png_sig_cmp() so applying it would break building against linpng 1.2.x .

It would be far better to modify configure to check for a function which is
common to both 1.2.x and 1.4.x, rather than switching between the two. e.g.
check if png_struct is defined or png_create_write_struct() is defined. (these
are actually used by the png device so rather more appropriate than either
png_check_sig() or png_sig_cmp()).
Comment 12 Samuli Suominen (RETIRED) gentoo-dev 2010-06-30 08:53:40 UTC
The bug is fixed in upstream, see:

http://bugs.ghostscript.com/show_bug.cgi?id=691111#c4

The upstream guy is wrong though, the patch we apply now (the sed in ebuild) doesn't break building with libpng 1.2.x, the new function was already included in 1.2.x... so there is nothing wrong with the way we fix it now

but whatever, both ways work, and we get the upstream version of the fix with next release
Comment 13 Luke-Jr 2010-07-18 13:40:59 UTC
Please fix app-text/ghostscript-gpl-8.64-r3 so stable ARM can build.