mirror of
https://github.com/xenia-project/xenia.git
synced 2025-12-06 07:12:03 +01:00
[premake, xb] Moar cleanup
This commit is contained in:
parent
f73b00a620
commit
fa8c19edbd
|
|
@ -13,6 +13,6 @@ project("xenia-apu")
|
|||
"xenia-base",
|
||||
})
|
||||
includedirs({
|
||||
project_root.."/third_party/FFmpeg/",
|
||||
project_root.."/third_party/FFmpeg",
|
||||
})
|
||||
local_platform_files()
|
||||
|
|
|
|||
90
third_party/zstd.lua
vendored
90
third_party/zstd.lua
vendored
|
|
@ -1,88 +1,10 @@
|
|||
-- This GENie/premake file copies the behavior of the Makefile in the lib folder.
|
||||
-- Basic usage: project_zstd(ZSTD_DIR)
|
||||
|
||||
function project_zstd(dir, compression, decompression, deprecated, dictbuilder, legacy)
|
||||
if compression == nil then compression = true end
|
||||
if decompression == nil then decompression = true end
|
||||
if deprecated == nil then deprecated = false end
|
||||
if dictbuilder == nil then dictbuilder = false end
|
||||
|
||||
if legacy == nil then legacy = 0 end
|
||||
|
||||
if not compression then
|
||||
dictbuilder = false
|
||||
deprecated = false
|
||||
end
|
||||
|
||||
if not decompression then
|
||||
legacy = 0
|
||||
deprecated = false
|
||||
end
|
||||
|
||||
project "zstd"
|
||||
kind "StaticLib"
|
||||
language "C"
|
||||
|
||||
files {
|
||||
dir .. "zstd.h",
|
||||
dir .. "common/**.c",
|
||||
dir .. "common/**.h"
|
||||
}
|
||||
|
||||
if compression then
|
||||
files {
|
||||
dir .. "compress/**.c",
|
||||
dir .. "compress/**.h"
|
||||
}
|
||||
end
|
||||
|
||||
if decompression then
|
||||
files {
|
||||
dir .. "decompress/**.c",
|
||||
dir .. "decompress/**.h"
|
||||
}
|
||||
end
|
||||
|
||||
if dictbuilder then
|
||||
files {
|
||||
dir .. "dictBuilder/**.c",
|
||||
dir .. "dictBuilder/**.h"
|
||||
}
|
||||
end
|
||||
|
||||
if deprecated then
|
||||
files {
|
||||
dir .. "deprecated/**.c",
|
||||
dir .. "deprecated/**.h"
|
||||
}
|
||||
end
|
||||
|
||||
if legacy ~= 0 then
|
||||
if legacy >= 8 then
|
||||
files {
|
||||
dir .. "legacy/zstd_v0" .. (legacy - 7) .. ".*"
|
||||
}
|
||||
end
|
||||
includedirs {
|
||||
dir .. "legacy"
|
||||
}
|
||||
end
|
||||
|
||||
includedirs {
|
||||
dir,
|
||||
dir .. "common"
|
||||
}
|
||||
|
||||
defines {
|
||||
"XXH_NAMESPACE=ZSTD_",
|
||||
-- See here on why: https://gitlab.kitware.com/cmake/cmake/-/issues/25744
|
||||
"ZSTD_DISABLE_ASM=1",
|
||||
"ZSTD_LEGACY_SUPPORT=" .. legacy
|
||||
}
|
||||
end
|
||||
|
||||
include("third_party/zstd/contrib/premake/zstd.lua")
|
||||
|
||||
group("third_party")
|
||||
project("zstd")
|
||||
uuid("df336aac-f0c8-11ed-a05b-0242ac120003")
|
||||
project_zstd("./zstd/lib/")
|
||||
-- TODO: https://github.com/facebook/zstd/issues/3278
|
||||
--defines({
|
||||
-- "ZSTD_DISABLE_ASM",
|
||||
--})
|
||||
project_zstd("zstd/lib/")
|
||||
|
|
|
|||
|
|
@ -486,7 +486,7 @@ def get_premake_target_os(target_os_override=None):
|
|||
target_os = "android"
|
||||
else:
|
||||
target_os = "linux"
|
||||
if target_os_override is not None and target_os_override != target_os:
|
||||
if target_os_override and target_os_override != target_os:
|
||||
if target_os_override == "android":
|
||||
target_os = target_os_override
|
||||
else:
|
||||
|
|
@ -832,7 +832,7 @@ class BaseBuildCommand(Command):
|
|||
"/m",
|
||||
"/v:m",
|
||||
f"/p:Configuration={args['config']}",
|
||||
] + ([targets] if targets is not None else []) + pass_args)
|
||||
] + ([targets] if targets else []) + pass_args)
|
||||
elif sys.platform == "darwin":
|
||||
schemes = args["target"] or ["xenia-app"]
|
||||
nested_args = [["-scheme", scheme] for scheme in schemes]
|
||||
|
|
|
|||
Loading…
Reference in a new issue