Skip to contentSkip to conversation

package/ltris: fix static linking with libmad

PATCH New Bernd Kuhls 2 participants 2 messages May 19, 2016 – May 25, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/ltris: fix static linking with libmad

Fixes
http://autobuild.buildroot.net/results/b06/b0671af6be81550221f5abf98c2c797787590199/

---
 package/ltris/ltris.mk | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
package/ltris/ltris.mk +6 -2
index e77f2ac..8cff4c1 100644
@@ -12,18 +12,22 @@ LTRIS_LICENSE_FILES = COPYING
 LTRIS_DEPENDENCIES = sdl
 
 LTRIS_CONF_ENV = \
-	SDL_CONFIG="$(STAGING_DIR)/usr/bin/sdl-config"
+	SDL_CONFIG="$(STAGING_DIR)/usr/bin/sdl-config" \
+	LIBS="$(LTRIS_LIBS)"
 
 ifeq ($(BR2_PACKAGE_LTRIS_AUDIO),y)
 LTRIS_DEPENDENCIES += sdl_mixer
 LTRIS_CONF_OPTS += --enable-audio=yes
+# configure script does NOT use pkg-config to figure out how to link
+# with sdl_mixer, breaking static linking as sdl_mixer can use libmad
+LTRIS_LIBS += `$(PKG_CONFIG_HOST_BINARY) --libs SDL_mixer`
 else
 LTRIS_CONF_OPTS += --disable-audio
 endif
 
 ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE),y)
 LTRIS_DEPENDENCIES += gettext
-LTRIS_CONF_ENV += LIBS=-lintl
+LTRIS_LIBS += -lintl
 endif
 
 $(eval $(autotools-package))
Signature · 1 line
2.8.1
#1 lore raw

PATCH 1/1 package/ltris: fix static linking with libmad

Quoted 18 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Bernd" == Bernd Kuhls <[email protected]> writes:

Fixes
http://autobuild.buildroot.net/results/b06/b0671af6be81550221f5abf98c2c797787590199/

---
 package/ltris/ltris.mk | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
package/ltris/ltris.mk +0 -0
index e77f2ac..8cff4c1 100644
@@ -12,18 +12,22 @@ LTRIS_LICENSE_FILES = COPYING
 LTRIS_DEPENDENCIES = sdl
 
 LTRIS_CONF_ENV = \

package/ltris/ltris.mk LTRIS_LICENSE_FILES = COPYING · line 23

Quoted 10 lines
package/ltris/ltris.mk +5 -1
-	SDL_CONFIG="$(STAGING_DIR)/usr/bin/sdl-config"
+	SDL_CONFIG="$(STAGING_DIR)/usr/bin/sdl-config" \
+	LIBS="$(LTRIS_LIBS)"
 
 ifeq ($(BR2_PACKAGE_LTRIS_AUDIO),y)
 LTRIS_DEPENDENCIES += sdl_mixer
 LTRIS_CONF_OPTS += --enable-audio=yes
+# configure script does NOT use pkg-config to figure out how to link
+# with sdl_mixer, breaking static linking as sdl_mixer can use libmad
+LTRIS_LIBS += `$(PKG_CONFIG_HOST_BINARY) --libs SDL_mixer`

We also need to ensure host-pkgconf is available, so I've added it to _DEPENDENCIES and committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard