summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Eden <sven.eden@prydeworx.com>2023-07-12 15:46:47 +0200
committerSven Eden <sven.eden@prydeworx.com>2023-07-12 15:46:47 +0200
commit71d62003edef681ca0477653895f6cb84f44a564 (patch)
tree47b9f7f1f879bad46e28d53fd024d4ecee0be032
parentmedia-libs/mlt: update Manifest (diff)
downloadseden-71d62003edef681ca0477653895f6cb84f44a564.tar.gz
seden-71d62003edef681ca0477653895f6cb84f44a564.tar.bz2
seden-71d62003edef681ca0477653895f6cb84f44a564.zip
app-arch/7-zip: new package, add 23.01
Signed-off-by: Sven Eden <sven.eden@prydeworx.com>
-rw-r--r--app-arch/7-zip/7-zip-23.01.ebuild68
-rw-r--r--app-arch/7-zip/Manifest3
-rw-r--r--app-arch/7-zip/files/7-zip-flags.patch31
3 files changed, 102 insertions, 0 deletions
diff --git a/app-arch/7-zip/7-zip-23.01.ebuild b/app-arch/7-zip/7-zip-23.01.ebuild
new file mode 100644
index 0000000..2b29b46
--- /dev/null
+++ b/app-arch/7-zip/7-zip-23.01.ebuild
@@ -0,0 +1,68 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit toolchain-funcs
+
+DESCRIPTION="A file archiver with a high compression ratio"
+HOMEPAGE="https://7-zip.org"
+SRC_URI="mirror://sourceforge/project/sevenzip/7-Zip/${PV}/7z$(ver_rs 1 '')-src.tar.xz"
+RESTRICT="primaryuri"
+S="${WORKDIR}"
+
+LICENSE="LGPL-2.1 BSD rar? ( unRAR )"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="+asm rar static"
+
+RDEPEND=""
+DEPEND="${RDEPEND}"
+BDEPEND="
+ asm? ( dev-lang/jwasm )
+"
+
+DOCS=(
+ DOC/7zC.txt
+ DOC/7zFormat.txt
+ DOC/lzma.txt
+ DOC/Methods.txt
+ DOC/readme.txt
+ DOC/src-history.txt
+)
+
+PATCHES=(
+ "${FILESDIR}/7-zip-flags.patch"
+)
+
+src_prepare() {
+ # Fix line endings so 7-zip-flags.patch
+ sed -i \
+ -e 's/\r$//' \
+ CPP/7zip/7zip_gcc.mak C/7zip_gcc_c.mak \
+ || die 'sed failed'
+ default
+}
+
+src_compile() {
+ local myemakeargs=(
+ CFLAGS_BASE2="${CFLAGS}"
+ CXXFLAGS_BASE2="${CXXFLAGS}"
+ CFLAGS_WARN_WALL='-Wall -Wextra'
+ IS_X64=1
+ USE_ASM=$(usex asm 1 '')
+ USE_JWASM=$(usex asm 1 '')
+ COMPL_STATIC=$(usex static 1 '')
+ O="${S}"
+ DISABLE_RAR=$(usex rar '' 1)
+ )
+ tc-env_build emake \
+ -C CPP/7zip/Bundles/Alone2 \
+ -f makefile.gcc \
+ "${myemakeargs[@]}"
+}
+
+src_install() {
+ dobin 7zz$(usex static 's' '')
+ einstalldocs
+}
diff --git a/app-arch/7-zip/Manifest b/app-arch/7-zip/Manifest
new file mode 100644
index 0000000..755fd2a
--- /dev/null
+++ b/app-arch/7-zip/Manifest
@@ -0,0 +1,3 @@
+AUX 7-zip-flags.patch 847 BLAKE2B 5f4a924072062a4ac02734024f325804b35c55685781405eeaa77d63081926610ad34ef7985a8907d99ca3b9a83232fb1570e1a12a8c87d4fdd83ea94513fabf SHA512 04b84cd06d676a77916e46102dd3023f0c3720a903fb8b4c3d5bfc987a41173690bfe464bd8a0cf77d9de5a94b2c77bebe3453017d5e8dac466b18c632a7840e
+DIST 7z2301-src.tar.xz 1378588 BLAKE2B 348484b24b39db70e513fe50d79954ea0e2dd669f83e3601fa796c8f0ca4734132ca20fac8cda9b8ba550bad9146627fc0ae07056abb99028ef6d825b6a533bd SHA512 e39f660c023aa65e55388be225b5591fe2a5c9138693f3c9107e2eb4ce97fafde118d3375e01ada99d29de9633f56221b5b3d640c982178884670cd84c8aa986
+EBUILD 7-zip-23.01.ebuild 1266 BLAKE2B d57378efd4e9825906fe716f8ae5a982e5e7b47915222ec480be16a009a190ac913d81d1bdd98ad2bad2fb80e3e6730323a8a24225ca8c6b35430e624fdf8f10 SHA512 4257df18ba7491cf885d335921442b37a2a4f9ed95513f9402a18f68adf762878e57c04f9325eea0dd66ae03f9cf1b2ea11358b19304640294bd3f36559b3599
diff --git a/app-arch/7-zip/files/7-zip-flags.patch b/app-arch/7-zip/files/7-zip-flags.patch
new file mode 100644
index 0000000..0534b39
--- /dev/null
+++ b/app-arch/7-zip/files/7-zip-flags.patch
@@ -0,0 +1,31 @@
+--- a/CPP/7zip/7zip_gcc.mak 2023-07-12 15:09:43.264812100 +0200
++++ b/CPP/7zip/7zip_gcc.mak 2023-07-12 15:11:34.326817937 +0200
+@@ -142,7 +142,7 @@
+
+ # LOCAL_LIBS=-lpthread
+ # LOCAL_LIBS_DLL=$(LOCAL_LIBS) -ldl
+-LIB2 = -lpthread -ldl
++LIB2 = -lpthread -ldl -z noexecstack
+
+
+ endif
+@@ -208,7 +208,7 @@
+ # -Wl,--print-gc-sections
+
+ ifneq ($(CC), $(CROSS_COMPILE)clang)
+-LFLAGS_STRIP = -s
++LFLAGS_STRIP =
+ endif
+
+ LFLAGS_ALL = $(LFLAGS_STRIP) $(MY_ARCH_2) $(LDFLAGS) $(FLAGS_FLTO) $(LD_arch) $(OBJS) $(MY_LIBS) $(LIB2)
+--- a/C/7zip_gcc_c.mak 2023-07-12 15:41:03.355910913 +0200
++++ b/C/7zip_gcc_c.mak 2023-07-12 15:41:35.353912595 +0200
+@@ -121,7 +121,7 @@
+
+ # LOCAL_LIBS=-lpthread
+ # LOCAL_LIBS_DLL=$(LOCAL_LIBS) -ldl
+-LIB2 = -lpthread -ldl
++LIB2 = -lpthread -ldl -z noexecstack
+
+ DEL_OBJ_EXE = -$(RM) $(PROGPATH) $(PROGPATH_STATIC) $(OBJS)
+