Compare commits

..

9 commits

Author SHA1 Message Date
Zephyr Lykos
bc4fcb1b3e
Fix xmake-data requires 2024-10-29 12:31:26 +08:00
topazus
975b105cb4 2.9.5 2024-09-28 00:12:38 +08:00
Packit
6a80a75d9d Update to 2.9.4 upstream release
- Resolves: rhbz#2301663

Upstream tag: v2.9.4
Upstream commit: e85b001f

Commit authored by Packit automation (https://packit.dev/)
2024-07-30 15:01:37 +00:00
Packit
e267518863 Update to 2.9.3 upstream release
- Resolves: rhbz#2294131

Upstream tag: v2.9.3
Upstream commit: a5da06f3

Commit authored by Packit automation (https://packit.dev/)
2024-06-25 02:30:12 +00:00
Packit
9bccad1bec Update to 2.9.2 upstream release
- Resolves: rhbz#2283192

Upstream tag: v2.9.2
Upstream commit: 6b6557c5

Commit authored by Packit automation (https://packit.dev/)
2024-05-25 10:12:18 +00:00
topazus
768e061de3 2.9.1 2024-04-23 23:36:48 +08:00
Packit
6dc8c6808c [packit] 2.8.9 upstream release
- Resolves rhbz#2270859

Upstream tag: v2.8.9
Upstream commit: cb1b6505
2024-03-21 21:29:03 +00:00
Packit
4d6920dd2a [packit] 2.8.8 upstream release
- Resolves rhbz#2267549

Upstream tag: v2.8.8
Upstream commit: d8e24825
2024-03-03 14:51:21 +00:00
Packit
2266f307cf [packit] 2.8.7 upstream release
- Resolves rhbz#2266055

Upstream tag: v2.8.7
Upstream commit: da279272
2024-02-26 16:19:13 +00:00
6 changed files with 26 additions and 352 deletions

View file

@ -1,11 +1,15 @@
upstream_package_name: xmake
upstream_project_url: https://github.com/xmake-io/xmake
upstream_tag_template: v{version}
downstream_package_name: xmake
specfile_path: xmake.spec
jobs:
- job: pull_from_upstream
trigger: release
dist_git_branches:
- fedora-rawhide
- fedora-all
- job: koji_build
trigger: commit

View file

@ -11,3 +11,16 @@ index 9901f58f6..ef523c2d9 100644
/* //////////////////////////////////////////////////////////////////////////////////////
* implementation
diff --git a/core/src/xmake/semver/prefix.h b/core/src/xmake/semver/prefix.h
index 2112d73f1..9077b49ca 100644
--- a/core/src/xmake/semver/prefix.h
+++ b/core/src/xmake/semver/prefix.h
@@ -25,7 +25,7 @@
* includes
*/
#include "../prefix.h"
-#include "semver.h"
+#include "sv/semver.h"
/* //////////////////////////////////////////////////////////////////////////////////////
* extern

View file

@ -1,344 +0,0 @@
From 5a41cf81382a49f1a88b613f2e6b10b8ce7223c7 Mon Sep 17 00:00:00 2001
From: ruki <waruqi@gmail.com>
Date: Mon, 12 Jan 2026 22:41:16 +0800
Subject: [PATCH 1/4] fix installdir of imporfiles
---
.../action/install/cmake_importfiles.lua | 31 ++++++++++---------
.../action/install/pkgconfig_importfiles.lua | 3 +-
2 files changed, 19 insertions(+), 15 deletions(-)
diff --git a/xmake/modules/target/action/install/cmake_importfiles.lua b/xmake/modules/target/action/install/cmake_importfiles.lua
index 6b876922564..0b1195c68ab 100644
--- a/xmake/modules/target/action/install/cmake_importfiles.lua
+++ b/xmake/modules/target/action/install/cmake_importfiles.lua
@@ -22,12 +22,12 @@
import("core.project.project")
-- get the lib file of the target
-function _get_libfile(target, installdir)
+function _get_libfile(target, libdir)
local libfile = path.filename(target:targetfile())
if target:is_plat("windows") then
libfile = libfile:gsub("%.dll$", ".lib")
elseif target:is_plat("mingw") then
- if os.isfile(path.join(installdir, "lib", libfile:gsub("%.dll$", ".dll.a"))) then
+ if os.isfile(path.join(libdir, libfile:gsub("%.dll$", ".dll.a"))) then
libfile = libfile:gsub("%.dll$", ".dll.a")
else
libfile = libfile:gsub("%.dll$", ".lib")
@@ -37,7 +37,7 @@ function _get_libfile(target, installdir)
end
-- get the builtin variables
-function _get_builtinvars(target, installdir, libdir)
+function _get_builtinvars(target, libdir)
local target_ptrbytes
if target:is_plat("cross") then
target_ptrbytes = target:check_sizeof("void*")
@@ -47,7 +47,7 @@ function _get_builtinvars(target, installdir, libdir)
return {LIBDIR = libdir,
TARGETNAME = target:name(),
PROJECTNAME = project.name() or target:name(),
- TARGETFILENAME = target:targetfile() and _get_libfile(target, installdir),
+ TARGETFILENAME = target:targetfile() and _get_libfile(target, libdir),
TARGETKIND = target:is_headeronly() and "INTERFACE" or (target:is_shared() and "SHARED" or "STATIC"),
PACKAGE_VERSION = target:get("version") or "1.0.0",
TARGET_PTRBYTES = target_ptrbytes}
@@ -55,18 +55,19 @@ end
-- install cmake config file
function _install_cmake_configfile(target, installdir, filename, opt)
+ opt = opt or {}
-- get import file path
- local libdir = opt and opt.libdir or "lib"
+ local libdir = opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
local projectname = project.name() or target:name()
local importfile_src = path.join(os.programdir(), "scripts", "cmake_importfiles", filename)
- local importfile_dst = path.join(installdir, libdir, "cmake", projectname, (filename:gsub("xxx", projectname)))
+ local importfile_dst = path.join(libdir, "cmake", projectname, (filename:gsub("xxx", projectname)))
-- trace
vprint("generating %s ..", importfile_dst)
-- get the builtin variables
- local builtinvars = _get_builtinvars(target, installdir, libdir)
+ local builtinvars = _get_builtinvars(target, libdir)
-- copy and replace builtin variables
local content = io.readfile(importfile_src)
@@ -83,15 +84,16 @@ end
-- append target to cmake config file
function _append_cmake_configfile(target, installdir, filename, opt)
+ opt = opt or {}
-- get import file path
- local libdir = opt and opt.libdir or "lib"
+ local libdir = opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
local projectname = project.name() or target:name()
local importfile_src = path.join(os.programdir(), "scripts", "cmake_importfiles", filename)
- local importfile_dst = path.join(installdir, libdir, "cmake", projectname, (filename:gsub("xxx", projectname)))
+ local importfile_dst = path.join(libdir, "cmake", projectname, (filename:gsub("xxx", projectname)))
-- get the builtin variables
- local builtinvars = _get_builtinvars(target, installdir, libdir)
+ local builtinvars = _get_builtinvars(target, libdir)
-- generate the file if not exist / file is outdated
if target:is_headeronly() or not os.isfile(importfile_dst) or os.mtime(importfile_dst) < os.mtime(target:targetfile()) then
@@ -119,18 +121,19 @@ end
-- install cmake target file
function _install_cmake_targetfile(target, installdir, filename, opt)
+ opt = opt or {}
-- get import file path
- local libdir = opt and opt.libdir or "lib"
+ local libdir = opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
local projectname = project.name() or target:name()
local importfile_src = path.join(os.programdir(), "scripts", "cmake_importfiles", filename)
- local importfile_dst = path.join(installdir, libdir, "cmake", projectname, (filename:gsub("xxx", target:name())))
+ local importfile_dst = path.join(libdir, "cmake", projectname, (filename:gsub("xxx", target:name())))
-- trace
vprint("generating %s ..", importfile_dst)
-- get the builtin variables
- local builtinvars = _get_builtinvars(target, installdir, libdir)
+ local builtinvars = _get_builtinvars(target, libdir)
-- copy and replace builtin variables
local content = io.readfile(importfile_src)
@@ -142,7 +145,7 @@ function _install_cmake_targetfile(target, installdir, filename, opt)
end)
local libfile = path.filename(target:targetfile())
local postfix = is_mode("debug") and "DEBUG" or "RELEASE"
- if target:is_shared() and (_get_libfile(target, installdir) ~= libfile) then
+ if target:is_shared() and (_get_libfile(target, libdir) ~= libfile) then
-- On DLL platforms, the import library is named differently from the target file
content = content:gsub("# IMPORTED_IMPLIB_" .. postfix, "IMPORTED_IMPLIB_" .. postfix)
content = content:gsub(
diff --git a/xmake/modules/target/action/install/pkgconfig_importfiles.lua b/xmake/modules/target/action/install/pkgconfig_importfiles.lua
index b96833071e7..cdeb42831bb 100644
--- a/xmake/modules/target/action/install/pkgconfig_importfiles.lua
+++ b/xmake/modules/target/action/install/pkgconfig_importfiles.lua
@@ -30,7 +30,8 @@ function main(target, opt)
end
-- get pkgconfig/.pc file
- local pcfile = path.join(installdir, opt and opt.libdir or "lib", "pkgconfig", opt.filename or (target:basename() .. ".pc"))
+ local libdir = opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
+ local pcfile = path.join(libdir, "pkgconfig", opt.filename or (target:basename() .. ".pc"))
-- get includedirs
local includedirs = opt.includedirs
From 168fe49abe77fbf2a1c1ba865bf22d4d8cdd371d Mon Sep 17 00:00:00 2001
From: ruki <waruqi@gmail.com>
Date: Mon, 12 Jan 2026 22:43:39 +0800
Subject: [PATCH 2/4] fix libdir
---
.../target/action/install/cmake_importfiles.lua | 16 +++++++++++-----
1 file changed, 11 insertions(+), 5 deletions(-)
diff --git a/xmake/modules/target/action/install/cmake_importfiles.lua b/xmake/modules/target/action/install/cmake_importfiles.lua
index 0b1195c68ab..ae2155ec7cf 100644
--- a/xmake/modules/target/action/install/cmake_importfiles.lua
+++ b/xmake/modules/target/action/install/cmake_importfiles.lua
@@ -37,14 +37,20 @@ function _get_libfile(target, libdir)
end
-- get the builtin variables
-function _get_builtinvars(target, libdir)
+function _get_builtinvars(target, installdir, libdir)
local target_ptrbytes
if target:is_plat("cross") then
target_ptrbytes = target:check_sizeof("void*")
else
target_ptrbytes = target:is_arch64() and "8" or "4"
end
- return {LIBDIR = libdir,
+ local libsubdir
+ if libdir:startswith(installdir) then
+ libsubdir = path.relative(libdir, installdir)
+ else
+ raise("target(%s): libdir(%s) is not in installdir(%s)", target:name(), libdir, installdir)
+ end
+ return {LIBDIR = libsubdir,
TARGETNAME = target:name(),
PROJECTNAME = project.name() or target:name(),
TARGETFILENAME = target:targetfile() and _get_libfile(target, libdir),
@@ -67,7 +73,7 @@ function _install_cmake_configfile(target, installdir, filename, opt)
vprint("generating %s ..", importfile_dst)
-- get the builtin variables
- local builtinvars = _get_builtinvars(target, libdir)
+ local builtinvars = _get_builtinvars(target, installdir, libdir)
-- copy and replace builtin variables
local content = io.readfile(importfile_src)
@@ -93,7 +99,7 @@ function _append_cmake_configfile(target, installdir, filename, opt)
local importfile_dst = path.join(libdir, "cmake", projectname, (filename:gsub("xxx", projectname)))
-- get the builtin variables
- local builtinvars = _get_builtinvars(target, libdir)
+ local builtinvars = _get_builtinvars(target, installdir, libdir)
-- generate the file if not exist / file is outdated
if target:is_headeronly() or not os.isfile(importfile_dst) or os.mtime(importfile_dst) < os.mtime(target:targetfile()) then
@@ -133,7 +139,7 @@ function _install_cmake_targetfile(target, installdir, filename, opt)
vprint("generating %s ..", importfile_dst)
-- get the builtin variables
- local builtinvars = _get_builtinvars(target, libdir)
+ local builtinvars = _get_builtinvars(target, installdir, libdir)
-- copy and replace builtin variables
local content = io.readfile(importfile_src)
From 3ffd904326d6a06f8f63a92bc1d2334a8d8441fd Mon Sep 17 00:00:00 2001
From: ruki <waruqi@gmail.com>
Date: Mon, 12 Jan 2026 22:54:07 +0800
Subject: [PATCH 3/4] improve cmake installdir
---
.../target/action/install/cmake_importfiles.lua | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/xmake/modules/target/action/install/cmake_importfiles.lua b/xmake/modules/target/action/install/cmake_importfiles.lua
index ae2155ec7cf..b4efecb0862 100644
--- a/xmake/modules/target/action/install/cmake_importfiles.lua
+++ b/xmake/modules/target/action/install/cmake_importfiles.lua
@@ -21,6 +21,12 @@
-- imports
import("core.project.project")
+-- get install libdir
+function _get_install_libdir(target, installdir, opt)
+ opt = opt or {}
+ return opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
+end
+
-- get the lib file of the target
function _get_libfile(target, libdir)
local libfile = path.filename(target:targetfile())
@@ -61,10 +67,9 @@ end
-- install cmake config file
function _install_cmake_configfile(target, installdir, filename, opt)
- opt = opt or {}
-- get import file path
- local libdir = opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
+ local libdir = _get_install_libdir(target, installdir, opt)
local projectname = project.name() or target:name()
local importfile_src = path.join(os.programdir(), "scripts", "cmake_importfiles", filename)
local importfile_dst = path.join(libdir, "cmake", projectname, (filename:gsub("xxx", projectname)))
@@ -90,10 +95,9 @@ end
-- append target to cmake config file
function _append_cmake_configfile(target, installdir, filename, opt)
- opt = opt or {}
-- get import file path
- local libdir = opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
+ local libdir = _get_install_libdir(target, installdir, opt)
local projectname = project.name() or target:name()
local importfile_src = path.join(os.programdir(), "scripts", "cmake_importfiles", filename)
local importfile_dst = path.join(libdir, "cmake", projectname, (filename:gsub("xxx", projectname)))
@@ -127,10 +131,9 @@ end
-- install cmake target file
function _install_cmake_targetfile(target, installdir, filename, opt)
- opt = opt or {}
-- get import file path
- local libdir = opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
+ local libdir = _get_install_libdir(target, installdir, opt)
local projectname = project.name() or target:name()
local importfile_src = path.join(os.programdir(), "scripts", "cmake_importfiles", filename)
local importfile_dst = path.join(libdir, "cmake", projectname, (filename:gsub("xxx", target:name())))
From 6c20d1006e21b8fe6ac33f65f8600152b81830b1 Mon Sep 17 00:00:00 2001
From: ruki <waruqi@gmail.com>
Date: Mon, 12 Jan 2026 22:55:01 +0800
Subject: [PATCH 4/4] improve installdir
---
.../target/action/install/cmake_importfiles.lua | 13 +++++++------
.../target/action/install/pkgconfig_importfiles.lua | 5 ++++-
2 files changed, 11 insertions(+), 7 deletions(-)
diff --git a/xmake/modules/target/action/install/cmake_importfiles.lua b/xmake/modules/target/action/install/cmake_importfiles.lua
index b4efecb0862..c9c45455466 100644
--- a/xmake/modules/target/action/install/cmake_importfiles.lua
+++ b/xmake/modules/target/action/install/cmake_importfiles.lua
@@ -24,11 +24,11 @@ import("core.project.project")
-- get install libdir
function _get_install_libdir(target, installdir, opt)
opt = opt or {}
- return opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
+ return path.normalize(opt.libdir and path.join(installdir, opt.libdir) or target:libdir())
end
-- get the lib file of the target
-function _get_libfile(target, libdir)
+function _get_libfilename(target, libdir)
local libfile = path.filename(target:targetfile())
if target:is_plat("windows") then
libfile = libfile:gsub("%.dll$", ".lib")
@@ -59,7 +59,7 @@ function _get_builtinvars(target, installdir, libdir)
return {LIBDIR = libsubdir,
TARGETNAME = target:name(),
PROJECTNAME = project.name() or target:name(),
- TARGETFILENAME = target:targetfile() and _get_libfile(target, libdir),
+ TARGETFILENAME = target:targetfile() and _get_libfilename(target, libdir),
TARGETKIND = target:is_headeronly() and "INTERFACE" or (target:is_shared() and "SHARED" or "STATIC"),
PACKAGE_VERSION = target:get("version") or "1.0.0",
TARGET_PTRBYTES = target_ptrbytes}
@@ -152,14 +152,14 @@ function _install_cmake_targetfile(target, installdir, filename, opt)
local value = builtinvars[variable]
return type(value) == "function" and value() or value
end)
- local libfile = path.filename(target:targetfile())
+ local libfilename = path.filename(target:targetfile())
local postfix = is_mode("debug") and "DEBUG" or "RELEASE"
- if target:is_shared() and (_get_libfile(target, libdir) ~= libfile) then
+ if target:is_shared() and (_get_libfilename(target, libdir) ~= libfilename) then
-- On DLL platforms, the import library is named differently from the target file
content = content:gsub("# IMPORTED_IMPLIB_" .. postfix, "IMPORTED_IMPLIB_" .. postfix)
content = content:gsub(
"IMPORTED_LOCATION_" .. postfix .. " \"%${_IMPORT_PREFIX}/lib/.-\"",
- "IMPORTED_LOCATION_" .. postfix .. " \"${_IMPORT_PREFIX}/bin/" .. libfile .. "\""
+ "IMPORTED_LOCATION_" .. postfix .. " \"${_IMPORT_PREFIX}/bin/" .. libfilename .. "\""
)
end
io.writefile(importfile_dst, content)
@@ -180,6 +180,7 @@ function main(target, opt)
end
-- do install
+ installdir = path.normalize(installdir)
_append_cmake_configfile(target, installdir, "xxxConfig.cmake", opt)
_install_cmake_configfile(target, installdir, "xxxConfigVersion.cmake", opt)
_install_cmake_targetfile(target, installdir, "xxxTargets.cmake", opt)
diff --git a/xmake/modules/target/action/install/pkgconfig_importfiles.lua b/xmake/modules/target/action/install/pkgconfig_importfiles.lua
index cdeb42831bb..9a9b8ee8107 100644
--- a/xmake/modules/target/action/install/pkgconfig_importfiles.lua
+++ b/xmake/modules/target/action/install/pkgconfig_importfiles.lua
@@ -30,8 +30,11 @@ function main(target, opt)
end
-- get pkgconfig/.pc file
- local libdir = opt.libdir and path.join(installdir, opt.libdir) or target:libdir()
+ local libdir = path.unix(path.normalize(opt.libdir and path.join(installdir, opt.libdir) or target:libdir()))
local pcfile = path.join(libdir, "pkgconfig", opt.filename or (target:basename() .. ".pc"))
+ if not libdir:startswith(installdir) then
+ raise("target(%s): libdir(%s) is not in installdir(%s)", target:name(), libdir, installdir)
+ end
-- get includedirs
local includedirs = opt.includedirs

View file

@ -1,3 +1,3 @@
This repository is maintained by packit.
https://packit.dev/
The file was generated using packit 1.16.0.post1.dev2+ged481c62d.
The file was generated using packit 0.99.0.post1.dev29+g2e75e6ff.

View file

@ -1 +1 @@
SHA512 (xmake-3.0.9.tar.gz) = 6cfe09b7c946e75bf844339fcf172a275caf3ec5b1aefd651b6c191aacea7c6a9b58d9a2b95f94df723368488cd7d616fc5b936156c66162e9926bdb62b08f76
SHA512 (xmake-2.9.5.tar.gz) = eac40c2c498b9a37d4648ed1867a4d0910a075d2459114919d5f72a5ce99de075a0b3dcd0efd4acc68e97246d5f3251b63dca0888ec5b88b6cb786ce365c2e1f

View file

@ -1,7 +1,7 @@
%bcond_with luajit
Name: xmake
Version: 3.0.9
Version: 2.9.5
%global __requires_exclude_from ^%{_datadir}/%{name}/scripts/.+\\.ps1$
%global forgeurl https://github.com/xmake-io/xmake
@ -15,8 +15,9 @@ License: Apache-2.0
URL: https://xmake.io
Source: %forgesource
Patch0: 0001-system-include.patch
Patch1: 0001-add-relwithdebinfo-build-mode.patch
Patch0: 0001-pkgconfig-fix-check.patch
Patch1: 0001-system-include.patch
Patch2: 0001-add-relwithdebinfo-build-mode.patch
BuildRequires: pkgconfig(ncurses)
BuildRequires: pkgconfig(readline)
@ -27,7 +28,7 @@ BuildRequires: pkgconfig(libsv)
%if %{with luajit}
BuildRequires: pkgconfig(luajit)
%else
BuildRequires: pkgconfig(lua) >= 5.5
BuildRequires: pkgconfig(lua) >= 5.4
%endif
BuildRequires: bash