[Debian GNUstep maintainers] Bug#633543: cynthiune.app: FTBFS with ld that defaults to --as-needed: undefined reference to `convert8to16'

Colin Watson cjwatson at ubuntu.com
Mon Jul 11 12:42:30 UTC 2011

Package: cynthiune.app
Version: 0.9.5-13
Severity: important
Tags: patch
User: ubuntu-devel at lists.ubuntu.com
Usertags: origin-ubuntu ubuntu-patch oneiric

I noticed that somebody had synced the base GNUstep packages from
experimental into Ubuntu oneiric, so I started work on rebuilding all
the application packages against that new version so that we can drop
the older library versions.  cynthiune.app failed to build as follows:


  gcc -shared  -rdynamic  -L../../Frameworks/Cynthiune/Cynthiune.framework/Versions/Current -lCynthiune     -Wl,-z,defs -Wl,--as-needed -Wl,-rpath,/usr/lib/cynthiune.app -shared-libgcc -fexceptions -o ./AudioFile.format/./AudioFile ./obj/AudioFile.obj/AudioFile.m.o      -L/usr/local/lib -L/usr/lib   -L/usr/lib -laudiofile -lm    -lgnustep-gui    -lgnustep-base   -lpthread -lobjc   -lm
  ./obj/AudioFile.obj/AudioFile.m.o: In function `-[AudioFile _readNext8BitChunk:withSize:]':
  /build/buildd/cynthiune.app-0.9.5/Bundles/AudioFile/AudioFile.m:122: undefined reference to `convert8to16'

It appears that link-libs.patch needs to be extended to cover this;
-lCynthiune is clearly in the wrong place on the link line for
--as-needed (http://wiki.debian.org/ToolChain/DSOLinking).  This
probably doesn't affect Debian right now because --as-needed is a
positional option and only affects those libraries listed after it, but
Ubuntu's linker defaults to --as-needed right out of the gate.
Nevertheless, I believe that the debian-gcc team is tracking these
problems and wants to make Debian packages work cleanly with such a

Here's a patch.  Does it seem like a reasonable approach?

  * debian/patches/link-libs.patch: Use ADDITIONAL_GUI_LIBS rather than
    ADDITIONAL_LDFLAGS in frameworks.make.

diff -u cynthiune.app-0.9.5/debian/patches/link-libs.patch cynthiune.app-0.9.5/debian/patches/link-libs.patch
--- cynthiune.app-0.9.5/debian/patches/link-libs.patch
+++ cynthiune.app-0.9.5/debian/patches/link-libs.patch
@@ -33,6 +33,8 @@
 	* Bundles/Taglib/GNUmakefile.preamble (ADDITIONAL_LDFLAGS)
 	(BUNDLE_LIBS): Likewise.
 	(TAGLIB_LIBS): Link only against libtaglib_c.
+	* frameworks.make (ADDITIONAL_LDFLAGS): Rename as...
 --- cynthiune.app-0.9.5.orig/Frameworks/Cynthiune/GNUmakefile
 +++ cynthiune.app-0.9.5/Frameworks/Cynthiune/GNUmakefile
@@ -209,0 +212,9 @@
+--- cynthiune.app-0.9.5.orig/frameworks.make
++++ cynthiune.app-0.9.5/frameworks.make
+@@ -10,5 +10,5 @@
+ ifeq (mingw32, $(GNUSTEP_TARGET_OS))
+ ADDITIONAL_GUI_LIBS += -L$(FRAMEWORKS_DIRS)/../../Cynthiune.app $(_ldflags)
+ else
+-ADDITIONAL_LDFLAGS += $(_ldflags)
++ADDITIONAL_GUI_LIBS += $(_ldflags)
+ endif


Colin Watson                                       [cjwatson at ubuntu.com]

More information about the pkg-GNUstep-maintainers mailing list