Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 369089 - sys-libs/libsemanage-2.0.45 fails to emerge
Summary: sys-libs/libsemanage-2.0.45 fails to emerge
Status: VERIFIED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Hardened (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: SE Linux Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-28 20:29 UTC by Amadeusz Sławiński
Modified: 2011-07-22 11:11 UTC (History)
2 users (show)

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


Attachments
build.log (build.log,20.06 KB, text/plain)
2011-05-28 20:30 UTC, Amadeusz Sławiński
Details
Suggestion to limit python builds to the 2.x series (libsemanage-2.0.45.ebuild.patch,584 bytes, text/plain)
2011-06-21 20:06 UTC, Sven Vermeulen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Amadeusz Sławiński 2011-05-28 20:29:29 UTC
on suggestions from #gentoo-hardened already tried revdep-rebuild, python-updater
also using different swig versions

Reproducible: Always

Steps to Reproduce:
1. emerge libsemanage
Actual Results:  
fails to emerge

Expected Results:  
emerges and installs

emerge --info
Portage 2.2.0_alpha37 (hardened/linux/amd64/no-multilib/selinux, gcc-4.5.2, glibc-2.13-r2, 2.6.38-hardened-r6 x86_64)
=================================================================
System uname: Linux-2.6.38-hardened-r6-x86_64-Intel-R-_Core-TM-_i3_CPU_M_350_@_2.27GHz-with-gentoo-2.0.2
Timestamp of tree: Sat, 28 May 2011 17:30:01 +0000
app-shells/bash:          4.2_p10
dev-java/java-config:     2.1.11-r3
dev-lang/python:          2.7.1-r1, 3.2
dev-util/cmake:           2.8.4-r1
sys-apps/baselayout:      2.0.2
sys-apps/openrc:          0.8.2-r1
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.21
sys-devel/gcc:            4.5.2
sys-devel/gcc-config:     1.4.1-r1
sys-devel/libtool:        2.4-r1
sys-devel/make:           3.82
sys-kernel/linux-headers: 2.6.38 (virtual/os-headers)
sys-libs/glibc:           2.13-r2
Repositories: gentoo my_local_overlay
Installed sets: 
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA AdobeFlash-10.1 PUEL dlj-1.1 sun-bcla-java-vm"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/maven-bin-3.0/conf /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.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs distlocks ebuild-locks fixlafiles fixpackages news parallel-fetch preserve-libs protect-owned sandbox selinux sesandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS=""
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j2"
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"SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X alsa amd64 apache2 berkdb bzip2 cairo cgi cli cracklib crypt cups cxx dbus device-mapper dri fbcon fontconfig fuse gd gdbm gdu gif gpm gtk hardened iconv innodb ipv6 java jpeg jpeg2k justify libnotify lua mmx modules mudflap mysql ncurses nls nptl nptlonly nsplugin open_perms opengl openmp pam pcre perl php png policykit pppd pulseaudio python readline selinux session sse sse2 sse3 ssl ssse3 startup-notification sysfs system-sqlite tcpd threads tiff truetype udev unicode urandom v4l2 vim vim-syntax wifi xinerama xml xml2 xorg zlib zsh-completion" 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="braindump flow karbon kexi kpresenter krita tables words" 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="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" PHP_TARGETS="php5-3" QEMU_SOFTMMU_TARGETS="i386 x86_64" QEMU_USER_TARGETS="i386 x86_64" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="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, LINGUAS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Amadeusz Sławiński 2011-05-28 20:30:55 UTC
Created attachment 274941 [details]
build.log
Comment 2 Amadeusz Sławiński 2011-05-31 11:33:41 UTC
with USE="-python" it emerges
Comment 3 Amadeusz Sławiński 2011-05-31 19:51:42 UTC
So after looking some more at build.log and ebuild it seems to be caused by that it tries to build libsemanage using multiple python versions. It build fine with python2.7 but fails with python3.2
Comment 4 David 2011-06-08 19:49:11 UTC
I'm having the same issue with libsemanage. It appeared after doing a depclean and happens when trying to compile for 3.2, after success with 2.7. It appeared while doing a revdep-rebuild after the depclean and python-updater failed to fix the problem.


---------------

# emerge --info
FEATURES variable contains unknown value(s): loadpolicy
Portage 2.1.10 (selinux/v2refpolicy/amd64/hardened, gcc-4.5.2, glibc-2.13-r2, 2.6.39-hardened x86_64)
=================================================================
System uname: Linux-2.6.39-hardened-x86_64-Intel-R-_Core-TM-2_CPU_T5300_@_1.73GHz-with-gentoo-2.0.2
Timestamp of tree: Wed, 08 Jun 2011 18:45:01 +0000
app-shells/bash:          4.2_p10
dev-lang/python:          2.6.6-r2, 2.7.1-r1, 3.2
dev-util/cmake:           2.8.4-r1
sys-apps/baselayout:      2.0.2
sys-apps/openrc:          0.8.2-r1
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.68
sys-devel/automake:       1.9.6-r3, 1.10.3, 1.11.1-r1
sys-devel/binutils:       2.21
sys-devel/gcc:            4.5.2
sys-devel/gcc-config:     1.4.1-r1
sys-devel/libtool:        2.4-r1
sys-devel/make:           3.82-r1
sys-kernel/linux-headers: 2.6.38 (virtual/os-headers)
sys-libs/glibc:           2.13-r2
Repositories: gentoo hardened-dev sunrise
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=core2 -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/openvpn/easy-rsa"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=core2 -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs distlocks ebuild-locks fixlafiles fixpackages loadpolicy news parallel-fetch protect-owned sandbox selinux sesandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS=""
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
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="/var/lib/layman/hardened-development /var/lib/layman/sunrise"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="X a52 aac acl alsa amd64 apache2 artist-screen autoipd avahi avi berkdb bluetooth bzip2 cairo cdda cdio cdr cli colors consolekit cracklib crypt css cups cxx dbus device-mapper divx dri dv dvd dvdr dvdread dynamic encode extras faac fame ffmpeg flac fortran ftp fuse gd gdbm gdu gif git gnome gopher gstreamer gtk gzip hardened iconv ipv6 jpeg jpeg2k kerberos lame lastfmradio ldap libmpeg2 mad mjpeg modules mouse mp3 mp4 mpd mpeg mpg123 mplayer mudflap mysql nautilus ncurses networkmanager nls odbc ogg openmp pam pam_krb5 pam_ssh pcre perl php pic png policykit ppds pppd python qt4 quicktime rar readline samba sdl search-screen selinux session smp song-screen sqlite ssh ssl subtitles subversion suid svg symlink tcl tcpd theora threads tiff truetype udev unicode urandom v4l v4l2 vim-syntax vnc vorbis wavpack wifi winbind xft xml xmp xorg xvid zeroconf zip 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="braindump flow karbon kexi kpresenter krita tables words" 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 mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="fbdev glint intel mach64 mga neomagic nouveau nv r128 radeon savage sis tdfx trident vesa dummy v4l" 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, LINGUAS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 5 David 2011-06-08 20:45:09 UTC
running revdep-rebuild gives me this before attempting to recompile and failing.


---------------

 * Collecting system binaries and libraries
 * Generated new 1_files.rr
 * Collecting complete LD_LIBRARY_PATH
 * Generated new 2_ldpath.rr
 * Checking dynamic linking consistency
[ 77% ]  *   broken /usr/lib64/python3.1/site-packages/_semanage.so (requires libpython3.1.so.1.0)
[ 100% ]                 
 * Generated new 3_broken.rr
 * Assigning files to packages
 *   /usr/lib64/python3.1/site-packages/_semanage.so -> sys-libs/libsemanage
 * Generated new 4_raw.rr and 4_owners.rr
 * Cleaning list of packages to rebuild
Comment 6 Anthony Basile gentoo-dev 2011-06-08 22:10:23 UTC
(In reply to comment #5)
> running revdep-rebuild gives me this before attempting to recompile and
> failing.
> 
> 
> ---------------
> 
>  * Collecting system binaries and libraries
>  * Generated new 1_files.rr
>  * Collecting complete LD_LIBRARY_PATH
>  * Generated new 2_ldpath.rr
>  * Checking dynamic linking consistency
> [ 77% ]  *   broken /usr/lib64/python3.1/site-packages/_semanage.so (requires
> libpython3.1.so.1.0)
> [ 100% ]                 
>  * Generated new 3_broken.rr
>  * Assigning files to packages
>  *   /usr/lib64/python3.1/site-packages/_semanage.so -> sys-libs/libsemanage
>  * Generated new 4_raw.rr and 4_owners.rr
>  * Cleaning list of packages to rebuild

What version of python are you using?  eselect python list
Comment 7 David 2011-06-08 23:30:23 UTC
Available Python interpreters:
  [1]   python2.6
  [2]   python2.7 *
  [3]   python3.2
Comment 8 Sven Vermeulen 2011-06-13 11:03:08 UTC
Well, we can restrict the ebuild to only build with the Python 2 ABIs, using something similar as in policycoreutils-2.0.82.
Comment 9 Sven Vermeulen 2011-06-21 20:06:24 UTC
Created attachment 277713 [details]
Suggestion to limit python builds to the 2.x series

Suggested update on the ebuild to limit builds to the python 2.x series.

Comments greatly appreciated.
Comment 10 Sven Vermeulen 2011-06-29 13:01:07 UTC
Is now available in hardened-dev overlay
Comment 11 Sebastian Glita 2011-06-29 22:59:30 UTC
(In reply to comment #10)
> Is now available in hardened-dev overlay

actually, swig already supports for 2.x and 3.x both for Capsule and CObject.
Just src/semanage_wrap.c is old and should be swigify'ed before it is pywrap'ed.

propose this modification to `src_compile':

		building() {
			emake CC="$(tc-getCC)" PYLIBVER="python$(python_get_version)" "$@"
		}
		python_execute_function -s --source-dir src building -- swigify
		python_execute_function -s --source-dir src building -- pywrap
	fi
Comment 12 Sven Vermeulen 2011-07-04 18:11:39 UTC
Thanks. Although I have not a clue what that does, it does allow libsemanage to build for CPython 3.1. 

With this trick in mind, I'm going to check if the other package (policycoreutils) can be updated similarly.
Comment 13 Sven Vermeulen 2011-07-07 18:54:42 UTC
Suggested swigify fix is now in hardened-dev overlay.
policycoreutils also has fixes, but they're on python files generally (like indentation, print statements, ...) and not regarding swig.