3 new builds flags for windows dosstub, winsign, winrsrc to explicitly turn on these extra steps

This commit is contained in:
otavepto 2024-05-22 03:09:18 +03:00
parent 99d9aa76d0
commit 478e2b3b52

View File

@ -109,7 +109,26 @@ newaction {
newoption { newoption {
trigger = "emubuild", trigger = "emubuild",
description = "Set the EMU_BUILD_STRING", description = "Set the EMU_BUILD_STRING",
default = os.date("%Y_%m_%d-%H_%M_%S") value = "your_string",
default = os.date("%Y_%m_%d-%H_%M_%S"),
}
newoption {
category = "win build",
trigger = "dosstub",
description = "Change the DOS stub of the Windows builds",
}
newoption {
category = "win build",
trigger = "winsign",
description = "Sign Windows builds with a fake certificate",
}
newoption {
category = "win build",
trigger = "winrsrc",
description = "Add resources to Windows builds",
} }
@ -379,16 +398,16 @@ local dos_stub_exe_32 = os.realpath('resources/win/file_dos_stub/file_dos_stub_3
local dos_stub_exe_64 = os.realpath('resources/win/file_dos_stub/file_dos_stub_64.exe') local dos_stub_exe_64 = os.realpath('resources/win/file_dos_stub/file_dos_stub_64.exe')
local signer_tool = os.realpath('third-party/build/win/cert/sign_helper.bat') local signer_tool = os.realpath('third-party/build/win/cert/sign_helper.bat')
-- change dos stub -- change dos stub
filter { "system:windows", "platforms:x32", } filter { "system:windows", "platforms:x32", "options:dosstub", }
postbuildcommands { postbuildcommands {
'"' .. dos_stub_exe_32 .. '" %[%{!cfg.buildtarget.abspath}]', '"' .. dos_stub_exe_32 .. '" %[%{!cfg.buildtarget.abspath}]',
} }
filter { "system:windows", "platforms:x64", } filter { "system:windows", "platforms:x64", "options:dosstub", }
postbuildcommands { postbuildcommands {
'"' .. dos_stub_exe_64 .. '" %[%{!cfg.buildtarget.abspath}]', '"' .. dos_stub_exe_64 .. '" %[%{!cfg.buildtarget.abspath}]',
} }
-- sign -- sign
filter { "system:windows", } filter { "system:windows", "options:winsign", }
postbuildcommands { postbuildcommands {
'"' .. signer_tool .. '" %[%{!cfg.buildtarget.abspath}]', '"' .. signer_tool .. '" %[%{!cfg.buildtarget.abspath}]',
} }
@ -459,12 +478,12 @@ project "api_regular"
"dll/wrap.cpp" "dll/wrap.cpp"
} }
-- Windows x32 common source files -- Windows x32 common source files
filter { "system:windows", "platforms:x32", } filter { "system:windows", "platforms:x32", "options:winrsrc", }
files { files {
"resources/win/api/32/resources.rc" "resources/win/api/32/resources.rc"
} }
-- Windows x64 common source files -- Windows x64 common source files
filter { "system:windows", "platforms:x64", } filter { "system:windows", "platforms:x64", "options:winrsrc", }
files { files {
"resources/win/api/64/resources.rc" "resources/win/api/64/resources.rc"
} }
@ -573,12 +592,12 @@ project "api_experimental"
"dll/wrap.cpp" "dll/wrap.cpp"
} }
-- Windows x32 common source files -- Windows x32 common source files
filter { "system:windows", "platforms:x32", } filter { "system:windows", "platforms:x32", "options:winrsrc", }
files { files {
"resources/win/api/32/resources.rc" "resources/win/api/32/resources.rc"
} }
-- Windows x64 common source files -- Windows x64 common source files
filter { "system:windows", "platforms:x64", } filter { "system:windows", "platforms:x64", "options:winrsrc", }
files { files {
"resources/win/api/64/resources.rc" "resources/win/api/64/resources.rc"
} }
@ -698,12 +717,12 @@ project "steamclient_experimental"
"dll/wrap.cpp" "dll/wrap.cpp"
} }
-- Windows x32 common source files -- Windows x32 common source files
filter { "system:windows", "platforms:x32", } filter { "system:windows", "platforms:x32", "options:winrsrc", }
files { files {
"resources/win/client/32/resources.rc" "resources/win/client/32/resources.rc"
} }
-- Windows x64 common source files -- Windows x64 common source files
filter { "system:windows", "platforms:x64", } filter { "system:windows", "platforms:x64", "options:winrsrc", }
files { files {
"resources/win/client/64/resources.rc" "resources/win/client/64/resources.rc"
} }
@ -789,12 +808,12 @@ project "tool_lobby_connect"
'tools/lobby_connect/lobby_connect.cpp' 'tools/lobby_connect/lobby_connect.cpp'
} }
-- Windows x32 common source files -- Windows x32 common source files
filter { "system:windows", "platforms:x32", } filter { "system:windows", "platforms:x32", "options:winrsrc", }
files { files {
"resources/win/launcher/32/resources.rc" "resources/win/launcher/32/resources.rc"
} }
-- Windows x64 common source files -- Windows x64 common source files
filter { "system:windows", "platforms:x64", } filter { "system:windows", "platforms:x64", "options:winrsrc", }
files { files {
"resources/win/launcher/64/resources.rc" "resources/win/launcher/64/resources.rc"
} }
@ -924,12 +943,12 @@ project "lib_game_overlay_renderer"
"game_overlay_renderer_lib/**" "game_overlay_renderer_lib/**"
} }
-- x32 common source files -- x32 common source files
filter { "system:windows", "platforms:x32", } filter { "system:windows", "platforms:x32", "options:winrsrc", }
files { files {
"resources/win/game_overlay_renderer/32/resources.rc" "resources/win/game_overlay_renderer/32/resources.rc"
} }
-- x64 common source files -- x64 common source files
filter { "system:windows", "platforms:x64", } filter { "system:windows", "platforms:x64", "options:winrsrc", }
files { files {
"resources/win/game_overlay_renderer/64/resources.rc" "resources/win/game_overlay_renderer/64/resources.rc"
} }
@ -965,12 +984,12 @@ project "steamclient_experimental_stub_win"
"steamclient/steamclient.cpp", "steamclient/steamclient.cpp",
} }
-- x32 common source files -- x32 common source files
filter { "platforms:x32", } filter { "platforms:x32", "options:winrsrc", }
files { files {
"resources/win/client/32/resources.rc" "resources/win/client/32/resources.rc"
} }
-- x64 common source files -- x64 common source files
filter { "platforms:x64", } filter { "platforms:x64", "options:winrsrc", }
files { files {
"resources/win/client/64/resources.rc" "resources/win/client/64/resources.rc"
} }
@ -1017,12 +1036,12 @@ project "steamclient_experimental_extra_win"
"libs/detours/**.c", "libs/detours/**.h", "libs/detours/**.c", "libs/detours/**.h",
} }
-- x32 common source files -- x32 common source files
filter { "platforms:x32", } filter { "platforms:x32", "options:winrsrc", }
files { files {
"resources/win/client/32/resources.rc" "resources/win/client/32/resources.rc"
} }
-- x64 common source files -- x64 common source files
filter { "platforms:x64", } filter { "platforms:x64", "options:winrsrc", }
files { files {
"resources/win/client/64/resources.rc" "resources/win/client/64/resources.rc"
} }
@ -1066,12 +1085,12 @@ project "steamclient_experimental_loader_win"
"helpers/dbg_log.cpp", "helpers/dbg_log.cpp",
} }
-- x32 common source files -- x32 common source files
filter { "platforms:x32", } filter { "platforms:x32", "options:winrsrc", }
files { files {
"resources/win/launcher/32/resources.rc" "resources/win/launcher/32/resources.rc"
} }
-- x64 common source files -- x64 common source files
filter { "platforms:x64", } filter { "platforms:x64", "options:winrsrc", }
files { files {
"resources/win/launcher/64/resources.rc" "resources/win/launcher/64/resources.rc"
} }