Premake: Add --copy-pdb parameter to also copy the PDB file to the folder given by --copy-to.

This commit is contained in:
/dev/urandom 2016-08-10 17:09:19 +02:00
parent 63fc302ce0
commit 4c6ad8a134
No known key found for this signature in database
GPG Key ID: 41322B973E0F295E

View File

@ -10,6 +10,11 @@ newoption {
description = "Do not use new virtual path structure (separating headers and source files)." description = "Do not use new virtual path structure (separating headers and source files)."
} }
newoption {
trigger = "copy-pdb",
description = "Copy debug information for binaries as well to the path given via --copy-to."
}
newaction { newaction {
trigger = "version", trigger = "version",
description = "Returns the version string for the current commit of the source code.", description = "Returns the version string for the current commit of the source code.",
@ -200,6 +205,12 @@ workspace "iw4x"
"if not exist \"" .. saneCopyToPath .. "\" mkdir \"" .. saneCopyToPath .. "\"", "if not exist \"" .. saneCopyToPath .. "\" mkdir \"" .. saneCopyToPath .. "\"",
"copy /y \"$(TargetDir)*.dll\" \"" .. saneCopyToPath .. "\"", "copy /y \"$(TargetDir)*.dll\" \"" .. saneCopyToPath .. "\"",
} }
if _OPTIONS["copy-pdb"] then
postbuildcommands {
"copy /y \"$(TargetDir)*.pdb\" \"" .. saneCopyToPath .. "\"",
}
end
end end
-- Specific configurations -- Specific configurations