-
[+] Added preconfig warmup to buildactionbootstrap.lua [*] Fix broken elseif syntax [*] Fix Settings.lua wasn't being included / add includes under utilities.lua are prefixed with ./ [*] Refactor requires/supportsElfStripping [+] Added devChainCoreUtils
This commit is contained in:
parent
09bb61542a
commit
bf097424ef
@ -39,6 +39,11 @@ if (settings) then
|
|||||||
require("./../../Public/Paths")
|
require("./../../Public/Paths")
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local preconfig = path.join(Aurora.Settings.sAbsRoot, "preconfig.lua")
|
||||||
|
if (os.isfile(preconfig) then
|
||||||
|
auRequireAbs(preconfig)
|
||||||
|
end
|
||||||
|
|
||||||
local projRoot = path.join(Aurora.Settings.sAbsRoot, _OPTIONS["project_root"] or "./")
|
local projRoot = path.join(Aurora.Settings.sAbsRoot, _OPTIONS["project_root"] or "./")
|
||||||
|
|
||||||
local cwd =_OPTIONS["cwd"]
|
local cwd =_OPTIONS["cwd"]
|
||||||
@ -73,15 +78,15 @@ end
|
|||||||
|
|
||||||
auBuild =
|
auBuild =
|
||||||
{
|
{
|
||||||
platform = projPlatform,
|
platform = projPlatform,
|
||||||
architecture = projArch,
|
architecture = projArch,
|
||||||
projectName = projName,
|
projectName = projName,
|
||||||
projectType = projType,
|
projectType = projType,
|
||||||
projectRoot = projRoot,
|
projectRoot = projRoot,
|
||||||
projectTargetName = targetName,
|
projectTargetName = targetName,
|
||||||
projectTargetFileName = fileName,
|
projectTargetFileName = fileName,
|
||||||
args = args,
|
args = args,
|
||||||
root = cwd
|
root = cwd
|
||||||
}
|
}
|
||||||
|
|
||||||
_G["build"] = auBuild
|
_G["build"] = auBuild
|
||||||
|
@ -46,14 +46,16 @@ local function addUserDestCopy(name, type, config, platformName, arch, dir)
|
|||||||
|
|
||||||
local copy, outputPath, file = formatCpy(Aurora.Settings.sLibPrefix .. name, type, dir, ext, isWin, config, platformName, arch, name)
|
local copy, outputPath, file = formatCpy(Aurora.Settings.sLibPrefix .. name, type, dir, ext, isWin, config, platformName, arch, name)
|
||||||
|
|
||||||
if (platformName == "linux" or platformName == "freebsd" or platformName == "mac") then
|
if (platform.devChainCoreUtils) then
|
||||||
gnuCoreUtilsMkdirRecursive(dir)
|
gnuCoreUtilsMkdirRecursive(dir)
|
||||||
end
|
end
|
||||||
|
|
||||||
if (platform.requiresElfStrip and platform.supportsElfStrip and config == Aurora.Settings.sNameOfShip) then
|
if (platform.devChainRequiresElfStrip and
|
||||||
|
platform.devChainSupportsElfStrip and
|
||||||
|
config ~= Aurora.Settings.sNameOfDebug) then
|
||||||
local debugSymbolPath = normalizeCpyPath(Aurora.Settings.sAbsSymbols) .. "/" .. name .. ".dwarf"
|
local debugSymbolPath = normalizeCpyPath(Aurora.Settings.sAbsSymbols) .. "/" .. name .. ".dwarf"
|
||||||
postbuildcommands("objcopy --strip-debug " .. file .. " " .. outputPath)
|
postbuildcommands("objcopy --strip-debug " .. file .. " " .. outputPath)
|
||||||
if (Aurora.Settings.bUseAuBuildHooks) then
|
if (Aurora.Settings.bUseAuBuildHooks and config ~= Aurora.Settings.sNameOfShip) then
|
||||||
postbuildcommands("objcopy --add-gnu-debuglink=" .. debugSymbolPath .. " " .. outputPath)
|
postbuildcommands("objcopy --add-gnu-debuglink=" .. debugSymbolPath .. " " .. outputPath)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
@ -98,17 +100,24 @@ local function postBuildCommands(name, type, config, platformName, arch)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if (config == Aurora.Settings.sNameOfShip) then
|
if (config ~= Aurora.Settings.sNameOfDebug) then
|
||||||
|
local platform = Aurora.Platforms[platformName]
|
||||||
|
if (not platform) then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
local debugSymbolPath = nil
|
local debugSymbolPath = nil
|
||||||
|
|
||||||
if (platform.requiresElfStrip and platform.supportsElfStrip) then
|
if (platform.devChainRequiresElfStrip and
|
||||||
|
platform.devChainSupportsElfStrip) then
|
||||||
debugSymbolPath = normalizeCpyPath(Aurora.Settings.sAbsSymbols) .. "/" .. name .. ".dwarf"
|
debugSymbolPath = normalizeCpyPath(Aurora.Settings.sAbsSymbols) .. "/" .. name .. ".dwarf"
|
||||||
postbuildcommands("objcopy --only-keep-debug " .. file .. " " .. debugSymbolPath)
|
postbuildcommands("objcopy --only-keep-debug " .. file .. " " .. debugSymbolPath)
|
||||||
elseif (isWin)
|
elseif (isWin) then
|
||||||
debugSymbolPath = normalizeCpyPath(Aurora.Settings.sAbsSymbols) .. "/" .. name .. ".pdb"
|
debugSymbolPath = normalizeCpyPath(Aurora.Settings.sAbsSymbols) .. "/" .. name .. ".pdb"
|
||||||
end
|
end
|
||||||
|
|
||||||
if (debugSymbolPath) then
|
if (debugSymbolPath and
|
||||||
|
config == Aurora.Settings.sNameOfShip) then
|
||||||
archiveShipPdb(debugSymbolPath)
|
archiveShipPdb(debugSymbolPath)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
|
@ -11,8 +11,9 @@ local platforms = {
|
|||||||
freebsd = {
|
freebsd = {
|
||||||
targetLocal = true,
|
targetLocal = true,
|
||||||
forceLLVMStl = true,
|
forceLLVMStl = true,
|
||||||
requiresElfStrip = true,
|
devChainRequiresElfStrip = true,
|
||||||
supportsElfStrip = true,
|
devChainSupportsElfStrip = true,
|
||||||
|
devChainCoreUtils = true,
|
||||||
exts = {
|
exts = {
|
||||||
SharedLib = ".so"
|
SharedLib = ".so"
|
||||||
}
|
}
|
||||||
@ -21,8 +22,9 @@ local platforms = {
|
|||||||
defines = "_LINUX_AURORA_PREPROCESSOR",
|
defines = "_LINUX_AURORA_PREPROCESSOR",
|
||||||
forceLLVMStl = true,
|
forceLLVMStl = true,
|
||||||
targetLocal = true,
|
targetLocal = true,
|
||||||
requiresElfStrip = true,
|
devChainRequiresElfStrip = true,
|
||||||
supportsElfStrip = true,
|
devChainSupportsElfStrip = true,
|
||||||
|
devChainCoreUtils = true,
|
||||||
exts = {
|
exts = {
|
||||||
SharedLib = ".so"
|
SharedLib = ".so"
|
||||||
}
|
}
|
||||||
@ -30,11 +32,13 @@ local platforms = {
|
|||||||
mac = {
|
mac = {
|
||||||
defines = "_APPLE_AURORA_PREPROCESSOR",
|
defines = "_APPLE_AURORA_PREPROCESSOR",
|
||||||
targetLocal = true,
|
targetLocal = true,
|
||||||
|
devChainCoreUtils = true,
|
||||||
exts = {
|
exts = {
|
||||||
SharedLib = ".dynlib"
|
SharedLib = ".dynlib"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
ios = {
|
ios = {
|
||||||
|
devChainCoreUtils = true,
|
||||||
defines = "_APPLE_MOBILE_AURORA_PREPROCESSOR"
|
defines = "_APPLE_MOBILE_AURORA_PREPROCESSOR"
|
||||||
},
|
},
|
||||||
android = {
|
android = {
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
require("getRoot")
|
require("./getRoot")
|
||||||
require("forEach")
|
require("./forEach")
|
||||||
require("strings")
|
require("./strings")
|
||||||
require("userRequire")
|
require("./userRequire")
|
||||||
require("lookupCmdArgs")
|
require("./lookupCmdArgs")
|
||||||
require("fatal")
|
require("./fatal")
|
||||||
require("eval")
|
require("./eval")
|
||||||
require("isArray")
|
require("./isArray")
|
||||||
require("concatArrays")
|
require("./concatArrays")
|
||||||
require("base64")
|
require("./base64")
|
||||||
require("requireAbs")
|
require("./requireAbs")
|
||||||
require("merge")
|
require("./merge")
|
||||||
require("settings")
|
require("./settings")
|
||||||
require("contains")
|
require("./contains")
|
Loading…
Reference in New Issue
Block a user