Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#12654 - [cryptsetup] fail to build/libcrypt
Attached to Project:
Arch Linux
Opened by Baho Utot (baho-utot) - Saturday, 03 January 2009, 15:51 GMT
Last edited by Thomas Bächler (brain0) - Sunday, 07 June 2009, 13:24 GMT
Opened by Baho Utot (baho-utot) - Saturday, 03 January 2009, 15:51 GMT
Last edited by Thomas Bächler (brain0) - Sunday, 07 June 2009, 13:24 GMT
|
DetailsDescription:
cryptsetup build fails because of static library missing libgcrypt.a From the cryptsetup makepkg build: gcc -march=native -mtune=generic -O2 -pipe -fomit-frame-pointer -o cryptsetup -static cryptsetup.o -lpopt ../lib/.libs/libcryptsetup.a -ldevmapper -lgcrypt -lgpg-error -luuid /usr/bin/ld: cannot find -lgcrypt Needs to build static library in libgcrypt Additional info: * package version: current abs Steps to reproduce: run makepkg on abs cryptsetup attached is a PKGBUILD patch for libgcrypt |
This task depends upon
Closed by Thomas Bächler (brain0)
Sunday, 07 June 2009, 13:24 GMT
Reason for closing: Fixed
Additional comments about closing: Next version of libgcrypt includes the static lib again. We really should move to something else than klibc soon.
Sunday, 07 June 2009, 13:24 GMT
Reason for closing: Fixed
Additional comments about closing: Next version of libgcrypt includes the static lib again. We really should move to something else than klibc soon.
PKGBUILD.patch
Even though cryptsetup is set to shared libs in the configure when watching the build you will see it build the shared libs first then build for static libs.
Here is the log entry from the build showing the static build
if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I.. -I../lib -DDATADIR=\""/usr/share"\" -DLOCALEDIR=\""/usr/share/locale"\" -DLIBDIR=\""/usr/lib"\" -DPREFIX=\""/usr"\" -DSYSCONFDIR=\""/usr/etc"\" -DVERSION=\""1.0.6"\" -D_GNU_SOURCE -march=i686 -mtune=generic -O2 -pipe -MT cryptsetup.o -MD -MP -MF ".deps/cryptsetup.Tpo" -c -o cryptsetup.o cryptsetup.c; \
then mv -f ".deps/cryptsetup.Tpo" ".deps/cryptsetup.Po"; else rm -f ".deps/cryptsetup.Tpo"; exit 1; fi
/bin/sh ../libtool --tag=CC --mode=link gcc -march=i686 -mtune=generic -O2 -pipe -o cryptsetup -all-static cryptsetup.o -lpopt ../lib/libcryptsetup.la
mkdir .libs
See the -all-static ?
This was from a build where I built the static libs from libgcrypt
Maybe there is another way but I haven't been successful otherwise.
cd $startdir/src/$pkgname-$pkgver
./configure --prefix=/usr --enable-static
make || return 1
# include a static cryptsetup binary for initrd setups
install -D -m755 src/cryptsetup $startdir/pkg/sbin/cryptsetup.static || return 1
# install hook
install -D -m644 $startdir/src/encrypt_hook $startdir/pkg/lib/initcpio/hooks/encrypt
install -D -m644 $startdir/src/encrypt_install $startdir/pkg/lib/initcpio/install/encrypt
This is the bad boy.
See the static in configure?
I don't know if the static build is required
Right now, a static build is the only solution.