Package: alpine Version: 2.01-1 Severity: normal Tags: patch alpine uses symbols from libkrb5 and libcrypto, but does not link those libraries directly.
Currently this does not cause a build failure because libkrb5 is linked as a result of linking libgssapi, and libcrypto is linked by linking libssl. However, it does cause build failures on Ubuntu Natty due to changes in the linker configuration, and it will cause similar failures in Wheezy for the same reason (see http://wiki.debian.org/ToolChain/DSOLinking) I've attached a patch that fixes the issue in a fairly minimal way as a straw man. Please let me know if you're not planning to upload fixes during the Squeeze freeze, so that I can go ahead and fix this in Ubuntu.
diff -u alpine-2.02/debian/changelog alpine-2.02/debian/changelog --- alpine-2.02/debian/changelog +++ alpine-2.02/debian/changelog @@ -1,3 +1,9 @@ +alpine (2.02-1ubuntu1) natty; urgency=low + + * Fix FTBFS due to linking issues. + + -- Evan Broder <e...@ebroder.net> Tue, 26 Oct 2010 06:31:32 -0700 + alpine (2.02-1) unstable; urgency=low * New upstream release, based on re-alpine project diff -u alpine-2.02/debian/control alpine-2.02/debian/control --- alpine-2.02/debian/control +++ alpine-2.02/debian/control @@ -1,7 +1,8 @@ Source: alpine Section: mail Priority: optional -Maintainer: Asheesh Laroia <ashe...@asheesh.org> +Maintainer: Ubuntu Developers <ubuntu-devel-disc...@lists.ubuntu.com> +XSBC-Original-Maintainer: Asheesh Laroia <ashe...@asheesh.org> Uploaders: Andreas Tille <ti...@debian.org> Build-Depends: debhelper (>= 5), libldap2-dev, libpam0g-dev, libncurses-dev, libssl-dev, autotools-dev, ca-certificates, automake, autoconf, libtool, libkrb5-dev, diff -u alpine-2.02/debian/patches/series alpine-2.02/debian/patches/series --- alpine-2.02/debian/patches/series +++ alpine-2.02/debian/patches/series @@ -9,0 +10 @@ +90_fix_linking.patch only in patch2: unchanged: --- alpine-2.02.orig/debian/patches/90_fix_linking.patch +++ alpine-2.02/debian/patches/90_fix_linking.patch @@ -0,0 +1,179 @@ +Index: alpine/configure.ac +=================================================================== +--- alpine.orig/configure.ac 2010-10-26 06:48:10.045558658 -0700 ++++ alpine/configure.ac 2010-10-26 06:49:42.375344745 -0700 +@@ -1004,6 +1004,7 @@ + [ + LIBS="$LIBS -lssl" + ]) ++ AC_SEARCH_LIBS(X509_free,crypto,,[alpine_SSLTYPE=none]) + if test "x$alpine_SSLTYPE" = "xnone" ; then + AC_MSG_NOTICE([OpenSSL libraries NOT found]) + else +@@ -1028,6 +1029,11 @@ + alpine_GSSTYPE="none" + alpine_gss_none_reason="libraries not found" + ]) ++ AC_SEARCH_LIBS(krb5_init_context,krb5,:, ++ [ ++ alpine_GSSTYPE="none" ++ alpine_gss_none_reason="libraries not found" ++ ]) + if test -n "$alpine_gss_none_reason" ; then + AC_MSG_NOTICE([NOT including Kerberos Support: $alpine_gss_none_reason]) + fi +Index: alpine/configure +=================================================================== +--- alpine.orig/configure 2010-10-26 06:48:10.205191765 -0700 ++++ alpine/configure 2010-10-26 06:49:48.096205312 -0700 +@@ -15472,7 +15472,7 @@ + alpine_SSLTYPE="none" + else + case $host in +- *-linux-gnu) ++ *-linux-gnu*) + if test -f /etc/fedora-release -o -f /etc/redhat-release -o -f /etc/redhat_version ; then + alpine_SSLTYPE="nopwd" + if test -d /etc/pki/tls ; then +@@ -16358,6 +16358,64 @@ + + fi + ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing X509_free" >&5 ++$as_echo_n "checking for library containing X509_free... " >&6; } ++if test "${ac_cv_search_X509_free+set}" = set; then : ++ $as_echo_n "(cached) " >&6 ++else ++ ac_func_search_save_LIBS=$LIBS ++cat confdefs.h - <<_ACEOF >conftest.$ac_ext ++/* end confdefs.h. */ ++ ++/* Override any GCC internal prototype to avoid an error. ++ Use char because int might match the return type of a GCC ++ builtin and then its argument prototype would still apply. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++char X509_free (); ++int ++main () ++{ ++return X509_free (); ++ ; ++ return 0; ++} ++_ACEOF ++for ac_lib in '' crypto; do ++ if test -z "$ac_lib"; then ++ ac_res="none required" ++ else ++ ac_res=-l$ac_lib ++ LIBS="-l$ac_lib $ac_func_search_save_LIBS" ++ fi ++ if ac_fn_c_try_link "$LINENO"; then : ++ ac_cv_search_X509_free=$ac_res ++fi ++rm -f core conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext ++ if test "${ac_cv_search_X509_free+set}" = set; then : ++ break ++fi ++done ++if test "${ac_cv_search_X509_free+set}" = set; then : ++ ++else ++ ac_cv_search_X509_free=no ++fi ++rm conftest.$ac_ext ++LIBS=$ac_func_search_save_LIBS ++fi ++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_X509_free" >&5 ++$as_echo "$ac_cv_search_X509_free" >&6; } ++ac_res=$ac_cv_search_X509_free ++if test "$ac_res" != no; then : ++ test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" ++ ++else ++ alpine_SSLTYPE=none ++fi ++ + if test "x$alpine_SSLTYPE" = "xnone" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: OpenSSL libraries NOT found" >&5 + $as_echo "$as_me: OpenSSL libraries NOT found" >&6;} +@@ -16443,6 +16501,67 @@ + + fi + ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing krb5_init_context" >&5 ++$as_echo_n "checking for library containing krb5_init_context... " >&6; } ++if test "${ac_cv_search_krb5_init_context+set}" = set; then : ++ $as_echo_n "(cached) " >&6 ++else ++ ac_func_search_save_LIBS=$LIBS ++cat confdefs.h - <<_ACEOF >conftest.$ac_ext ++/* end confdefs.h. */ ++ ++/* Override any GCC internal prototype to avoid an error. ++ Use char because int might match the return type of a GCC ++ builtin and then its argument prototype would still apply. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++char krb5_init_context (); ++int ++main () ++{ ++return krb5_init_context (); ++ ; ++ return 0; ++} ++_ACEOF ++for ac_lib in '' krb5; do ++ if test -z "$ac_lib"; then ++ ac_res="none required" ++ else ++ ac_res=-l$ac_lib ++ LIBS="-l$ac_lib $ac_func_search_save_LIBS" ++ fi ++ if ac_fn_c_try_link "$LINENO"; then : ++ ac_cv_search_krb5_init_context=$ac_res ++fi ++rm -f core conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext ++ if test "${ac_cv_search_krb5_init_context+set}" = set; then : ++ break ++fi ++done ++if test "${ac_cv_search_krb5_init_context+set}" = set; then : ++ ++else ++ ac_cv_search_krb5_init_context=no ++fi ++rm conftest.$ac_ext ++LIBS=$ac_func_search_save_LIBS ++fi ++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_krb5_init_context" >&5 ++$as_echo "$ac_cv_search_krb5_init_context" >&6; } ++ac_res=$ac_cv_search_krb5_init_context ++if test "$ac_res" != no; then : ++ test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" ++ : ++else ++ ++ alpine_GSSTYPE="none" ++ alpine_gss_none_reason="libraries not found" ++ ++fi ++ + if test -n "$alpine_gss_none_reason" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: NOT including Kerberos Support: $alpine_gss_none_reason" >&5 + $as_echo "$as_me: NOT including Kerberos Support: $alpine_gss_none_reason" >&6;} +@@ -18733,7 +18852,7 @@ + + + case "$host" in +- *-linux-gnu*|*-k*bsd*-gnu*|*-*-gnu*) ++ *-linux-gnu*|*-k*bsd*-gnu*) + alpine_path_delim="/" + alpine_mode_readonly="(0600)" + if test -f /etc/fedora-release ; then