Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 431916

Summary: dev-dotnet/libgdiplus-2.10.9 - Variable 'libjpeg_prefix' not defined in '/usr/lib64/pkgconfig/libgdiplus.pc'
Product: Gentoo Linux Reporter: Bartosz Brachaczek <b.brachaczek>
Component: Current packagesAssignee: dotnet project <dotnet>
Status: RESOLVED FIXED    
Severity: normal CC: cynede, freedesktop-bugs, ianh, ostroffjh, rich0, rossi.f
Priority: Normal Keywords: NeedPatch
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 487442    
Attachments: libgdiplus-2.10.9-configure.patch

Description Bartosz Brachaczek 2012-08-19 00:39:22 UTC
$ pkg-config --libs libgdiplus
Variable 'libjpeg_prefix' not defined in '/usr/lib64/pkgconfig/libgdiplus.pc'


# emerge --info
Portage 2.1.11.10 (default/linux/amd64/10.0/desktop/kde, gcc-4.6.3, glibc-2.15-r2, 3.5.1-gentoo x86_64)
=================================================================
System uname: Linux-3.5.1-gentoo-x86_64-Intel-R-_Core-TM-_i3-2310M_CPU_@_2.10GHz-with-gentoo-2.1
Timestamp of tree: Sat, 18 Aug 2012 19:15:01 +0000
ccache version 3.1.8 [disabled]
app-shells/bash:          4.2_p37
dev-java/java-config:     2.1.12
dev-lang/python:          2.7.3-r2, 3.2.3-r1
dev-util/ccache:          3.1.8
dev-util/cmake:           2.8.8-r3
dev-util/pkgconfig:       0.27
sys-apps/baselayout:      2.1-r1
sys-apps/openrc:          0.10.5
sys-apps/sandbox:         2.6
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.9.6-r3, 1.11.6, 1.12.2, 9999
sys-devel/binutils:       2.22.90
sys-devel/gcc:            4.6.3, 4.7.1
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 3.5 (virtual/os-headers)
sys-libs/glibc:           2.15-r2
Repositories: gentoo local mythtv roslin x11 java-overlay
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=native -fno-omit-frame-pointer -g -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/themes/oxygen-gtk/gtk-2.0 /usr/share/themes/oxygen-gtk/gtk-3.0"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -march=native -fno-omit-frame-pointer -g -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--quiet-build=n"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs compressdebug config-protect-if-modified distlocks ebuild-locks fixlafiles metadata-transfer news parallel-fetch parse-eapi-ebuild-head protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS=" http://gentoo.mirror.pw.edu.pl http://www.ibiblio.org/pub/Linux/distributions/gentoo http://distfiles.gentoo.org"
LANG="pl_PL.utf8"
LC_ALL="pl_PL.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--hash-style=gnu"
LINGUAS="pl_PL pl en_US en"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage /usr/local/mythtv_portage/Gentoo /var/lib/layman/roslin /var/lib/layman/x11 /var/lib/layman/java-overlay"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="X a52 aac acpi akonadi alsa amd64 avahi avx bash-completion berkdb bluetooth branding bzip2 cairo cdda cdr cli consolekit crypt cups cxx dbus declarative development dri dts dvd dvdr egl emboss encode exif fam ffmpeg fftw firefox flac fontconfig fortran gdbm gif git glib gmp gpm gstreamer iconv icu idn ios ipod ipv6 javascript jpeg jpeg2k kde kipi lame lcms libnotify lzma lzo mad mercurial mmap mmx mng modules mp3 mp4 mpeg mudflap multilib ncurses networkmanager nls nptl ogg openexr opengl openmp pam pango pch pcre pdf phonon plasma png policykit ppds pppd private-headers pulseaudio qt3support qt4 quicktime readline samba schroedinger sdl semantic-desktop session smp sndfile spell sse sse2 sse3 sse4 sse4_1 sse4_2 ssl ssse3 startup-notification subversion svg tcpd theora threads threadsafe tiff truetype udev udisks unicode upnp upower usb v4l vaapi vcd vim-syntax vorbis vpx wifi wmf wxwidgets x264 xcb xcomposite xml xscreensaver xv xvid xvmc zeroconf zlib" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" FOO2ZJS_DEVICES="hp1020" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="pl_PL pl en_US en" PHP_TARGETS="php5-3" PYTHON_TARGETS="python3_2 python2_7" QEMU_SOFTMMU_TARGETS="i386 x86_64" QEMU_USER_TARGETS="i386 x86_64" RUBY_TARGETS="ruby19" USERLAND="GNU" VIDEO_CARDS="i965 intel" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 Pacho Ramos gentoo-dev 2012-09-15 12:41:45 UTC
Will ask pkgconfig maintainers to try to know why .pc file is being wrongly generated
Comment 2 Bartosz Brachaczek 2012-09-15 16:21:49 UTC
(In reply to comment #1)
> Will ask pkgconfig maintainers to try to know why .pc file is being wrongly
> generated

It's just a bug in their configure.in. They export -L${libjpeg_prefix}/lib in GDIPLUS_PKG_LIBS for use by libgdiplus.pc.in, and they don't define libjpeg_prefix in the .pc file. And they have very similar code for handling tiff and libgif, yet they don't include -L${libtiff_prefix}/lib nor -L${libgif_prefix}/lib in their .pc file. All their autoconf code is broken, it's need a substantial rewrite. Even the .pc files are broken, there is no excuse for libgdiplus.pc to export -ljpeg -lgif etc. in Libs.

For Gentoo simply sed'ing the generated libgdiplus.pc to remove '-L${libjpeg_prefix}/lib' will be fine.
Comment 3 Jack 2012-11-08 18:53:41 UTC
I wonder if the priority or importance of this needs to be increased, as it has a secondary effect.  Running "pkg-config --list-all" aborts on generating that error - so it outputs an abbreviated list of packages.  It's certainly not critical, but I did waste some time wondering why "pkg-config --list-all" produced a much shorter list than the number of .pc files in the pkgconfig directory.   (Yes, manually applying the fix from Comment #2 did fix the problem for me.)
Comment 4 Samuli Suominen (RETIRED) gentoo-dev 2012-11-09 13:41:14 UTC
(In reply to comment #3)
> I wonder if the priority or importance of this needs to be increased, as it
> has a secondary effect.  Running "pkg-config --list-all" aborts on
> generating that error - so it outputs an abbreviated list of packages.  It's
> certainly not critical, but I did waste some time wondering why "pkg-config
> --list-all" produced a much shorter list than the number of .pc files in the
> pkgconfig directory.   (Yes, manually applying the fix from Comment #2 did
> fix the problem for me.)

with what, dev-util/pkgconfig, dev-util/pkgconf, or something else?
Comment 5 Jack 2012-11-09 14:13:30 UTC
Samuli - thanks for making me think. :-)

I suppose I should reword my question as asking whether there is any point in opening a separate bug against dev-util/pkgconfig so a problem in a .pc file (such as described in this bug) does not cause pkg-config to fail.  (I don't use pkgconf, so I don't know whether it has the same problem or not.)
Comment 6 Pacho Ramos gentoo-dev 2013-05-24 20:30:14 UTC
Would be better to try to patch libgdiplus.pc.in than sedding .pc file after it being wrongly generated during building
Comment 7 Fabio Rossi 2013-12-10 14:51:48 UTC
Created attachment 365050 [details, diff]
libgdiplus-2.10.9-configure.patch

here is a simple patch, the ebuild needs of course a run of eautoconf
Comment 8 Jack 2014-12-20 22:30:02 UTC
Still not fixed in the -r1 ebuild, which is stable, nor the -r2, which is still ~.

I filed bug 533146 against pkgconfig, to see if it can be made to simplly ignore invalid pc files.
Comment 9 Doug Goldstein (RETIRED) gentoo-dev 2016-01-17 05:57:23 UTC
Its two years since someone provided a patch and there has not been any action by the .NET maintainers. Is this package orphaned or is the Gentoo .NET project orphaned?
Comment 10 Matthew Thode ( prometheanfire ) archtester Gentoo Infrastructure gentoo-dev Security 2016-11-20 02:22:23 UTC
with a new gdiplus becoming stable soon I hope this problem just 'goes away' https://bugs.gentoo.org/show_bug.cgi?id=570434
Comment 11 Pacho Ramos gentoo-dev 2017-07-23 11:24:45 UTC
that version is stable now