aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dev-build/xmake/Manifest1
-rw-r--r--dev-build/xmake/xmake-2.8.9.ebuild68
2 files changed, 69 insertions, 0 deletions
diff --git a/dev-build/xmake/Manifest b/dev-build/xmake/Manifest
index 9e8a0d40d..b37ca6375 100644
--- a/dev-build/xmake/Manifest
+++ b/dev-build/xmake/Manifest
@@ -1 +1,2 @@
DIST xmake-v2.8.8.tar.gz 2810801 BLAKE2B 79a877ebfbd99e034a5bb5767c1522304261024d96338671215dba0fd368737eca0603051c521859276ab811465e6c54548bb02582e5aea9d7c44387846701ec SHA512 538b33cb54a7aefc52edff1cc77144ba3d3b273f11d3b8cfa1cfac744b868467ff3ad0dc3bc39046648819b73badb7e8c9eb485d98cccf81da048a74470831a0
+DIST xmake-v2.8.9.tar.gz 2814291 BLAKE2B 8a7ba74e2a8374e34f4fd4a70a1c0c5365954d5f30093d08d5054d1f4697b98049abee6b105f3830a2bbf4dfc0fc140b536d291bc71747414e37af012b5308a6 SHA512 63edfd8ef71a363f4587fa819eb538182b3770215d9b7e844c92aa2dca07f712a5c49cea1947cad84189bc5df1350a62e6c4a6b1c23e55425220857749e39f11
diff --git a/dev-build/xmake/xmake-2.8.9.ebuild b/dev-build/xmake/xmake-2.8.9.ebuild
new file mode 100644
index 000000000..25ed5aa18
--- /dev/null
+++ b/dev-build/xmake/xmake-2.8.9.ebuild
@@ -0,0 +1,68 @@
+# Copyright 2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit optfeature shell-completion
+
+DESCRIPTION="A cross-platform build utility based on Lua"
+HOMEPAGE="https://xmake.io"
+
+if [[ ${PV} == *9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/xmake-io/${PN}.git"
+else
+ SRC_URI="https://github.com/xmake-io/${PN}/releases/download/v${PV}/${PN}-v${PV}.tar.gz"
+ KEYWORDS="~amd64 ~riscv ~x86"
+fi
+
+LICENSE="Apache-2.0"
+SLOT="0"
+# tarball doesn't provide tests
+RESTRICT="test"
+
+DEPEND="
+ sys-libs/ncurses:=
+ sys-libs/readline:=
+"
+BDEPEND="
+ virtual/pkgconfig
+"
+RDEPEND="
+ ${DEPEND}
+ ${BDEPEND}
+"
+
+DOCS=(
+ CHANGELOG.md CODE_OF_CONDUCT.md CONTRIBUTING.md
+ NOTICE.md README.md README_zh.md
+)
+
+src_prepare() {
+ default
+
+ # Don't strip binaries
+ sed -i 's/"-s"/""/' configure || die
+}
+
+src_configure() {
+ econf --prefix="${EPREFIX}"/usr \
+ --plat=linux
+ # --plat=linux is necessary, which enables correct directory:
+ # build/linux/ARCH other than build/ARCH/ARCH
+}
+
+src_install() {
+ default
+
+ doman scripts/man/*
+
+ newbashcomp xmake/scripts/completions/register-completions.bash xmake
+ bashcomp_alias xmake xrepo
+ newzshcomp xmake/scripts/completions/register-completions.zsh _xmake
+ newfishcomp xmake/scripts/completions/register-completions.fish xmake.fish
+}
+
+pkg_postinst() {
+ optfeature "cached compilation for your xmake projects" dev-util/ccache
+}