Package: bbtime
Version: 0.1.5-12
Severity: minor
Tags: patch
User: debian-...@lists.debian.org
Usertags: ld-as-needed

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1



*** /tmp/tmp9yX78W
In Ubuntu, the attached patch was applied to achieve the following:

  * debian/patches/002-fix-as-needed.dpatch: (LP: #765966)
    Libraries should go into X_LIBS instead of LDFLAGS to fix
    building with ld --as-needed.

See http://lists.debian.org/debian-devel-announce/2011/02/msg00011.html
and http://wiki.debian.org/ToolChain/DSOLinking#Onlylinkwithneededlibraries

for more information.

Thanks for considering the patch.


- -- System Information:
Debian Release: wheezy/sid
  APT prefers oneiric
  APT policy: (500, 'oneiric')
Architecture: amd64 (x86_64)

Kernel: Linux 3.0.0-999-generic (SMP w/2 CPU cores)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/dash

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iQIcBAEBAgAGBQJOB3sHAAoJEGHzRCZ03mYkJUoQAKSlIDLEY/bp54WQk10huipz
PKDFbf4aPGM2fzvj/q20RGwWVPUoZDGg00H9h0+KMF9WV/mIormG0PLIuDW9YvrR
b2T5PqwBX/W643xtI/Cg5y8oCf4PBO0sPQRSAeh5CRCkdXXAgzn8tnsXZMWjSfzK
kk9aG5cfFLcrgGfyOACsM5eJlG/7N5x1wHZBDyufQBUGH5ubmfZX6W5C4nPdea4j
3OFqZuaiEX3rwRrj4cAakdFSJtu8gysgD5Z+nJEq4rYaY9lW2kUvIhd0kD+Zb/6E
Y0EWIjTwRLcYbaPyeMjXy5Cq5/bmuiY3tM0onHZsl0g9nP+V8/sWW3MbXCPdF1a1
x5YLxBSL0oEinXS04mZ1by8eX/F04FC/1GTcI1+0t5n8YSRftsmE056uIq5gMtnG
rjomCQRaLi/a3UixNg2/SodCzSmvEdhHcSCqtJ8WEpDsHvaFmFiQihP/mvyqycmu
R87xXz+3YraDVEIwL3gQgIh0DTKJpM6wcng3Lf7IC4BJ++hVOsCbkCNJLak5lK54
4NIDgfj8sL43xWfN9DCLuknBOTEB5uDIRdaEivtnkodYdvmPGNGY3JL8GE2WIPyC
2swjYM4j1suIhjoDPlpCUsXkEI2Bcir7y8gN0QRTtUSMFp/RuFXOFqEPyi1mfI/I
1NqS9vleT58E94psqAe+
=R3kQ
-----END PGP SIGNATURE-----
=== added file 'debian/patches/002-fix-as-needed.dpatch'
--- debian/patches/002-fix-as-needed.dpatch	1970-01-01 00:00:00 +0000
+++ debian/patches/002-fix-as-needed.dpatch	2011-06-26 18:29:44 +0000
@@ -0,0 +1,32 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+Description: Fix FTBFS with ld --as-needed, libraries should go
+ into X_LIBS instead of LDFLAGS. For an explanation, see
+ http://lists.debian.org/debian-devel-announce/2011/02/msg00011.html
+Author: Andreas Moog
+Bug-Ubuntu: https://bugs.launchpad.net/bugs/765966
+
+@DPATCH@
+diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' bbtime~/configure bbtime/configure
+--- bbtime~/configure	2011-06-26 18:25:58.000000000 +0000
++++ bbtime/configure	2011-06-26 18:26:46.763143964 +0000
+@@ -2290,7 +2290,7 @@
+ fi
+ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+   echo "$ac_t""yes" 1>&6
+-  LDFLAGS="$LDFLAGS -lX11"
++  X_LIBS="$X_LIBS -lX11"
+ else
+   echo "$ac_t""no" 1>&6
+ { echo "configure: error: XOpenDisplay not found in -lX11" 1>&2; exit 1; }
+diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' bbtime~/configure.in bbtime/configure.in
+--- bbtime~/configure.in	2011-06-26 18:25:58.000000000 +0000
++++ bbtime/configure.in	2011-06-26 18:26:46.763143964 +0000
+@@ -51,7 +51,7 @@
+ CXXFLAGS="$CXXFLAGS $X_CFLAGS"
+ LDFLAGS="$LDFLAGS $X_LIBS $X_PRE_LIBS"
+ dnl Checks for X libraries.
+-AC_CHECK_LIB(X11, XOpenDisplay, LDFLAGS="$LDFLAGS -lX11",
++AC_CHECK_LIB(X11, XOpenDisplay, X_LIBS="$X_LIBS -lX11",
+              AC_MSG_ERROR(XOpenDisplay not found in -lX11))
+ 
+ LDFLAGS="$LDFLAGS $X_EXTRA_LIBS"

=== modified file 'debian/patches/00list'
--- debian/patches/00list	2007-08-14 14:32:07 +0000
+++ debian/patches/00list	2011-06-26 18:26:49 +0000
@@ -1 +1,2 @@
 001_Makefile_nostrip
+002-fix-as-needed.dpatch

Reply via email to