diff options
Diffstat (limited to 'emulators/mame/patches')
-rw-r--r-- | emulators/mame/patches/patch-3rdparty_genie_build_gmake.darwin_genie.make | 26 | ||||
-rw-r--r-- | emulators/mame/patches/patch-makefile | 22 | ||||
-rw-r--r-- | emulators/mame/patches/patch-scripts_toolchain.lua | 51 |
3 files changed, 94 insertions, 5 deletions
diff --git a/emulators/mame/patches/patch-3rdparty_genie_build_gmake.darwin_genie.make b/emulators/mame/patches/patch-3rdparty_genie_build_gmake.darwin_genie.make new file mode 100644 index 00000000000..a82091e0798 --- /dev/null +++ b/emulators/mame/patches/patch-3rdparty_genie_build_gmake.darwin_genie.make @@ -0,0 +1,26 @@ +$NetBSD: patch-3rdparty_genie_build_gmake.darwin_genie.make,v 1.1 2018/10/11 08:20:54 adam Exp $ + +Do not set optimization level, nor minimal macOS version. + +--- 3rdparty/genie/build/gmake.darwin/genie.make.orig 2018-10-10 17:27:27.000000000 +0000 ++++ 3rdparty/genie/build/gmake.darwin/genie.make +@@ -50,13 +50,13 @@ ifeq ($(config),release) + INCLUDES += -I"../../src/host/lua-5.3.0/src" + INCLUDES += + ALL_CPPFLAGS += $(CPPFLAGS) -MMD -MP -MP $(DEFINES) $(INCLUDES) +- ALL_ASMFLAGS += $(ASMFLAGS) $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra -Os -mmacosx-version-min=10.4 +- ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra -Os -mmacosx-version-min=10.4 +- ALL_CXXFLAGS += $(CXXFLAGS) $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra -Os -mmacosx-version-min=10.4 +- ALL_OBJCFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra -Os -mmacosx-version-min=10.4 +- ALL_OBJCPPFLAGS += $(CXXFLAGS) $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra -Os -mmacosx-version-min=10.4 ++ ALL_ASMFLAGS += $(ASMFLAGS) $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra ++ ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra ++ ALL_CXXFLAGS += $(CXXFLAGS) $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra ++ ALL_OBJCFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra ++ ALL_OBJCPPFLAGS += $(CXXFLAGS) $(CFLAGS) $(ALL_CPPFLAGS) $(ARCH) -Wall -Wextra + ALL_RESFLAGS += $(RESFLAGS) $(DEFINES) $(INCLUDES) +- ALL_LDFLAGS += $(LDFLAGS) -L. -mmacosx-version-min=10.4 ++ ALL_LDFLAGS += $(LDFLAGS) -L. + LDDEPS += + LIBS += $(LDDEPS) -framework CoreServices + EXTERNAL_LIBS += diff --git a/emulators/mame/patches/patch-makefile b/emulators/mame/patches/patch-makefile index de6a60dba94..60c91181189 100644 --- a/emulators/mame/patches/patch-makefile +++ b/emulators/mame/patches/patch-makefile @@ -1,11 +1,12 @@ -$NetBSD: patch-makefile,v 1.20 2017/09/09 22:40:58 dholland Exp $ +$NetBSD: patch-makefile,v 1.21 2018/10/11 08:20:54 adam Exp $ Treat all BSDs the same. +Do not set compiler optimization. Add missing rules for building with clang on FreeBSD and NetBSD. ---- makefile.orig 2017-03-29 03:12:20.000000000 +0000 +--- makefile.orig 2018-08-29 00:35:24.000000000 +0000 +++ makefile -@@ -180,19 +180,19 @@ GENIEOS := solaris +@@ -190,19 +190,19 @@ GENIEOS := solaris endif ifeq ($(firstword $(filter FreeBSD,$(UNAME))),FreeBSD) OS := freebsd @@ -29,7 +30,18 @@ Add missing rules for building with clang on FreeBSD and NetBSD. endif ifeq ($(firstword $(filter Darwin,$(UNAME))),Darwin) OS := macosx -@@ -1357,6 +1357,23 @@ freebsd_x86: generate $(PROJECTDIR)/$(MA +@@ -566,10 +566,6 @@ PROFILER = + SYMBOLS = 1 + endif + +-# specify a default optimization level if none explicitly stated +-ifndef OPTIMIZE +-OPTIMIZE = 3 +-endif + + # set the symbols level + ifdef SYMBOLS +@@ -1395,6 +1391,23 @@ freebsd_x86: generate $(PROJECTDIR)/$(MA $(SILENT) $(MAKE) -C $(PROJECTDIR)/$(MAKETYPE)-freebsd config=$(CONFIG)32 #------------------------------------------------- @@ -53,7 +65,7 @@ Add missing rules for building with clang on FreeBSD and NetBSD. # gmake-netbsd #------------------------------------------------- -@@ -1377,6 +1394,23 @@ netbsd_x86: generate $(PROJECTDIR)/$(MAK +@@ -1415,6 +1428,23 @@ netbsd_x86: generate $(PROJECTDIR)/$(MAK $(SILENT) $(MAKE) -C $(PROJECTDIR)/$(MAKETYPE)-netbsd config=$(CONFIG)32 #------------------------------------------------- diff --git a/emulators/mame/patches/patch-scripts_toolchain.lua b/emulators/mame/patches/patch-scripts_toolchain.lua new file mode 100644 index 00000000000..bcc1b1d683e --- /dev/null +++ b/emulators/mame/patches/patch-scripts_toolchain.lua @@ -0,0 +1,51 @@ +$NetBSD: patch-scripts_toolchain.lua,v 1.3 2018/10/11 08:20:54 adam Exp $ + +Allow Clang on FreeBSD, NetBSD, and OpenBSD. + +--- scripts/toolchain.lua.orig 2018-09-26 04:43:31.000000000 +0000 ++++ scripts/toolchain.lua +@@ -23,6 +23,7 @@ newoption { + { "android-x64", "Android - x64" }, + { "asmjs", "Emscripten/asm.js" }, + { "freebsd", "FreeBSD" }, ++ { "freebsd-clang", "FreeBSD (clang compiler)"}, + { "linux-gcc", "Linux (GCC compiler)" }, + { "linux-clang", "Linux (Clang compiler)" }, + { "ios-arm", "iOS - ARM" }, +@@ -31,7 +32,9 @@ newoption { + { "mingw64-gcc", "MinGW64" }, + { "mingw-clang", "MinGW (clang compiler)" }, + { "netbsd", "NetBSD" }, ++ { "netbsd-clang", "NetBSD (clang compiler)"}, + { "openbsd", "OpenBSD" }, ++ { "openbsd-clang", "OpenBSD (clang compiler)"}, + { "osx", "OSX (GCC compiler)" }, + { "osx-clang", "OSX (Clang compiler)" }, + { "pnacl", "Native Client - PNaCl" }, +@@ -168,14 +171,26 @@ function toolchain(_buildDir, _subDir) + location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-freebsd") + end + ++ if "freebsd-clang" == _OPTIONS["gcc"] then ++ location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-freebsd-clang") ++ end ++ + if "netbsd" == _OPTIONS["gcc"] then + location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-netbsd") + end + ++ if "netbsd-clang" == _OPTIONS["gcc"] then ++ location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-netbsd-clang") ++ end ++ + if "openbsd" == _OPTIONS["gcc"] then + location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-openbsd") + end + ++ if "openbsd-clang" == _OPTIONS["gcc"] then ++ location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-openbsd-clang") ++ end ++ + if "ios-arm" == _OPTIONS["gcc"] then + premake.gcc.cc = "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang" + premake.gcc.cxx = "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++" |