libsdl2: fix secondary arch build.

This commit is contained in:
Adrien Destugues
2018-02-02 09:43:14 +01:00
parent cb7175c3e5
commit 363aa5f013
2 changed files with 59 additions and 11 deletions

View File

@@ -6,7 +6,7 @@ software, emulators, and popular games."
HOMEPAGE="http://www.libsdl.org/"
COPYRIGHT="1997-2017 Sam Lantinga"
LICENSE="Zlib"
REVISION="1"
REVISION="2"
SOURCE_URI="http://www.libsdl.org/release/SDL2-$portVersion.tar.gz"
CHECKSUM_SHA256="ee35c74c4313e2eda104b14b1b86f7db84a04eeab9430d56e001cea268bf4d5e"
SOURCE_DIR="SDL2-$portVersion"

View File

@@ -1,4 +1,4 @@
From 357b0e7d9842be41636f498d740f45395e4e1a02 Mon Sep 17 00:00:00 2001
From 5b995581729cb06e58f1d71cb286135951e5d2a5 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Fri, 29 Aug 2014 15:24:11 +0000
Subject: haiku patch
@@ -27,20 +27,20 @@ index 6bf7a17..0b60466 100644
&location)) == B_OK) {
return location;
--
2.13.1
2.15.1
From 9da1e4aee27290c16c7b20eb67fe1c6a90087fe1 Mon Sep 17 00:00:00 2001
From 6cb2a822e56dcd960dd788b84fd7ea48e67caa2a Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Thu, 25 Feb 2016 20:23:41 +0000
Subject: remove nacl, missing templates on Haiku
diff --git a/configure.in b/configure.in
index e91851e..7d85a5d 100644
index 5ac2130..fbfe2cc 100644
--- a/configure.in
+++ b/configure.in
@@ -1527,33 +1527,6 @@ AC_HELP_STRING([--enable-mir-shared], [dynamically load Mir support [[default=ma
@@ -1530,33 +1530,6 @@ AC_HELP_STRING([--enable-mir-shared], [dynamically load Mir support [[default=ma
fi
}
@@ -75,20 +75,20 @@ index e91851e..7d85a5d 100644
{
AC_ARG_ENABLE(video-rpi,
--
2.13.1
2.15.1
From aa9490806bacc5ae684bc416c2263f9bf1dc70f0 Mon Sep 17 00:00:00 2001
From f289ca347419e84ab5bce1e0f9992ea56289ed57 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Sat, 30 Sep 2017 13:36:12 +0200
Subject: fix AC_DEFINE
diff --git a/configure.in b/configure.in
index 7d85a5d..6f48fef 100644
index fbfe2cc..c77e630 100644
--- a/configure.in
+++ b/configure.in
@@ -1826,7 +1826,7 @@ int event_type = XI_TouchBegin;
@@ -1829,7 +1829,7 @@ int event_type = XI_TouchBegin;
XITouchClassInfo *t;
],[
have_xinput2_multitouch=yes
@@ -98,5 +98,53 @@ index 7d85a5d..6f48fef 100644
])
AC_MSG_RESULT($have_xinput2_multitouch)
--
2.13.1
2.15.1
From 289f0c1f881d64367c560e913f686cf45adaa567 Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Fri, 2 Feb 2018 09:40:46 +0100
Subject: Fix secondary arch build.
Rather than trying to guess the name of libstdc++, run libtool in C++
mode so it figures this out by itself. The previous way of detecting
libstdc++ would not allow for building a secondary architecture package.
diff --git a/Makefile.in b/Makefile.in
index fe56652..47d9c82 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -143,13 +143,13 @@ update-revision:
.PHONY: all update-revision install install-bin install-hdrs install-lib install-data uninstall uninstall-bin uninstall-hdrs uninstall-lib uninstall-data clean distclean dist $(OBJECTS:.lo=.d)
$(objects)/$(TARGET): $(GEN_HEADERS) $(GEN_OBJECTS) $(OBJECTS) $(VERSION_OBJECTS)
- $(RUN_CMD_LTLINK)$(LIBTOOL) --tag=CC --mode=link $(CC) -o $@ $(OBJECTS) $(GEN_OBJECTS) $(VERSION_OBJECTS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(LT_LDFLAGS)
+ $(RUN_CMD_LTLINK)$(LIBTOOL) --tag=CXX --mode=link $(CXX) -o $@ $(OBJECTS) $(GEN_OBJECTS) $(VERSION_OBJECTS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(LT_LDFLAGS)
$(objects)/$(SDLMAIN_TARGET): $(SDLMAIN_OBJECTS)
- $(RUN_CMD_LTLINK)$(LIBTOOL) --tag=CC --mode=link $(CC) -static -o $@ $(SDLMAIN_OBJECTS) -rpath $(libdir)
+ $(RUN_CMD_LTLINK)$(LIBTOOL) --tag=CXX --mode=link $(CXX) -static -o $@ $(SDLMAIN_OBJECTS) -rpath $(libdir)
$(objects)/$(SDLTEST_TARGET): $(SDLTEST_OBJECTS)
- $(RUN_CMD_LTLINK)$(LIBTOOL) --tag=CC --mode=link $(CC) -static -o $@ $(SDLTEST_OBJECTS) -rpath $(libdir)
+ $(RUN_CMD_LTLINK)$(LIBTOOL) --tag=CXX --mode=link $(CXX) -static -o $@ $(SDLTEST_OBJECTS) -rpath $(libdir)
install: all install-bin install-hdrs install-lib install-data
install-bin:
diff --git a/configure.in b/configure.in
index c77e630..ffb09bb 100644
--- a/configure.in
+++ b/configure.in
@@ -3595,9 +3595,6 @@ AC_HELP_STRING([--enable-render-d3d], [enable the Direct3D render driver [[defau
# The Haiku platform requires special setup.
SOURCES="$srcdir/src/main/haiku/*.cc $SOURCES"
EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lroot -lbe -lmedia -lgame -ldevice -ltextencoding"
- # Haiku's x86 spins use libstdc++.r4.so (for binary compat?), but
- # other spins, like x86-64, use a more standard "libstdc++.so.*"
- AC_CHECK_FILE("/boot/system/lib/libstdc++.r4.so", EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lstdc++.r4", EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lstdc++")
;;
arm*-apple-darwin*|*-ios-*)
ARCH=ios
--
2.15.1