~alpine/aports

main/squashfs-tools: add static subpackage v1 PROPOSED

Daniel Santana
Daniel Santana: 1
 main/squashfs-tools: add static subpackage

 1 files changed, 22 insertions(+), 4 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.alpinelinux.org/~alpine/aports/patches/3335/mbox | git am -3
Learn more about email & git

[PATCH] main/squashfs-tools: add static subpackage Export this patch

Daniel Santana
---
 main/squashfs-tools/APKBUILD | 26 ++++++++++++++++++++++----
 1 file changed, 22 insertions(+), 4 deletions(-)

diff --git a/main/squashfs-tools/APKBUILD b/main/squashfs-tools/APKBUILD
index 44121f25db..185c967368 100644
--- a/main/squashfs-tools/APKBUILD
+++ b/main/squashfs-tools/APKBUILD
@@ -1,12 +1,15 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=squashfs-tools
pkgver=4.4
pkgrel=0
pkgrel=1
pkgdesc="Tools for squashfs, a highly compressed read-only filesystem for Linux."
url="https://github.com/plougher/squashfs-tools"
arch="all"
license="GPL"
makedepends="zlib-dev xz-dev lzo-dev lz4-dev attr-dev zstd-dev"
makedepends="zlib-dev zlib-static xz-dev lzo-dev lz4-dev lz4-static attr-dev
	zstd-dev zstd-static"
subpackages="$pkgname-static"
options="!check" # No testsuite
source="$pkgname-$pkgver.tar.gz::https://github.com/plougher/squashfs-tools/archive/$pkgver.tar.gz
	fix-compat.patch
"
@@ -15,8 +18,16 @@ _builddir="$srcdir"/$pkgname-$pkgver

build() {
	cd "$builddir"/$pkgname
	CFLAGS="$CFLAGS -std=gnu89" \
	make XZ_SUPPORT=1 LZO_SUPPORT=1 LZ4_SUPPORT=1 ZSTD_SUPPORT=1

	export XZ_SUPPORT=1 LZO_SUPPORT=1 LZ4_SUPPORT=1 ZSTD_SUPPORT=1

	make clean
	CFLAGS="$CFLAGS -std=gnu89" LDFLAGS="$LDFLAGS -static" make
	mv mksquashfs mksquashfs.static
	mv unsquashfs unsquashfs.static

	make clean
	CFLAGS="$CFLAGS -std=gnu89" make
}

package() {
@@ -24,5 +35,12 @@ package() {
	mkdir -p "$pkgdir"/sbin
	cp -a mksquashfs unsquashfs "$pkgdir"/sbin
}

static() {
	cd "$builddir"/${pkgname%-static}
	mkdir -p "$subpkgdir"/sbin
	cp -a mksquashfs.static unsquashfs.static "$subpkgdir"/sbin
}

sha512sums="133ce437fb8c929933d52cff710b61dd9181f6f8be58250b0d6a59a7bb79a2b350f68f456b06a0e17c469409a71272d586802d570248273ddcd5dad088c00308  squashfs-tools-4.4.tar.gz
157379cf4bafb72d717f14b1bc5dc350c97a9e68a7018e0febba4b1e59f9fd90c1de8485c4ffc48a035b53be8c3aa62046281291664bee4699100cec637b0bfa  fix-compat.patch"
-- 
2.26.2
View this thread in the archives