Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 392701 - net-libs/pjsip-1.12 is not installing python library
Summary: net-libs/pjsip-1.12 is not installing python library
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Jean-Noël Rivasseau (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-01 06:02 UTC by Jon Wagoner
Modified: 2012-12-23 11:22 UTC (History)
1 user (show)

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 Jon Wagoner 2011-12-01 06:02:29 UTC
With the Python USE flag enabled, pjsip should build a python library, but it fails to compile.  The build output is:

python setup.py build
running build
running build_py
running build_ext
building '_pjsua' extension
x86_64-pc-linux-gnu-gcc -pthread -fPIC -DPJ_AUTOCONF=1 -Imake[1]: Entering directory `/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip-apps/src/python' -I-DPJ_IS_BIG_ENDIAN=0 -I-DPJ_IS_LITTLE_ENDIAN=1 -I/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjlib/include -I/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjlib-util/include -I/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjnath/include -I/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjmedia/include -I/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip/include -Imake[1]: Leaving directory `/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip-apps/src/python' -I/usr/include/python2.7 -c _pjsua.c -o build/temp.linux-x86_64-2.7/_pjsua.o
warning: no library file corresponding to 'make[1]: Entering directory `/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip-apps/src/python'' found (skipping)
warning: no library file corresponding to 'make[1]: Leaving directory `/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip-apps/src/python'' found (skipping)
x86_64-pc-linux-gnu-gcc -pthread -shared build/temp.linux-x86_64-2.7/_pjsua.o -Lmake[1]: Entering directory `/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip-apps/src/python' -L/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjlib/lib -L/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjlib-util/lib -L/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjnath/lib -L/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjmedia/lib -L/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip/lib -L/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/third_party/lib -Lmake[1]: Leaving directory `/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip-apps/src/python' -L/usr/lib64 -lpjsua -lpjsip-ua -lpjsip-simple -lpjsip -lpjmedia-codec -lpjmedia -lpjmedia-audiodev -lpjnath -lpjlib-util -lresample -lmilenage -lsrtp -lportaudio -lpj -lm -luuid -lnsl -lrt -lpthread -lasound -lcrypto -lssl -lopencore-amrnb -lpython2.7 -o build/lib.linux-x86_64-2.7/_pjsua.so
/usr/lib/gcc/x86_64-pc-linux-gnu/4.5.3/../../../../x86_64-pc-linux-gnu/bin/ld: /var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip/lib/libpjsua.a(pjsua_acc.o): relocation R_X86_64_32 against `pjsua_var' can not be used when making a shared object; recompile with -fPIC
/var/tmp/portage/net-libs/pjsip-1.12/work/pjproject-1.12/pjsip/lib/libpjsua.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
error: command 'x86_64-pc-linux-gnu-gcc' failed with exit status 1




Reproducible: Always

Steps to Reproduce:
1. USE="python" emerge pjsip

Actual Results:  
No python library built/installed

Expected Results:  
python library built/installed

Portage 2.1.10.39 (default/linux/amd64/10.0/developer, gcc-4.5.3, glibc-2.14.1-r1, 3.1.3-gentoo x86_64)
=================================================================
System uname: Linux-3.1.3-gentoo-x86_64-AMD_Athlon-tm-_64_X2_Dual_Core_Processor_6000+-with-gentoo-2.1
Timestamp of tree: Wed, 30 Nov 2011 08:45:01 +0000
distcc 3.1 x86_64-pc-linux-gnu [disabled]
ccache version 3.1.6 [disabled]
app-shells/bash:          4.2_p20
dev-java/java-config:     2.1.11-r3
dev-lang/python:          2.7.2-r3, 3.2.2
dev-util/ccache:          3.1.6
dev-util/cmake:           2.8.6-r4
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.1
sys-apps/openrc:          0.9.4
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.68
sys-devel/automake:       1.10.3, 1.11.1-r1
sys-devel/binutils:       2.22
sys-devel/gcc:            4.5.3-r1
sys-devel/gcc-config:     1.5-r2
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 2.6.39 (virtual/os-headers)
sys-libs/glibc:           2.14.1-r1
Repositories: gentoo jon-local
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=athlon64 -fomit-frame-pointer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/openvpn/easy-rsa /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.4/ext-active/ /etc/php/cgi-php5.4/ext-active/ /etc/php/cli-php5.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe -march=athlon64 -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs distlocks ebuild-locks fixlafiles news parallel-fetch protect-owned sandbox sfperms sign splitdebug strict test-fail-continue unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox"
FFLAGS=""
GENTOO_MIRRORS="http://gentoo.mirrors.pair.com/ http://open-systems.ufl.edu/mirrors/gentoo http://mirror.datapipe.net/gentoo http://osmirrors.cerias.purdue.edu/pub/gentoo/ http://gentoo.mirrors.easynews.com/linux/gentoo/"
LANG="en_US.UTF-8"
LDFLAGS="-Wl,--hash-style=gnu -Wl,-O1 -Wl,--as-needed"
LINGUAS="en"
MAKEOPTS="-j3"
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/local/portage/jon"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext X a52 aac acl acpi alsa amd64 amr bash-completion berkdb bzip2 cairo cdda cdr cli consolekit cracklib crypt cups cxx dbus dri dts dvd dvdr emboss encode exif fam ffmpeg firefox flac gdu gif gpm gtk jpeg kde lcms libnotify lzma lzo mad mmx mmxext mng modules mp3 mp4 mpeg mudflap multilib ncurses nls nptl nptlonly ogg opengl pam pango pch pcre pdf phonon png policykit ppds pppd pulseaudio python qt3support qt4 readline sdl semantic-desktop session spell sse sse2 ssl startup-notification svg sysfs tiff truetype udev unicode usb v4l2 vim-syntax vorbis x264 xattr xcb xine xinerama xml xorg xulrunner xv xvid zeroconf zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" 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 stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" 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="keyboard evdev mouse" KERNEL="linux" LCD_DEVICES="g15 xosd" LINGUAS="en" LIRC_DEVICES="serial" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="nvidia vesa nouveau" 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, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Jon Wagoner 2012-02-21 16:01:20 UTC
Adding -fPIC to the CFLAGS for this package enables the library to be built.

I found the documentation about pic problems, and tried looking at the makefile to make a proper patch, but I couldn't follow the makefile well enough to do this.
Comment 2 Jean-Noël Rivasseau (RETIRED) gentoo-dev 2012-12-23 11:22:02 UTC
Seems OK in 1.14.