Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 149632 - net-libs/adns-1.3 violates sandbox on install
Summary: net-libs/adns-1.3 violates sandbox on install
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: High normal
Assignee: Stefan Briesenick (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-09-30 10:27 UTC by Alexandre Rostovtsev (RETIRED)
Modified: 2006-09-30 15:25 UTC (History)
2 users (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 Alexandre Rostovtsev (RETIRED) gentoo-dev 2006-09-30 10:27:46 UTC
On an amd64 box:
# emerge adns
[...]
>>> Install adns-1.3 into /var/tmp/portage/adns-1.3/image/ category net-libs
set -e; for d in src dynamic client regress; do make -C $d install; done
make[1]: Entering directory `/var/tmp/portage/adns-1.3/work/adns-1.3/src'
mkdir -p /usr/lib64 /var/tmp/portage/adns-1.3/image//usr/include
set -xe; for f in libadns.a; \
                        do /bin/install -c -m 644 $f /usr/lib64/$f; done
+ for f in libadns.a
+ /bin/install -c -m 644 libadns.a /usr/lib64/libadns.a
ACCESS DENIED  unlink:    /usr/lib64/libadns.a
/bin/install: cannot remove `/usr/lib64/libadns.a': Permission denied
make[1]: *** [install] Error 1
make[1]: Leaving directory `/var/tmp/portage/adns-1.3/work/adns-1.3/src'
make: *** [install] Error 2


But on x86 machines:
# emerge adns
[...]
>>> Install adns-1.3 into /var/tmp/portage/adns-1.3/image/ category net-libs
set -e; for d in src dynamic client regress; do make -C $d install; done
make[1]: Entering directory `/var/tmp/portage/adns-1.3/work/adns-1.3/src'
mkdir -p /var/tmp/portage/adns-1.3/image//usr/lib /var/tmp/portage/adns-1.3/image//usr/include
set -xe; for f in libadns.a; \
                        do /bin/install -c -m 644 $f /var/tmp/portage/adns-1.3/image//usr/lib/$f; done
+ for f in libadns.a
+ /bin/install -c -m 644 libadns.a /var/tmp/portage/adns-1.3/image//usr/lib/libadns.a
[...]
>>> net-libs/adns-1.3 merged.

Both the x86 and the amd64 boxes have the same version of everything; emerge --info from the amd64:
Portage 2.1.2_pre2 (default-linux/amd64/2006.1/desktop, gcc-4.1.1, glibc-2.4-r4, 2.6.17-gentoo-r8 x86_64)
=================================================================
System uname: 2.6.17-gentoo-r8 x86_64 Intel(R) Core(TM)2 CPU          6600  @ 2.40GHz
Gentoo Base System version 1.12.5
Last Sync: Sat, 30 Sep 2006 15:30:01 +0000
distcc 2.18.3 x86_64-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
ccache version 2.4 [enabled]
app-admin/eselect-compiler: [Not Present]
dev-java/java-config: 1.3.7, 2.0.30
dev-lang/python:     2.4.3-r4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.4-r6
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.60
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.17
sys-devel/gcc-config: 1.3.13-r3
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r1
Comment 1 Jason Wever (RETIRED) gentoo-dev 2006-09-30 11:03:07 UTC
This also affects SPARC and probably others too.

Stefan, did this work for you on some arch before you committed it?
Comment 2 Stefan Briesenick (RETIRED) gentoo-dev 2006-09-30 14:14:09 UTC
ups. I tested it on x86 only. There it works w/o any problems.
I try to fix it asap.
Comment 3 Stefan Briesenick (RETIRED) gentoo-dev 2006-09-30 14:18:17 UTC
and yes, I have FEATURES="sandbox" enabled. :-/ I don't commit ebuilds which I haven't tested at least on 2 of my machines.
Comment 4 Stefan Briesenick (RETIRED) gentoo-dev 2006-09-30 14:24:44 UTC
ok, tested it on a amd64 machine now (I only have ssh access there). Indeed, *there* we have a sandbox violation. Seems to be a 64Bit only issue.
Comment 5 Jason Wever (RETIRED) gentoo-dev 2006-09-30 14:31:37 UTC
SPARC64 has a 64 bit kernel but the userland is completely 32 bits.  Weird though that it it would differ like that at the install phase for 64 bit arches but not 32.
Comment 6 Stefan Briesenick (RETIRED) gentoo-dev 2006-09-30 14:47:55 UTC
really strange!

on x86:
+ for f in libadns.a
+ /bin/install -c -m 644 libadns.a /var/gentoo/portage/adns-1.3/image//usr/lib/libadns.a

on amd64:
+ for f in libadns.a
+ /bin/install -c -m 644 libadns.a /usr/lib64/libadns.a

as you can see, x86 works as expected, on amd64 ${D} is missing. But I found the error. 

> make prefix=${D}/usr lib_dir=${D}/usr/$(get_libdir) install

must be changed to

> make prefix=${D}/usr libdir=${D}/usr/$(get_libdir) install

then it works on amd64.

obviously, the Makefile now uses 'libdir' variable instead of 'lib_dir'. But why does it still works on x86? :-/

But ok, I will commit a fixed ebuild (w/o new rev).
Comment 7 Stefan Briesenick (RETIRED) gentoo-dev 2006-09-30 14:49:36 UTC
ok, in CVS. Please test.
Comment 8 Jason Wever (RETIRED) gentoo-dev 2006-09-30 15:18:41 UTC
Works on SPARC now.  Thanks for fixing it :)
Comment 9 Stefan Briesenick (RETIRED) gentoo-dev 2006-09-30 15:25:47 UTC
ok ;)