premake for debug and release
This commit is contained in:
parent
d319cbeba3
commit
1def3ea22e
96
premake5.lua
96
premake5.lua
@ -122,6 +122,26 @@ workspace "efsw"
|
||||
configurations { "debug", "release", "relwithdbginfo" }
|
||||
platforms { "x86_64", "x86", "ARM", "ARM64" }
|
||||
|
||||
-- GLOBAL CONFIGURATION (Applies to ALL projects below)
|
||||
filter "configurations:debug"
|
||||
defines { "DEBUG" }
|
||||
symbols "On"
|
||||
runtime "Debug" -- This forces /MDd everywhere
|
||||
|
||||
filter "configurations:release"
|
||||
defines { "NDEBUG" }
|
||||
optimize "On"
|
||||
runtime "Release" -- This forces /MD everywhere
|
||||
|
||||
filter "configurations:relwithdbginfo"
|
||||
defines { "NDEBUG" }
|
||||
symbols "On"
|
||||
optimize "On"
|
||||
runtime "Release"
|
||||
|
||||
-- Reset filter so project-specific settings work
|
||||
filter "*"
|
||||
|
||||
if os.istarget("windows") then
|
||||
osfiles = "src/efsw/platform/win/*.cpp"
|
||||
else
|
||||
@ -157,25 +177,6 @@ workspace "efsw"
|
||||
files { "src/efsw/*.cpp", osfiles }
|
||||
conf_excludes()
|
||||
|
||||
filter "configurations:debug"
|
||||
defines { "DEBUG" }
|
||||
symbols "On"
|
||||
targetname "efsw-static-debug"
|
||||
conf_warnings()
|
||||
|
||||
filter "configurations:release"
|
||||
defines { "NDEBUG" }
|
||||
optimize "On"
|
||||
targetname "efsw-static-release"
|
||||
conf_warnings()
|
||||
|
||||
filter "configurations:relwithdbginfo"
|
||||
defines { "NDEBUG" }
|
||||
symbols "On"
|
||||
optimize "On"
|
||||
targetname "efsw-static-reldbginfo"
|
||||
conf_warnings()
|
||||
|
||||
project "efsw-test"
|
||||
kind "ConsoleApp"
|
||||
language "C++"
|
||||
@ -184,25 +185,6 @@ workspace "efsw"
|
||||
includedirs { "include", "src" }
|
||||
conf_links()
|
||||
|
||||
filter "configurations:debug"
|
||||
defines { "DEBUG" }
|
||||
symbols "On"
|
||||
targetname "efsw-test-debug"
|
||||
conf_warnings()
|
||||
|
||||
filter "configurations:release"
|
||||
defines { "NDEBUG" }
|
||||
optimize "On"
|
||||
targetname "efsw-test-release"
|
||||
conf_warnings()
|
||||
|
||||
filter "configurations:relwithdbginfo"
|
||||
defines { "NDEBUG" }
|
||||
symbols "On"
|
||||
optimize "On"
|
||||
targetname "efsw-test-reldbginfo"
|
||||
conf_warnings()
|
||||
|
||||
project "joomer-efsw-file-monitoring"
|
||||
kind "ConsoleApp"
|
||||
language "C++"
|
||||
@ -219,25 +201,6 @@ workspace "efsw"
|
||||
includedirs { "include", "src" }
|
||||
conf_links()
|
||||
|
||||
filter "configurations:debug"
|
||||
defines { "DEBUG" }
|
||||
symbols "On"
|
||||
targetname "efsw-test-stdc-debug"
|
||||
conf_warnings()
|
||||
|
||||
filter "configurations:release"
|
||||
defines { "NDEBUG" }
|
||||
optimize "On"
|
||||
targetname "efsw-test-stdc-release"
|
||||
conf_warnings()
|
||||
|
||||
filter "configurations:relwithdbginfo"
|
||||
defines { "NDEBUG" }
|
||||
symbols "On"
|
||||
optimize "On"
|
||||
targetname "efsw-test-stdc-reldbginfo"
|
||||
conf_warnings()
|
||||
|
||||
project "efsw-shared-lib"
|
||||
kind "SharedLib"
|
||||
language "C++"
|
||||
@ -248,25 +211,6 @@ workspace "efsw"
|
||||
conf_excludes()
|
||||
conf_links()
|
||||
|
||||
filter "configurations:debug"
|
||||
defines { "DEBUG" }
|
||||
symbols "On"
|
||||
targetname "efsw-debug"
|
||||
conf_warnings()
|
||||
|
||||
filter "configurations:release"
|
||||
defines { "NDEBUG" }
|
||||
optimize "On"
|
||||
targetname "efsw"
|
||||
conf_warnings()
|
||||
|
||||
filter "configurations:relwithdbginfo"
|
||||
defines { "NDEBUG" }
|
||||
symbols "On"
|
||||
optimize "On"
|
||||
targetname "efsw"
|
||||
conf_warnings()
|
||||
|
||||
if os.istarget("linux") or os.istarget("bsd") or os.istarget("haiku") then
|
||||
targetextension ( ".so." .. efsw_version )
|
||||
postbuildcommands { "sh ../../project/build.reldbginfo.sh " .. efsw_major_version .. " " .. efsw_minor_version .. " " .. efsw_patch_version .. " " .. iif( _OPTIONS["strip-symbols"], "strip-symbols", "" ) }
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user