Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions packages/e/eabase/xmake.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@ package("eabase")
set_description("EABase is a small set of header files that define platform-independent data types and platform feature macros.")
set_license("BSD-3-Clause")

add_urls("https://github.com/electronicarts/EABase/archive/refs/tags/$(version).tar.gz",
"https://github.com/electronicarts/EABase.git")
add_urls("https://github.com/electronicarts/EABase/archive/refs/tags/$(version).tar.gz")
add_urls("https://github.com/electronicarts/EABase.git", {alias = "git", submodules = false})

add_versions("2.09.05", "f85b98c96f1976aa013c8d6016c5e37a409633ac3fce843cd4ec0b89c67e6b7a")
add_patches("2.09.05", "patches/2.09.05/add-arm64-windows.patch", "c140e4587fdb1fc93b16df639da93aac5d331420b86f68363482be31f4bd2bfd")
add_versions("git:2.09.12", "0699a15efdfd20b6cecf02153bfa5663decb653c")

on_install("!wasm", function (package)
os.cp("include/Common/EABase", package:installdir("include"))
Expand Down
20 changes: 19 additions & 1 deletion packages/e/eastl/xmake.lua
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,33 @@ package("eastl")
add_versions("3.17.06", "9ebeef26cdf091877ee348450d2711cd0bb60ae435309126c0adf8fec9a01ea5")
add_versions("3.18.00", "a3c5b970684be02e81fb16fbf92ed2584e055898704fde87c72d0331afdea12b")
add_versions("3.21.12", "2a4d77e5eda23ec52fea8b22abbf2ea8002f38396d2a3beddda3ff2e17f7db2e")
add_versions("3.21.23", "2bcb48f88f7daf9f91c165aae751c10d11d6959b6e10f2dda8f1db893e684022")
add_versions("3.27.00", "5606643e41ab12fd7c209755fe04dca581ed01f43dec515288b1544eea22623f")

add_deps("cmake")
add_deps("eabase")

on_load("windows", function (package)
if package:config("shared") then
package:add("defines", "EA_DLL")
end
end)

on_install("windows", "linux", "macosx", function (package)
io.replace("CMakeLists.txt", [[target_compile_features(EASTL PUBLIC cxx_std_14)]], [[target_compile_features(EASTL PUBLIC cxx_std_17)]], {plain = true})
if package:is_plat("windows") and package:config("shared") then
io.replace("CMakeLists.txt", [[add_definitions(-D_CHAR16T)]], [[add_definitions(-D_CHAR16T)
if(BUILD_SHARED_LIBS)
target_compile_definitions(EASTL PUBLIC EA_DLL)
if(MSVC OR CYGWIN)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't it be OR MINGW?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well I was providing those changes, I think it should be WIN32 ?

target_compile_definitions(EASTL PRIVATE "EASTL_API=__declspec(dllexport)")
endif()
endif()]], {plain = true})
end
io.replace("CMakeLists.txt", "add_subdirectory(test/packages/EABase)", "", {plain = true})
io.replace("CMakeLists.txt", "target_link_libraries(EASTL EABase)", "", {plain = true})
local configs = {"-DEASTL_BUILD_TESTS=OFF", "-DEASTL_BUILD_BENCHMARK=OFF"}
table.insert(configs, "-DCMAKE_BUILD_TYPE=" .. (package:debug() and "Debug" or "Release"))
table.insert(configs, "-DCMAKE_BUILD_TYPE=" .. (package:is_debug() and "Debug" or "Release"))
if not package:is_plat("windows") then
table.insert(configs, "-DBUILD_SHARED_LIBS=" .. (package:config("shared") and "ON" or "OFF"))
end
Expand Down
Loading