From 3be787aa22b79ce3b5fe1e95de1c9a8c388b895b Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 20 Oct 2024 14:27:04 +0800 Subject: [PATCH 1/8] tkrzw: add package --- packages/t/tkrzw/xmake.lua | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 packages/t/tkrzw/xmake.lua diff --git a/packages/t/tkrzw/xmake.lua b/packages/t/tkrzw/xmake.lua new file mode 100644 index 00000000000..152c17b7413 --- /dev/null +++ b/packages/t/tkrzw/xmake.lua @@ -0,0 +1,19 @@ +package("tkrzw") + set_homepage("https://dbmx.net/tkrzw/") + set_description("Tkrzw: a set of implementations of DBM") + set_license("Apache-2.0") + + set_urls("https://github.com/estraier/tkrzw.git") + + add_versions("2024-06-04", "409a57bf7507a4079d0519bc4a023da8ab79e132") + + on_install("macosx", "linux", function (package) + local configs = {} + table.insert(configs, "--enable-shared=" .. (package:config("shared") and "yes" or "no")) + table.insert(configs, "--enable-static=" .. (package:config("shared") and "no" or "yes")) + import("package.tools.autoconf").install(package, configs) + end) + + on_test(function (package) + assert(package:has_cxxfuncs("ParseCommandArguments", {includes = "tkrzw_cmd_util.h"})) + end) From 34faae906ddf180c907803a52df80edf86c94161 Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 20 Oct 2024 14:33:30 +0800 Subject: [PATCH 2/8] Update xmake.lua --- packages/t/tkrzw/xmake.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/t/tkrzw/xmake.lua b/packages/t/tkrzw/xmake.lua index 152c17b7413..9db797a8567 100644 --- a/packages/t/tkrzw/xmake.lua +++ b/packages/t/tkrzw/xmake.lua @@ -15,5 +15,5 @@ package("tkrzw") end) on_test(function (package) - assert(package:has_cxxfuncs("ParseCommandArguments", {includes = "tkrzw_cmd_util.h"})) + assert(package:has_cxxfuncs("tkrzw::ParseCommandArguments", {includes = "tkrzw_cmd_util.h"})) end) From dfcf24c63fa9fba570a2fe133e632393e13f985d Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 20 Oct 2024 14:40:28 +0800 Subject: [PATCH 3/8] Update xmake.lua --- packages/t/tkrzw/xmake.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/t/tkrzw/xmake.lua b/packages/t/tkrzw/xmake.lua index 9db797a8567..74361deb2a1 100644 --- a/packages/t/tkrzw/xmake.lua +++ b/packages/t/tkrzw/xmake.lua @@ -15,5 +15,5 @@ package("tkrzw") end) on_test(function (package) - assert(package:has_cxxfuncs("tkrzw::ParseCommandArguments", {includes = "tkrzw_cmd_util.h"})) + assert(package:has_cxxfuncs("tkrzw::Print()", {includes = "tkrzw_cmd_util.h"})) end) From 8bc9e0b44730935127bcd451cc40b40061722dc9 Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 20 Oct 2024 14:48:25 +0800 Subject: [PATCH 4/8] Update xmake.lua --- packages/t/tkrzw/xmake.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/t/tkrzw/xmake.lua b/packages/t/tkrzw/xmake.lua index 74361deb2a1..a43056fb476 100644 --- a/packages/t/tkrzw/xmake.lua +++ b/packages/t/tkrzw/xmake.lua @@ -7,7 +7,11 @@ package("tkrzw") add_versions("2024-06-04", "409a57bf7507a4079d0519bc4a023da8ab79e132") - on_install("macosx", "linux", function (package) + if is_plat("linux") then + add_syslinks("atomic") + end + + on_install("linux", function (package) local configs = {} table.insert(configs, "--enable-shared=" .. (package:config("shared") and "yes" or "no")) table.insert(configs, "--enable-static=" .. (package:config("shared") and "no" or "yes")) From 737c43682445a1b5528769168ccdf96ef6b350e7 Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 20 Oct 2024 14:52:50 +0800 Subject: [PATCH 5/8] Update fedora.yml --- .github/workflows/fedora.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/fedora.yml b/.github/workflows/fedora.yml index c15c8a6444b..30cf90a0026 100644 --- a/.github/workflows/fedora.yml +++ b/.github/workflows/fedora.yml @@ -25,7 +25,8 @@ jobs: dnf -y install gfortran p7zip which dnf -y install mesa-libGL-devel mesa-libGLU-devel dnf -y install @development-tools @rpm-development-tools - dnf -y install copr-cli make gcc-c++ libatomic libcxx-devel + dnf -y install copr-cli make gcc-c++ libcxx-devel + dnf -y install libatomic libatomic-static dnf -y upgrade git dnf -y install perl dnf -y install glibc-static libstdc++-static From d838a4bda0ad7a437ac367f8f3e0276d19541955 Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 20 Oct 2024 19:06:09 +0800 Subject: [PATCH 6/8] Update xmake.lua --- packages/t/tkrzw/xmake.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/t/tkrzw/xmake.lua b/packages/t/tkrzw/xmake.lua index a43056fb476..b69d973fd1e 100644 --- a/packages/t/tkrzw/xmake.lua +++ b/packages/t/tkrzw/xmake.lua @@ -12,6 +12,7 @@ package("tkrzw") end on_install("linux", function (package) + io.replace("configure.in", "AC_CHECK_LIB(atomic, main)", "") local configs = {} table.insert(configs, "--enable-shared=" .. (package:config("shared") and "yes" or "no")) table.insert(configs, "--enable-static=" .. (package:config("shared") and "no" or "yes")) From 2bc0d1f39e8052f6bd437364aef9dc8916cb187e Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 20 Oct 2024 19:10:05 +0800 Subject: [PATCH 7/8] Update xmake.lua --- packages/t/tkrzw/xmake.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/t/tkrzw/xmake.lua b/packages/t/tkrzw/xmake.lua index b69d973fd1e..42f9f2be3ae 100644 --- a/packages/t/tkrzw/xmake.lua +++ b/packages/t/tkrzw/xmake.lua @@ -12,6 +12,7 @@ package("tkrzw") end on_install("linux", function (package) + os.vrun("rm configure") io.replace("configure.in", "AC_CHECK_LIB(atomic, main)", "") local configs = {} table.insert(configs, "--enable-shared=" .. (package:config("shared") and "yes" or "no")) From f7c63d2d99e885c541f5f6be24fd4326c780e06a Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 20 Oct 2024 19:15:16 +0800 Subject: [PATCH 8/8] Update xmake.lua --- packages/t/tkrzw/xmake.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/t/tkrzw/xmake.lua b/packages/t/tkrzw/xmake.lua index 42f9f2be3ae..42b92d86ad1 100644 --- a/packages/t/tkrzw/xmake.lua +++ b/packages/t/tkrzw/xmake.lua @@ -12,8 +12,7 @@ package("tkrzw") end on_install("linux", function (package) - os.vrun("rm configure") - io.replace("configure.in", "AC_CHECK_LIB(atomic, main)", "") + os.vrun("sudo ln -s /lib/libatomic.so /lib/libatomic.a") local configs = {} table.insert(configs, "--enable-shared=" .. (package:config("shared") and "yes" or "no")) table.insert(configs, "--enable-static=" .. (package:config("shared") and "no" or "yes"))