diff --git a/build-scripts/lz4.build b/build-scripts/lz4.build new file mode 100644 index 0000000..becc687 --- /dev/null +++ b/build-scripts/lz4.build @@ -0,0 +1,52 @@ +#! /bin/bash + +# lz4 +# Source: https://github.com/lz4/lz4/archive/v1.9.3.tar.gz +# +# $BUILD = Directory to temporarily install +# $PKGS = Directory to store built packages +# +# DEPS +# Required: NONE +# Recommended: NONE +# Optional: NONE + +make PREFIX=/usr -j2 && \ + +sudo -S make PREFIX=/usr DESTDIR=$BUILD install && \ +sudo -S mkdir -pv /BMAN/install /BMAN/usr && \ +sudo -S mv $BUILD/usr/share /BMAN/usr/ && \ + +cd $BUILD && sudo -S mkdir -v ${BUILD}/install && +cat > /tmp/slack-desc << "EOF" +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +lz4: lz4 +lz4: +lz4: LZ4 is lossless compression algorithm with fast decoder @ multiple +lz4: GB/s per core. +lz4: +lz4: https://github.com/lz4/lz4 +lz4 +EOF +sudo -S mv -v /tmp/slack-desc install/ && +sudo -S makepkg -l y -c n $PKGS/lz4-1.9.3-$(uname -m)-mlfs.txz && \ +cd /BMAN && \ +cat > /tmp/slack-desc << "EOF" +lz4-doc: Manpages for lz4 +lz4-doc: +lz4-doc: LZ4 is lossless compression algorithm with fast decoder @ multiple +lz4-doc: GB/s per core. +lz4-doc: +lz4-doc: https://github.com/lz4/lz4 +lz4-doc: +EOF +sudo -S mv -v /tmp/slack-desc install/ && +sudo -S makepkg -l y -c n $PKGS/lz4-doc-1.9.3-noarch-mlfs.txz && \ +sudo -S rm -rf ${BUILD}/* /BMAN/* diff --git a/build-scripts/squashfs-tools.sh b/build-scripts/squashfs-tools.sh new file mode 100644 index 0000000..f9153ad --- /dev/null +++ b/build-scripts/squashfs-tools.sh @@ -0,0 +1,47 @@ +#! /bin/bash + +# Squashfs-Tools +# Source: https://github.com/plougher/squashfs-tools/archive/4.5.tar.gz +# +# $BUILD = Directory to temporarily install +# $PKGS = Directory to store built packages +# +# DEPS +# Required: lz4 +# Recommended: NONE +# Optional: NONE + +# Apply patches from Alpine Linux +patch -Np1 -i ../patches/squashfs-tools-alpine/0001-unsquashfs-use-squashfs_closedir-to-delete-directory.patch +patch -Np1 -i ../patches/squashfs-tools-alpine/0002-unsquashfs-dynamically-allocate-name.patch +patch -Np1 -i ../patches/squashfs-tools-alpine/0003-unsquashfs-use-linked-list-to-store-directory-names.patch +patch -Np1 -i ../patches/squashfs-tools-alpine/0004-Unsquashfs-additional-write-outside-destination-dire.patch +patch -Np1 -i ../patches/squashfs-tools-alpine/0005-Unsquashfs-Add-makefile-entry-for-unsquash-12.o.patch +patch -Np1 -i ../patches/squashfs-tools-alpine/fix-compat.patch + +make -C squashfs-tools XZ_SUPPORT=1 LZO_SUPPORT=1 LZ4_SUPPORT=1 ZSTD_SUPPORT=1 -j2 && \ + +sudo -S mkdir -pv $BUILD/usr/sbin && \ +sudo -S cp -a squashfs-tools/*squashfs $BUILD/usr/sbin && \ + +cd $BUILD && sudo -S mkdir -v ${BUILD}/install && +cat > /tmp/slack-desc << "EOF" +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +squashfs-tools: squashfs-tools +squashfs-tools: +squashfs-tools: Tools for squashfs, a highly compressed read-only filesystem for +squashfs-tools: Linux. +squashfs-tools: +squashfs-tools: https://github.com/plougher/squashfs-tools +squashfs-tools: +EOF +sudo -S mv -v /tmp/slack-desc install/ && +sudo -S makepkg -l y -c n $PKGS/squashfs-tools-4.5-$(uname -m)-mlfs.txz && +sudo -S rm -rf ${BUILD}/*