Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 120829 - libselinux 1.28 appears to have hardcoded Python-2.4 dependency
Summary: libselinux 1.28 appears to have hardcoded Python-2.4 dependency
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Other
: High major (vote)
Assignee: Chris PeBenito (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-29 09:50 UTC by Ed Wildgoose
Modified: 2006-01-29 12:02 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 Ed Wildgoose 2006-01-29 09:50:43 UTC
Have been bashing my head wondering why the standard stage 3 hardened stage rebuild subsequently fails when I run "emerge -e system", always falling over when building libselinux

The problem appears to be that when everything is rebuilt, libselinux is upgraded from 1.22-r1 to 1.28 and the newer libselinux appears to die needing "/usr/include/python2.4/Python.h".  The default version of python is 2.3 on the current hardened stages.

I think it's swig which is hardcoded to need python2.4, but something is explicitly setting the build command line to look for Python.h in the /usr/include/python2.4 directory - which does not exist in the standard stage

I simply did an "emerge python" and upgraded to 2.4 and not libselinux builds OK.

I think this is a higher severity than normal because it appears to hit anyone downloading and trying to use the current hardened stages.

The first issue is possibly that libselinux seems to need swig (and this is not listed in the ebuild dependencies).  The second thing is that something is hardcoding in the paths for Python 2.4 as part of the build

Probably someone who knows these ebuilds better can quickly point out the best place to add in the missing dependency statement


The errors look like this:

cc -march=pentium4 -O2 -fomit-frame-pointer -pipe -I../include -I/usr/include -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/python2.4 -fpic -DSHARED -c -o selinuxswig_wrap.lo selinuxswig_wrap.c
ar rcs libselinux.a avc.o avc_internal.o avc_sidtab.o booleans.o canonicalize_context.o checkAccess.o check_context.o compute_av.o compute_create.o compute_member.o compute_relabel.o compute_user.o context.o disable.o enabled.o fgetfilecon.o freecon.o freeconary.o fsetfilecon.o get_context_list.o get_default_type.o getcon.o getenforce.o getexeccon.o getfilecon.o getfscreatecon.o getpeercon.o getpidcon.o getprevcon.o init.o is_customizable_type.o lgetfilecon.o load_policy.o lsetfilecon.o matchmediacon.o matchpathcon.o policyvers.o query_user_context.o rpm.o selinux_config.o setcon.o setenforce.o setexeccon.o setfilecon.o setfscreatecon.o seusers.o trans.o
selinuxswig_wrap.c:22:20: Python.h: No such file or directory
ranlib libselinux.a
cc  -shared -o libselinux.so.1 avc.lo avc_internal.lo avc_sidtab.lo booleans.lo canonicalize_context.lo checkAccess.lo check_context.lo compute_av.lo compute_create.lo compute_member.lo compute_relabel.lo compute_user.lo context.lo disable.lo enabled.lo fgetfilecon.lo freecon.lo freeconary.lo fsetfilecon.lo get_context_list.lo get_default_type.lo getcon.lo getenforce.lo getexeccon.lo getfilecon.lo getfscreatecon.lo getpeercon.lo getpidcon.lo getprevcon.lo init.lo is_customizable_type.lo lgetfilecon.lo load_policy.lo lsetfilecon.lo matchmediacon.lo matchpathcon.lo policyvers.lo query_user_context.lo rpm.lo selinux_config.lo setcon.lo setenforce.lo setexeccon.lo setfilecon.lo setfscreatecon.lo seusers.lo trans.lo -ldl -lsepol -L/usr/lib -Wl,-soname,libselinux.so.1,-z,defs
selinuxswig_wrap.c:622: error: parse error before "PyObject_HEAD"
selinuxswig_wrap.c:622: warning: no semicolon at end of struct or union
selinuxswig_wrap.c:625: error: parse error before '}' token
selinuxswig_wrap.c:625: warning: data definition has no type or storage class
selinuxswig_wrap.c:630: error: parse error before '*' token
selinuxswig_wrap.c: In function `PySwigObject_print':
selinuxswig_wrap.c:633: error: `v' undeclared (first use in this function)
selinuxswig_wrap.c:633: error: (Each undeclared identifier is reported only once
selinuxswig_wrap.c:633: error: for each function it appears in.)
selinuxswig_wrap.c:634: error: `fp' undeclared (first use in this function)
selinuxswig_wrap.c: At top level:
selinuxswig_wrap.c:641: error: parse error before '*' token
selinuxswig_wrap.c:642: error: parse error before '*' token
selinuxswig_wrap.c: In function `PySwigObject_repr':
... repeats on for a long time ....
Comment 1 Chris PeBenito (RETIRED) gentoo-dev 2006-01-29 12:02:20 UTC
python version handling fixed, added swig dependency.