commit 835caeb047444efa37db22ed370f88a7ea2e549f from: Thomas Adam date: Thu Jun 06 19:33:36 2024 UTC CI: Macos fixes Add host detection so we can identify the different platforms we support for CI. In doing so, update LDFLAGS, CPPFLAGS, etc., as per the instructions for when these packages are installed, so that they're visible to us. commit - b93c86aa2f37e6a464d11e46caecb11dab056176 commit + 835caeb047444efa37db22ed370f88a7ea2e549f blob - 3b66571a2374813247041b0c445fd305165a84db blob + e97e25722132465c874f58a2eb73ac925dd3096f --- configure.ac +++ configure.ac @@ -41,6 +41,33 @@ AS_IF([test "x$with_libbsd" = "xyes"], [ ]) ]) +AC_MSG_CHECKING([platform]) +case "$host_os" in + *darwin*) + PLATFORM=darwin + ;; + *linux*) + PLATFORM=linux + ;; + *freebsd*) + PLATFORM=freebsd + ;; + *openbsd*) + PLATFORM=openbsd + ;; + *) + PLATFORM=unknown + ;; +esac +AC_MSG_RESULT($PLATFORM) +AC_SUBST(PLATFORM) + +if test "x$PLATFORM" = "xdarwin"; then + export LDFLAGS="-L/opt/homebrew/opt/libressl/lib $LDFLAGS" + export CPPFLAGS="-I/opt/homebrew/opt/libressl/include $CPPFLAGS" + export PKG_CONFIG_PATH="/opt/homebrew/opt/libressl/lib/pkgconfig $PKG_CONFIG_PATH" +fi + AC_REPLACE_FUNCS([ asprintf \ err \