Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 546894

Summary: sys-fs/cryptsetup-1.6.7: cannot emerge a static binary
Product: Gentoo Linux Reporter: qdii <qdii>
Component: [OLD] Core systemAssignee: Gentoo Linux bug wranglers <bug-wranglers>
Status: RESOLVED INVALID    
Severity: normal CC: floppym
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: Log from emerge -NuD lvm2 cryptsetup
emerge --info cryptsetup

Description qdii 2015-04-17 09:34:03 UTC
Created attachment 401444 [details]
Log from emerge -NuD lvm2 cryptsetup

This is from a fresh install.

Steps to reproduce:
1. modify USE flags to force a static build:
echo "sys-fs/cryptsetup static -dynamic static-libs" >> /etc/portage/package.use/cryptsetup
echo "sys-fs/lvm2 static -dynamic static-libs" >> /etc/portage/package.use/lvm2

2. emerge both packages:
emerge -NuD lvm2 cryptsetup

3. notice that cryptsetup are dynamically link to shared objects:
ldd /sbin/cryptsetup
        …
        libattr.so.1 => /lib64/libattr.so.1 (0x00007fd96603c000)
        libcryptsetup.so.4 => …


Expected result:
/sbin/cryptsetup should not depend on any shared object

I need a static binary for my initramfs.
Comment 1 qdii 2015-04-17 09:35:06 UTC
Created attachment 401446 [details]
emerge --info cryptsetup
Comment 2 Mike Gilbert gentoo-dev 2015-04-23 17:18:19 UTC
You are using a systemd profile, which masks the "static" and "static-libs" use flags.