]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
ci: fix macos build 11138/head 11140/head
authorPhilippe Antoine <pantoine@oisf.net>
Tue, 23 Apr 2024 21:29:19 +0000 (23:29 +0200)
committerPhilippe Antoine <pantoine@oisf.net>
Thu, 23 May 2024 20:14:00 +0000 (22:14 +0200)
use brew instead of pip
limit the number of jobs for make
set a prefix where we can install
use brew flags for library finding

(cherry picked from commit 47a1502dbb0d9ef43a820c956d0396c83b488e07)

.github/workflows/builds.yml

index bc1ef3f560b4a8d2d3fbc2a6fec11d502ed0c80a..196a025950745db2e8edd7e30db12449a6a73321 100644 (file)
@@ -1341,6 +1341,7 @@ jobs:
           libnet \
           libtool \
           libyaml \
+          pyyaml \
           lua \
           nss \
           nspr \
@@ -1352,7 +1353,6 @@ jobs:
       - name: Install cbindgen
         run: cargo install --force --debug --version 0.14.1 cbindgen
       - run: echo "$HOME/.cargo/bin" >> $GITHUB_PATH
-      - run: pip3 install PyYAML
       - uses: actions/checkout@dcd71f646680f2efd8db4afa5ad64fdcba30e748
       - name: Downloading prep archive
         uses: actions/download-artifact@v2
@@ -1362,8 +1362,8 @@ jobs:
       - run: tar xvf prep/libhtp.tar.gz
       - run: tar xvf prep/suricata-update.tar.gz
       - run: ./autogen.sh
-      - run: CFLAGS="${DEFAULT_CFLAGS}" CPPFLAGS="-I/usr/local/opt/libiconv/include" CXXFLAGS="-I/usr/local/opt/libiconv/include" LDFLAGS="-L/usr/local/opt/libiconv/lib" ./configure --enable-unittests
-      - run: make -j2
+      - run: CPATH="$HOMEBREW_PREFIX/include:$CPATH" LIBRARY_PATH="$HOMEBREW_PREFIX/lib:$LIBRARY_PATH" PATH="/opt/homebrew/opt/libtool/libexec/gnubin:$PATH" CFLAGS="${DEFAULT_CFLAGS}" ./configure --enable-unittests --prefix="$HOME/.local/"
+      - run: CPATH="$HOMEBREW_PREFIX/include:$CPATH" LIBRARY_PATH="$HOMEBREW_PREFIX/lib:$LIBRARY_PATH" PATH="/opt/homebrew/opt/libtool/libexec/gnubin:$PATH" CFLAGS="${DEFAULT_CFLAGS}" make -j2
       # somehow it gets included by some C++ stdlib header (case unsensitive)
       - run: rm libhtp/VERSION && make check
       - run: tar xf prep/suricata-verify.tar.gz