Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 305491 - dev-libs/nspr.4.8.3 has incorrect nspr.pc
Summary: dev-libs/nspr.4.8.3 has incorrect nspr.pc
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Mozilla Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-02-17 08:53 UTC by whereami
Modified: 2010-02-21 01:12 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description whereami 2010-02-17 08:53:20 UTC
My emerge of dev-libs/nss-3.12.5-r1 would result in linker failures about missing symbols like PL_strlen. I eventually realized that this was due to a -L flag with nothing after it, making the subsequent -lplc4 flag be misinterpreted as a library path. I tracked this to 
NSPR_LIB_DIR=`pkg-config --libs-only-L nspr | sed 's/-L//'`
in the nss ebuild. That command yields no output.

nspr.pc has this line:
Libs: -R${libdir} -L${libdir} -lplds4 -lplc4 -lnspr4 -lpthread

I suspect that '-R' should be '-Wl,-R'. Somehow this means that even when only looking for -L, pkg-config isn't willing to print anything...

This nspr.pc comes from dev-libs/nspr/files/nspr-4.8-pkgconfig-gentoo-1.patch


I've since rolled back to stable nspr and nss (I didn't intend to install these versions; turns out my old unmasks for installing firefox 3.5 when it was new were just too wide), so I can't really reproduce this any more without having to recompile vast swaths of my system.

However, you should be able to reproduce by emerging nsnpr-4.8.3 and then nss-3.12.5-r1.
Comment 1 Jory A. Pratt gentoo-dev 2010-02-17 23:58:25 UTC
Your understanding is wrong, without proper emerge --info and being willing to work on the problem I see no way to address this issue. Reopen when you are willing to debug why your missing an export via the ebuild.
Comment 2 whereami 2010-02-18 02:05:29 UTC
I am willing to help debug. Turns out I didn't have to rebuild that many things due to nspr/nss. Sorry if I sounded unwilling before; I just wanted to move on and get a working system before coming back to this.

I'll provide emerge --info when I get back home. Sorry I didn't include it before; highlights off the top of my head include ARCH=amd64, CFLAGS="-O2 -march=athlon64", MAKEOPTS="-j2" (varying this had no effect)

If you read this in the meantime, can you clarify where you think my understanding is wrong?
Comment 3 Jory A. Pratt gentoo-dev 2010-02-18 02:19:20 UTC
Both these exports are run first.

	export PKG_CONFIG_ALLOW_SYSTEM_LIBS=1
	export PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1

This is how we are able to get a proper libpath for the libs we need.

	export NSPR_INCLUDE_DIR=`pkg-config --cflags-only-I nspr | sed 's/-I//'`
	export NSPR_LIB_DIR=`pkg-config --libs-only-L nspr | sed 's/-L//'`

If the exports do not happen, we will end up with a null return on NSPR_INCLUDES_DIR and NSPR_LIB_DIR. This is all well tested on amd64. Soon as you can please provide your emerge --info and your enviroment file so we can trace where your failure is actually occuring.
Comment 4 whereami 2010-02-18 04:42:02 UTC
# emerge --info
Portage 2.1.7.16 (default/linux/amd64/10.0/desktop, gcc-4.3.4, glibc-2.10.1-r1, 2.6.29-gentoo-r5 x86_64)
=================================================================
System uname: Linux-2.6.29-gentoo-r5-x86_64-AMD_Athlon-tm-_64_Processor_3200+-with-gentoo-1.12.13
Timestamp of tree: Wed, 17 Feb 2010 06:30:01 +0000
distcc 3.1 x86_64-pc-linux-gnu [disabled]
ccache version 2.4 [disabled]
app-shells/bash:     4.0_p35
dev-java/java-config: 2.1.10
dev-lang/python:     2.4.6, 2.5.4-r3, 2.6.4
dev-util/ccache:     2.4-r7
dev-util/cmake:      2.6.4-r3
sys-apps/baselayout: 1.12.13
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.13, 2.63-r1
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc:       3.4.6-r2, 4.1.2, 4.2.4, 4.3.4
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6b
virtual/os-headers:  2.6.27-r2
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA Q3AEULA dlj-1.1 skype-eula ut2003"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=athlon64"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-O2 -march=athlon64"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests distlocks fixpackages news parallel-fetch protect-owned sandbox sfperms strict unmerge-logs unmerge-orphans userfetch"
GENTOO_MIRRORS="http://gentoo.osuosl.org/distfiles http://cudlug.cudenver.edu/gentoo/distfiles"
LANG="C"
LDFLAGS="-Wl,-O1"
LINGUAS="en en_US utf8"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/science /usr/portage/local/layman/sunrise /usr/portage/local"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext X a52 aac aalib acl acpi alsa amd64 ao bash-completion berkdb branding bzip2 cairo cd cdparanoia cdr cli consolekit cpufreq cracklib crypt css cups curl cxx dbus dri dts dvd dvdr dvdread eds emboss encode evo exif expat fam fbcon ffmpeg firefox flac foomaticdb fortran fuse gdbm gif glitz glut gpm gstreamer gtk hal iconv idn imagemagick imlib ipv6 java jpeg ladspa lame lcms ldap libcaca libnotify libsamplerate lm_sensors mad matroska mikmod mmx mmxext mng modules mp3 mp4 mpeg mudflap multilib musicbrainz ncurses network nls nptl nptlonly nvidia ogg openal opengl openmp pam pcre pdf pic png ppds pppd python qt3support qt4 quicktime raw readline reflection rtc samba sdl session spell spl sse sse2 ssl startup-notification svg sysfs tcpd theora threads thunar tiff truetype unicode usb vdpau vim-syntax vorbis x264 xcb xine xinerama xml xml2 xorg xscreensaver xulrunner xv xvid xvmc zlib" ALSA_CARDS="emu10k1" 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 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" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en en_US utf8" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="nvidia vesa" 
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LC_ALL, MAKEOPTS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 5 whereami 2010-02-18 05:01:06 UTC
I made a mistake in my original report: It was nss-3.12.5 (stable), not -r1 (unstable) that failed to emerge, and it was with nspr-4.8.3-r2 (unstable), not 4.8.3 (stable).

These versions of nss and nspr ebuilds are probably just incompatible, and given their different states of stability should not be expected to work together.

emerging only the unstable (nspr-4.8.3-r2 and nss-3.12.5-r1) versions works fine.

So, this is just user error, perhaps with a little missing dependency checks mixed in. I'm closing as invalid. Sorry for your time.
Comment 6 Jory A. Pratt gentoo-dev 2010-02-21 01:12:40 UTC
(In reply to comment #5)
> I made a mistake in my original report: It was nss-3.12.5 (stable), not -r1
> (unstable) that failed to emerge, and it was with nspr-4.8.3-r2 (unstable), not
> 4.8.3 (stable).
> 
> These versions of nss and nspr ebuilds are probably just incompatible, and
> given their different states of stability should not be expected to work
> together.
> 
> emerging only the unstable (nspr-4.8.3-r2 and nss-3.12.5-r1) versions works
> fine.
> 
> So, this is just user error, perhaps with a little missing dependency checks
> mixed in. I'm closing as invalid. Sorry for your time.
> 

Glad you figured out where you problem was, I double checked the ebuild, and based off your findings I am lead to believe you have an older version of the tree before I fixed the dep. Sorry this caused used problem. Please never hesitate to file a bug if you believe you have a valid bug or just need help.