Skip to content

Commit

Permalink
premake: add startrpoject; add lto option; fix copying of binary to g…
Browse files Browse the repository at this point in the history
…amedir; update premake5.exe
  • Loading branch information
withmorten committed Jan 10, 2021
1 parent cc2cebf commit 59825a5
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
Binary file modified premake5.exe
Binary file not shown.
13 changes: 11 additions & 2 deletions premake5.lua
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,11 @@ newoption {
description = "Build with opus"
}

newoption {
trigger = "lto",
description = "Use link time optimization"
}

if(_OPTIONS["with-librw"]) then
Librw = "vendor/librw"
else
Expand Down Expand Up @@ -61,6 +66,7 @@ end
workspace "re3"
language "C++"
configurations { "Debug", "Release" }
startproject "re3"
location "build"
symbols "Full"
staticruntime "off"
Expand Down Expand Up @@ -109,7 +115,10 @@ workspace "re3"

filter "configurations:Release"
defines { "NDEBUG" }
optimize "On"
optimize "Speed"
if(_OPTIONS["lto"]) then
flags { "LinkTimeOptimization" }
end

filter { "platforms:win*" }
system "windows"
Expand Down Expand Up @@ -166,7 +175,7 @@ workspace "re3"
scriptspath = scriptspath or ""
if (gamepath) then
postbuildcommands {
'{COPY} "%{cfg.buildtarget.abspath}" "' .. gamepath .. scriptspath .. '%{cfg.buildtarget.name}"'
'{COPYFILE} "%{cfg.buildtarget.abspath}" "' .. gamepath .. scriptspath .. '%{cfg.buildtarget.name}"'
}
debugdir (gamepath)
if (exepath) then
Expand Down
Binary file modified premake5Linux
Binary file not shown.

0 comments on commit 59825a5

Please sign in to comment.