Azathothas / Toolpacks

Official (pkgforge-edge) Repo 📦📀 & The Largest Collection of Pre-Compiled (+ UPXed) Linux Static Binaries (incl. Build Scripts) & Package Manager (rust) :: https://github.com/pkgforge/soar
https://bin.pkgforge.dev/
MIT License
151 stars 16 forks source link

[PKG REQUEST] dwarfs for all available archs #33

Closed xplshn closed 2 months ago

xplshn commented 2 months ago

DWARFS is a high efficienty compression FUSE filesystem and archival&compression format, its readme includes a "Static Builds" section. I'd appreciate it if this was added to Toolpacks :)

It can be built within Alpine easily, since we have -static versions of library packages.

# This has been tested with ubuntu-22.04-live-server-amd64.iso. First, install all the packages listed as dependencies above. Also install:

$ apt install ccache ninja libacl1-dev
# ccache and ninja are optional, but help with a speedy compile.

# Depending on your distribution, you'll need to build and install static versions of some libraries, e.g. libarchive and libmagic for Ubuntu:

$ wget https://github.com/libarchive/libarchive/releases/download/v3.6.2/libarchive-3.6.2.tar.xz
$ tar xf libarchive-3.6.2.tar.xz && cd libarchive-3.6.2
$ ./configure --prefix=/opt/static-libs --without-iconv --without-xml2 --without-expat
$ make && sudo make install
$ wget ftp://ftp.astron.com/pub/file/file-5.44.tar.gz
$ tar xf file-5.44.tar.gz && cd file-5.44
$ ./configure --prefix=/opt/static-libs --enable-static=yes --enable-shared=no
$ make && make install
# That's it! Now you can try building static binaries for DwarFS:

$ git clone --recurse-submodules https://github.com/mhx/dwarfs
$ cd dwarfs && mkdir build && cd build
$ cmake .. -GNinja -DWITH_TESTS=ON -DSTATIC_BUILD_DO_NOT_USE=ON \
           -DSTATIC_BUILD_EXTRA_PREFIX=/opt/static-libs
$ ninja
$ ninja test

https://github.com/mhx/dwarfs

Azathothas commented 2 months ago

Refuses to build with nix musl because has dependencies on python and such. The readme itself warns static-linking isn't recommended. This will require manual work, will take a look when I have time.

xplshn commented 2 months ago

BTW: Static binary releases for aarch64 and x86_64 (linux) are available: https://github.com/mhx/dwarfs/releases

image

Azathothas commented 2 months ago

Added https://github.com/Azathothas/Toolpacks/commit/a000968f67e977636d55169e31da44388678307e The binary is named dwarfs-tools to explicitly make it print that it's a multi-call binary and leave it to the user to rename/symlink it. image

image