diff options
-rw-r--r-- | .SRCINFO | 21 | ||||
-rw-r--r-- | .gitignore | 7 | ||||
-rw-r--r-- | PKGBUILD | 51 |
3 files changed, 79 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..cca2ed27a554 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,21 @@ +pkgbase = android-riscv64-zstd + pkgdesc = Zstandard - Fast real-time compression algorithm (Android riscv64) + pkgver = 1.5.7 + pkgrel = 1 + url = http://www.zstd.net/ + arch = any + groups = android-zstd + license = BSD + license = GPL2 + makedepends = android-cmake + depends = android-riscv64-zlib + depends = android-riscv64-xz + depends = android-riscv64-lz4 + options = !strip + options = !buildflags + options = staticlibs + options = !emptydirs + source = https://github.com/facebook/zstd/archive/refs/tags/v1.5.7.tar.gz + md5sums = 619a019adbbc4536e7fb93cdbb01af3e + +pkgname = android-riscv64-zstd diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..f3ed6a151b9f --- /dev/null +++ b/.gitignore @@ -0,0 +1,7 @@ +glib/ +pkg/ +src/ +*.log +*.tar +*.xz +*.pkg.tar.zst diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..92ccf44a18bb --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,51 @@ +# Maintainer: Gonzalo Exequiel Pedone <hipersayan DOT x AT gmail DOT com> +# Contributor: seth <getchoo at tuta dot io> +# Contributor: xantares + +_android_arch=riscv64 + +pkgname=android-${_android_arch}-zstd +_pkgname=zstd +pkgver=1.5.7 +pkgrel=1 +arch=('any') +pkgdesc="Zstandard - Fast real-time compression algorithm (Android ${_android_arch})" +url="http://www.zstd.net/" +license=('BSD' + 'GPL2') +groups=('android-zstd') +depends=("android-${_android_arch}-zlib" + "android-${_android_arch}-xz" + "android-${_android_arch}-lz4") +makedepends=('android-cmake') +options=(!strip !buildflags staticlibs !emptydirs) +source=("https://github.com/facebook/zstd/archive/refs/tags/v${pkgver}.tar.gz") +md5sums=('619a019adbbc4536e7fb93cdbb01af3e') + +build() { + cd "${srcdir}/zstd-${pkgver}" + source android-env ${_android_arch} + + android-${_android_arch}-cmake \ + -S build/cmake \ + -B builddir \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_INSTALL_LIBDIR=lib \ + -DZSTD_ZLIB_SUPPORT=ON \ + -DZSTD_LZMA_SUPPORT=ON \ + -DZSTD_LZ4_SUPPORT=ON \ + -DZSTD_BUILD_CONTRIB=OFF \ + -DZSTD_BUILD_TESTS=OFF \ + -DZSTD_PROGRAMS_LINK_SHARED=OFF \ + -DZSTD_BUILD_PROGRAMS=OFF + make -C builddir $MAKEFLAGS +} + +package() { + cd "${srcdir}/zstd-${pkgver}" + source android-env ${_android_arch} + + make -C builddir DESTDIR="${pkgdir}" install + ${ANDROID_STRIP} -g "${pkgdir}/${ANDROID_PREFIX_LIB}"/*.a || true + ${ANDROID_STRIP} -g --strip-unneeded "${pkgdir}/${ANDROID_PREFIX_LIB}"/*.so +} |