2 on: [pull_request, push]
4 DEF_CFLAGS: -O2 -g -Wall -Werror
5 DEPENDENCIES: autoconf automake libtool pkg-config libfuse-dev ntfs-3g-dev
9 name: Build and test with gcc
10 runs-on: ubuntu-latest
12 - uses: actions/checkout@v3
13 - name: Install dependencies
16 sudo apt-get install -y $DEPENDENCIES
18 - run: ./configure CC=gcc CFLAGS="$DEF_CFLAGS"
19 - run: make -j8 check V=1
20 - run: make -j8 install V=1 DESTDIR=$PWD/installdir
21 - run: make -j8 uninstall V=1 DESTDIR=$PWD/installdir
22 - uses: actions/upload-artifact@v3
29 name: Build and test with clang
30 runs-on: ubuntu-latest
32 - uses: actions/checkout@v3
33 - name: Install dependencies
36 sudo apt-get install -y clang $DEPENDENCIES
38 - run: ./configure CC=clang CFLAGS="$DEF_CFLAGS"
39 - run: make -j8 check V=1
40 - run: make -j8 install V=1 DESTDIR=$PWD/installdir
41 - run: make -j8 uninstall V=1 DESTDIR=$PWD/installdir
42 - uses: actions/upload-artifact@v3
49 name: Build and test with gcc -m32
50 runs-on: ubuntu-latest
52 - uses: actions/checkout@v3
53 - name: Install dependencies
55 sudo dpkg --add-architecture i386
57 sudo apt-get install -y gcc-multilib $DEPENDENCIES
59 - run: ./configure CC=gcc CFLAGS="-m32 $DEF_CFLAGS" --without-fuse --without-ntfs-3g
60 - run: make -j8 check V=1
61 - run: make -j8 install V=1 DESTDIR=$PWD/installdir
62 - run: make -j8 uninstall V=1 DESTDIR=$PWD/installdir
63 - uses: actions/upload-artifact@v3
70 name: Build and test with ASAN enabled
71 runs-on: ubuntu-latest
73 - uses: actions/checkout@v3
74 - name: Install dependencies
77 sudo apt-get install -y clang $DEPENDENCIES
79 - run: ./configure CC=clang CFLAGS="$DEF_CFLAGS -fsanitize=address"
80 - run: make -j8 check V=1
81 - uses: actions/upload-artifact@v3
88 name: Build and test with UBSAN enabled
89 runs-on: ubuntu-latest
91 - uses: actions/checkout@v3
92 - name: Install dependencies
95 sudo apt-get install -y clang $DEPENDENCIES
97 - run: ./configure CC=clang CFLAGS="$DEF_CFLAGS -fsanitize=undefined"
98 - run: make -j8 check V=1
99 - uses: actions/upload-artifact@v3
102 name: ubsan-test-logs
105 macos-build-and-test:
106 name: Build and test on macOS
107 runs-on: macos-latest
109 - uses: actions/checkout@v3
110 - name: Install dependencies
112 brew install autoconf automake libtool pkg-config
114 - run: ./configure CFLAGS="$DEF_CFLAGS" --without-fuse --without-ntfs-3g
115 - run: make -j8 check V=1
116 - run: make -j8 install DESTDIR=$PWD/installdir
117 - run: make -j8 uninstall DESTDIR=$PWD/installdir
118 - uses: actions/upload-artifact@v3
121 name: macos-test-logs
125 name: Build on Windows
126 runs-on: windows-latest
130 - { sys: mingw32, env: i686 }
131 - { sys: mingw64, env: x86_64 }
136 - uses: actions/checkout@v3
137 - uses: msys2/setup-msys2@v2
139 msystem: ${{matrix.sys}}
147 mingw-w64-${{matrix.env}}-gcc
149 - run: CFLAGS="$DEF_CFLAGS" ./tools/make-windows-release --no-docs --no-zip
152 name: Fuzz with libFuzzer (${{matrix.target}} ${{matrix.sanitizer}})
159 sanitizer: --asan --ubsan
163 sanitizer: --asan --ubsan
167 sanitizer: --asan --ubsan
171 sanitizer: --asan --ubsan
172 runs-on: ubuntu-latest
174 - uses: actions/checkout@v3
175 - name: Install dependencies
178 sudo apt-get install -y clang $DEPENDENCIES
182 tools/libFuzzer/fuzz.sh --time=120 ${{matrix.sanitizer}} \