steps:
- uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
- name: Install dependencies
- run: ./build/ci/github_actions/macos.sh prepare
+ run: ./build/ci/github_actions/install-macos-dependencies.sh
- name: Autogen
run: ./build/ci/build.sh -a autogen
env:
#!/bin/sh
+set -eu
PATH=/usr/local/gnu-autotools/bin/:$PATH
-export PATH
# Start from one level above the build directory
if [ -f version ]; then
perl -p -i -e 's/(m4_define\(\[LIBARCHIVE_VERSION_N\]),.*\)/$1,['"$VN"'])/' configure.ac
# Remove developer CFLAGS if a release build is being made
-if [ -n "${MAKE_LIBARCHIVE_RELEASE}" ]; then
+if [ -n "${MAKE_LIBARCHIVE_RELEASE:-}" ]; then
perl -p -i -e "s/^(DEV_CFLAGS.*)/# \$1/" Makefile.am
perl -p -i -e 's/CMAKE_BUILD_TYPE "[A-Za-z]*"/CMAKE_BUILD_TYPE "Release"/' CMakeLists.txt
fi
#!/bin/sh +v
+set -eu
# Start from the build directory, where the version file is located
if [ -f build/version ]; then
# MAKE_ARGS= # make arguments
# DEBUG= # set -g -fsanitize=address flags
+set -eu
+
ACTIONS=
-if [ -n "${BUILD_SYSTEM}" ]; then
+if [ -n "${BUILD_SYSTEM:-}" ]; then
BS="${BUILD_SYSTEM}"
fi
BS="${BS:-autotools}"
MAKE="${MAKE:-make}"
CMAKE="${CMAKE:-cmake}"
+CMAKE_ARGS="${CMAKE_ARGS:-}"
+CONFIGURE_ARGS="${CONFIGURE_ARGS:-}"
CURDIR=`pwd`
SRCDIR="${SRCDIR:-`pwd`}"
RET=0
;;
esac
done
-case "${CRYPTO}" in
+case "${CRYPTO:-}" in
mbedtls)
CMAKE_ARGS="${CMAKE_ARGS} -DENABLE_OPENSSL=OFF -DENABLE_MBEDTLS=ON"
CONFIGURE_ARGS="${CONFIGURE_ARGS} --without-openssl --with-mbedtls"
CONFIGURE_ARGS="${CONFIGURE_ARGS} --without-openssl --with-nettle"
;;
esac
-if [ -z "${MAKE_ARGS}" ]; then
+if [ -z "${MAKE_ARGS:-}" ]; then
if [ "${BS}" = "autotools" ]; then
MAKE_ARGS="V=1"
elif [ "${BS}" = "cmake" ]; then
fi
fi
if [ -d /opt/homebrew/include ]; then
- export CFLAGS="${CFLAGS} -I/opt/homebrew/include"
+ export CFLAGS="${CFLAGS:-} -I/opt/homebrew/include"
fi
if [ -d /opt/homebrew/lib ]; then
- export LDFLAGS="${LDFLAGS} -L/opt/homebrew/lib"
+ export LDFLAGS="${LDFLAGS:-} -L/opt/homebrew/lib"
fi
-if [ -n "${DEBUG}" ]; then
- if [ -n "${CFLAGS}" ]; then
+if [ -n "${DEBUG:-}" ]; then
+ if [ -n "${CFLAGS:-}" ]; then
export CFLAGS="${CFLAGS} -g -fsanitize=address"
else
export CFLAGS="-g -fsanitize=address"
if [ -z "${BS}" ]; then
inputerror "Missing build system (-b) parameter"
fi
-if [ -z "${BUILDDIR}" ]; then
+if [ -z "${BUILDDIR:-}" ]; then
BUILDDIR="${CURDIR}/build_ci/${BS}"
fi
mkdir -p "${BUILDDIR}"
;;
esac
RET="$?"
- find ${TMPDIR:-/tmp} -path '*_test.*' -name '*.log' -print -exec cat {} \;
+ find ${TMPDIR:-/tmp} -path '*_test.*' -name '*.log' -print -exec cat {} \; 2>/dev/null || /bin/true
;;
install)
${MAKE} ${MAKE_ARGS} install DESTDIR="${BUILDDIR}/destdir"
${MAKE} ${MAKE_ARGS} distcheck || (
RET="$?"
find . -name 'test-suite.log' -print -exec cat {} \;
- find ${TMPDIR:-/tmp} -path '*_test.*' -name '*.log' -print -exec cat {} \;
+ find ${TMPDIR:-/tmp} -path '*_test.*' -name '*.log' -print -exec cat {} \; 2>/dev/null || /bin/true
exit "${RET}"
)
RET="$?"
#!/bin/sh
+set -eu
+
+if [ $# != 1 ]
+then
+ echo "Usage: $0 prepare | test"
+ exit 1
+fi
+
UNAME=`uname`
if [ "$1" = "prepare" ]
then
TMPDIR=/tmp_acl_nfsv4 ${BIN_SUBDIR}/libarchive_test -r "${CURDIR}/libarchive/test" -v test_acl_platform_nfs4
fi
else
- echo "Usage $0 prepare | test_nfsv4_acls"
+ echo "Usage: $0 prepare | test"
exit 1
fi
--- /dev/null
+#!/bin/sh
+set -eux
+
+# Uncommenting these adds a full minute to the CI time
+#brew update > /dev/null
+#brew upgrade > /dev/null
+
+# This does an upgrade if the package is already installed
+brew install \
+ autoconf \
+ automake \
+ libtool \
+ pkg-config \
+ cmake \
+ xz \
+ lz4 \
+ zstd \
+ libxml2 \
+ openssl
+++ /dev/null
-#!/bin/sh
-if [ "$1" = "prepare" ]
-then
- set -x -e
- #Uncommenting these adds a full minute to the CI time
- #brew update > /dev/null
- #brew upgrade > /dev/null
-
- # This does an upgrade if the package is already installed
- brew install \
- autoconf \
- automake \
- libtool \
- pkg-config \
- cmake \
- xz \
- lz4 \
- zstd \
- libxml2 \
- openssl
-fi
#!/bin/sh
+set -eu
#
# Attempt to remove as many generated files as we can.
#!/bin/sh
+set -eu
#
# This script exists primarily to document some of the
#
PATH=/usr/local/gnu-autotools/bin/:$PATH
-export PATH
# Start from one level above the build directory
if [ -f version ]; then
# Makefile. Effectively disable it.
export MAKEOBJDIRPREFIX=/junk
-set -ex
+set -x
#
# Scrub the local tree before running the build tests below.
#!/bin/sh
+set -eu
+
ID=$(docker build -q -f build/release/Dockerfile .)
if [ -z "$ID" ]; then
echo "Failed to build docker image"
exit 1
else
- docker run $ID sh -c "tar -c -f - libarchive-*" | tar -x -f -
+ docker run "$ID" sh -c "tar -c -f - libarchive-*" | tar -x -f -
fi
#!/bin/sh
+set -eu
+
+if [ $# != 1 ]
+then
+ echo "Usage: $0 path/to/UnicodeData.txt"
+ exit 1
+fi
+
#
# This needs http://unicode.org/Public/6.0.0/ucd/UnicodeData.txt
#
#!/bin/sh
-
-set -e
+set -eu
#
# Simple script to repopulate the 'doc' tree from
# the mdoc man pages stored in each project.
#
+script_dir=`dirname $0`
+cd "$script_dir"
+
# Collect list of man pages, relative to my subdirs
test -d man || mkdir man
cd man