Source: guichan Version: 0.8.2 Severity: important Tags: patch
Dear Maintainer, Some applications using the guichan library fail to start when guichan is built using the toolchain in Ubuntu 11.10 or later. This is likely to also be a problem in upcoming Debian toolchain releases. A typical application startup error is as follows. legacy/legacy: symbol lookup error: /usr/lib/libguichan_sdl-0.8.1.so.1: undefined symbol: IMG_Load The attached patch modifies the build order so library symbols are resolved correctly at link time without missing any. See also Ubuntu bug https://bugs.launchpad.net/ubuntu/+source/guichan/+bug/871548 for more information.
Description: Added dependent link libraries to SDL back end to prevent missing symbols at run time due to newer linker. Affects configure.in and some Makefile.am file, other files are regenerated. Author: Stephen M. Webb <stephen.w...@bregmasoft.ca> Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/guichan/+bug/871548 --- a/configure.in +++ b/configure.in @@ -114,8 +114,7 @@ HaveSDLImage() { SDLIMAGE="yes" - SDL_LIBS="$SDL_LIBS -lSDL_image" - CPPFLAGS="$CPPFLAGS `sdl-config --cflags`" + PKG_CHECK_MODULES([SDL], [sdl SDL_image]) } ForceSDLImage() --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,4 +1,4 @@ -SUBDIRS = widgets @GUICHAN_EXTRADIRS@ hge openlayer contrib +SUBDIRS = widgets . @GUICHAN_EXTRADIRS@ hge openlayer contrib INCLUDES = -I$(top_srcdir)/include --- a/src/opengl/Makefile.am +++ b/src/opengl/Makefile.am @@ -2,6 +2,7 @@ INCLUDES = -I$(top_srcdir)/include +libguichan_opengl_la_LIBADD = $(top_builddir)/src/libguichan.la libguichan_opengl_la_LDFLAGS = -no-undefined -release $(LT_RELEASE) -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) libguichan_opengl_la_SOURCES = \ --- a/src/sdl/Makefile.am +++ b/src/sdl/Makefile.am @@ -4,6 +4,8 @@ INCLUDES = -I$(top_srcdir)/include +libguichan_sdl_la_CPPFLAGS = $(SDL_CFLAGS) +libguichan_sdl_la_LIBADD = $(top_builddir)/src/libguichan.la $(SDL_LIBS) libguichan_sdl_la_LDFLAGS = -no-undefined -release $(LT_RELEASE) -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) libguichan_sdl_la_SOURCES = \