diff options
| author | 2015-07-22 15:46:15 -0400 | |
|---|---|---|
| committer | 2015-07-22 15:46:15 -0400 | |
| commit | b83cc37ae2d4d1b60ba3e77cb9740b52bbaf0cbf (patch) | |
| tree | 26d0baf978cbdf2d826c9486bb9c8992f117746c /scripts | |
| parent | f395bf7dd363ba8fbae3e5ff1bf10e5ee48ca882 (diff) | |
| parent | 7769689bd7625289fe2416a21d8971060f17fe2b (diff) | |
Merge pull request #257 from 0-wiz-0/master
Re-add NetBSD support.
Diffstat (limited to 'scripts')
| -rw-r--r-- | scripts/src/3rdparty.lua | 12 | ||||
| -rw-r--r-- | scripts/toolchain.lua | 29 |
2 files changed, 40 insertions, 1 deletions
diff --git a/scripts/src/3rdparty.lua b/scripts/src/3rdparty.lua index 889a6737cd5..5247517dce0 100644 --- a/scripts/src/3rdparty.lua +++ b/scripts/src/3rdparty.lua @@ -534,6 +534,13 @@ project "portmidi" MAME_DIR .. "3rdparty/portmidi/porttime/ptlinux.c", } end + if _OPTIONS["targetos"]=="netbsd" then + files { + MAME_DIR .. "3rdparty/portmidi/pm_linux/pmlinux.c", + MAME_DIR .. "3rdparty/portmidi/pm_linux/finddefault.c", + MAME_DIR .. "3rdparty/portmidi/porttime/ptlinux.c", + } + end if _OPTIONS["targetos"]=="macosx" then files { MAME_DIR .. "3rdparty/portmidi/pm_mac/pmmac.c", @@ -591,6 +598,11 @@ project "bgfx" MAME_DIR .. "3rdparty/bx/include/compat/freebsd", } + configuration { "netbsd" } + includedirs { + MAME_DIR .. "3rdparty/bx/include/compat/freebsd", + } + configuration { "gmake" } buildoptions { "-Wno-uninitialized", diff --git a/scripts/toolchain.lua b/scripts/toolchain.lua index 91d1f29884e..589db7bc6fa 100644 --- a/scripts/toolchain.lua +++ b/scripts/toolchain.lua @@ -24,6 +24,7 @@ newoption { { "mingw-clang", "MinGW (clang compiler)" }, { "nacl", "Native Client" }, { "nacl-arm", "Native Client - ARM" }, + { "netbsd", "NetBSD" }, { "osx", "OSX (GCC compiler)" }, { "osx-clang", "OSX (Clang compiler)" }, { "pnacl", "Native Client - PNaCl" }, @@ -147,6 +148,10 @@ function toolchain(_buildDir, _subDir) location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-freebsd") end + if "netbsd" == _OPTIONS["gcc"] then + location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-netbsd") + 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++" @@ -590,7 +595,29 @@ function toolchain(_buildDir, _subDir) configuration { "freebsd", "x64", "Debug" } targetdir (_buildDir .. "freebsd" .. "/bin/x64/Debug") - + + configuration { "netbsd", "x32" } + objdir (_buildDir .. "netbsd" .. "/obj") + buildoptions { + "-m32", + } + configuration { "netbsd", "x32", "Release" } + targetdir (_buildDir .. "netbsd" .. "/bin/x32/Release") + + configuration { "netbsd", "x32", "Debug" } + targetdir (_buildDir .. "netbsd" .. "/bin/x32/Debug") + + configuration { "netbsd", "x64" } + objdir (_buildDir .. "netbsd" .. "/obj") + buildoptions { + "-m64", + } + configuration { "netbsd", "x64", "Release" } + targetdir (_buildDir .. "netbsd" .. "/bin/x64/Release") + + configuration { "netbsd", "x64", "Debug" } + targetdir (_buildDir .. "netbsd" .. "/bin/x64/Debug") + configuration { "android-*" } includedirs { "$(ANDROID_NDK_ROOT)/sources/cxx-stl/gnu-libstdc++/4.8/include", |
