Build Nazara on macos up to Nazara_network (not included

This commit is contained in:
ImperatorS79
2020-11-21 20:05:19 +01:00
parent d243e7bcd2
commit 4bf49876c6
13 changed files with 158 additions and 18 deletions

View File

@@ -158,6 +158,15 @@ function NazaraBuild:Execute()
"../src/",
"../thirdparty/include"
})
if (os.ishost("macosx")) then
includedirs({
"../include",
"../src/",
"../thirdparty/include",
"/usr/local/include/" --brew
})
end
files(moduleTable.Files)
excludes(moduleTable.FilesExcluded)
@@ -171,6 +180,14 @@ function NazaraBuild:Execute()
"../thirdparty/lib/common",
"../lib"
})
if (os.ishost("macosx")) then
libdirs({
"../thirdparty/lib/common",
"../lib",
"/usr/local/lib" --brew
})
end
-- Output to lib/conf/arch
self:FilterLibDirectory("../lib/", targetdir)
@@ -928,7 +945,10 @@ end
function NazaraBuild:PostconfigGenericProject()
-- Add options required for C++17 thread and filesystem (have to be linked last)
filter("action:gmake*")
filter({"action:gmake*", "system:macosx"})
links("pthread")
filter({"action:gmake*", "system:not macosx"})
links("stdc++fs")
links("pthread")

View File

@@ -21,11 +21,15 @@ MODULE.OsDefines.Windows = {
"SDL_VIDEO_DRIVER_WINDOWS=1"
}
MODULE.OsDefines.Posix = {
"SDL_VIDEO_DRIVER_X11=1",
"SDL_VIDEO_DRIVER_WAYLAND=1",
}
MODULE.DynLib = {
"SDL2"
}
MODULE.Custom = function()
filter("system:linux")
defines("SDL_VIDEO_DRIVER_X11=1")
defines("SDL_VIDEO_DRIVER_WAYLAND=1")
filter("system:macosx")
defines("SDL_VIDEO_DRIVER_COCOA=1")
end