morebuilds #1813
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: morebuilds | |
on: | |
schedule: | |
# run at CST 10:00 and 22:00 | |
- cron: '0 2,14 * * *' | |
# Allows to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
build-erofs-utils: | |
runs-on: ubuntu-22.04 | |
strategy: | |
matrix: | |
pass: [1, 2] | |
compiler: [gcc, clang] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build erofs-utilis | |
env: | |
CC: ${{ matrix.compiler }} | |
run: | | |
COMPILER_FLAGS=( "-m32" "-mx32" ) | |
CFLAGS=${COMPILER_FLAGS[${{ matrix.pass }}]} | |
sudo dpkg --add-architecture i386 | |
sudo apt-get -qq update | |
sudo apt-get install -y libc6-dev-i386 lib32gcc-10-dev libx32gcc-10-dev zlib1g-dev:i386 libx32z1-dev lib32z1-dev | |
[ "${{ matrix.compiler }}" = "clang" ] && sudo apt-get install -y clang++-10 | |
[ "${{ matrix.compiler }}" = "gcc" ] && sudo apt-get install gcc-multilib | |
sudo apt-get install -y libpcre2-8-0:i386 | |
curl -L https://github.com/lz4/lz4/archive/refs/tags/v1.9.4.tar.gz | tar -zxv | |
make BUILD_SHARED=no -C lz4-1.9.4 MOREFLAGS=${CFLAGS} && lz4libdir=$(pwd)/lz4-1.9.4/lib | |
git clone git://git.kernel.org/pub/scm/linux/kernel/git/xiang/erofs-utils.git -b experimental | |
cd erofs-utils | |
mkdir output | |
./autogen.sh && ./configure --enable-debug --enable-werror --without-uuid --disable-fuse \ | |
--host=i686-linux-gnu \ | |
--prefix=$(pwd)/output \ | |
--with-lz4-incdir=${lz4libdir} --with-lz4-libdir=${lz4libdir} \ | |
"CFLAGS=${CFLAGS}" "CPPFLAGS=${CFLAGS}" "CXXFLAGS=${CFLAGS}" "LDFLAGS=${CFLAGS}" && \ | |
make && make install |