Browse Source

Add support for Arch, btw

master
Antonio SJ Musumeci 1 day ago
committed by trapexit
parent
commit
6a6aa054cd
  1. 3
      Makefile
  2. 23
      buildtools/build-mergerfs
  3. 23
      buildtools/build-release
  4. 2
      buildtools/install-build-pkgs
  5. 2
      buildtools/install-build-tools
  6. 4
      vendored/libfuse/Makefile

3
Makefile

@ -94,7 +94,8 @@ TESTS_DEPS += $(DEPS)
MANPAGE := mergerfs.1
CPPFLAGS ?=
override CPPFLAGS += \
-D_FILE_OFFSET_BITS=64
-D_FILE_OFFSET_BITS=64 \
-DBOOST_UNORDERED_DISABLE_PARALLEL_ALGORITHMS
CFLAGS ?= \
$(OPT_FLAGS) \
-Wall \

23
buildtools/build-mergerfs

@ -38,18 +38,27 @@ elif [ -e /sbin/apk ]; then
elif [ -e /usr/sbin/pkg ]; then
echo "NOT YET SUPPORTED"
exit 1
elif [ -e /usr/bin/pacman ]; then
make tarball
else
echo "NOT YET SUPPORTED"
exit 1
fi
echo "Copy packages to host..."
find "${BUILDDIR}" \
-type f \
\( -name "*.deb" -or -name "*.rpm" \) \
-not -name "*dbgsym*" \
-not -name "*sym*" \
-not -name "*src.rpm" \
-exec cp -v {} /build/ \;
if [ -e /usr/bin/pacman ]; then
find "${BUILDDIR}" \
-type f \
-name "*.tar.gz" \
-exec cp -v {} /build/ \;
else
find "${BUILDDIR}" \
-type f \
\( -name "*.deb" -or -name "*.rpm" \) \
-not -name "*dbgsym*" \
-not -name "*sym*" \
-not -name "*src.rpm" \
-exec cp -v {} /build/ \;
fi
exit 0

23
buildtools/build-release

@ -47,12 +47,23 @@ def build(git_repo,
def setup():
args = ['sudo',
'apt-get',
'install',
'-fy',
'qemu-user-static',
'qemu-user-binfmt']
# Detect distribution
if os.path.exists('/usr/bin/apt-get'):
args = ['sudo',
'apt-get',
'install',
'-fy',
'qemu-user-static',
'qemu-user-binfmt']
elif os.path.exists('/usr/bin/pacman'):
args = ['sudo',
'pacman',
'-Sy',
'--noconfirm',
'qemu-user-static']
else:
print("Unsupported distribution for setup")
sys.exit(1)
print(args)
subprocess.run(args)

2
buildtools/install-build-pkgs

@ -34,4 +34,6 @@ elif [ -e /sbin/apk ]; then
elif [ -e /usr/sbin/pkg ]; then
pkg install \
git gmake gcc
elif [ -e /usr/bin/pacman ]; then
pacman -Sy --noconfirm base-devel git fakeroot
fi

2
buildtools/install-build-tools

@ -16,4 +16,6 @@ elif [ -e /sbin/apk ]; then
python3 \
qemu-user-static \
podman
elif [ -e /usr/bin/pacman ]; then
pacman -Sy --noconfirm qemu-user-static podman
fi

4
vendored/libfuse/Makefile

@ -96,7 +96,9 @@ else
STATIC_FLAGS :=
endif
CPPFLAGS ?=
CPPFLAGS ?= \
-D_FILE_OFFSET_BITS=64 \
-DBOOST_UNORDERED_DISABLE_PARALLEL_ALGORITHMS
CFLAGS ?= \
$(OPT_FLAGS) \
$(LTO_FLAGS) \

Loading…
Cancel
Save