From 08ac33bc5cd801d036512bada7a8a53cd9f83fea Mon Sep 17 00:00:00 2001 From: Chocobo1 Date: Tue, 28 Sep 2021 17:18:19 +0800 Subject: [PATCH] Add detection for OpenBSD in configure script Patch taken from downstream: http://cvsweb.openbsd.org/cgi-bin/cvsweb/ports/net/qbittorrent/qbittorrent/patches/patch-configure_ac --- configure | 12 ++++++++++++ configure.ac | 6 ++++++ 2 files changed, 18 insertions(+) diff --git a/configure b/configure index 137d2adde..4e88e2a48 100755 --- a/configure +++ b/configure @@ -5200,6 +5200,18 @@ else $as_nop printf "%s\n" "no" >&6; } fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OS is OpenBSD" >&5 +printf %s "checking whether OS is OpenBSD... " >&6; } +if expr "$host_os" : ".*openbsd.*" > /dev/null +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + LIBS="-lexecinfo $LIBS" +else $as_nop + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +fi + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OS is macOS" >&5 printf %s "checking whether OS is macOS... " >&6; } if expr "$host_os" : ".*darwin.*" > /dev/null diff --git a/configure.ac b/configure.ac index 536d7d5eb..34e024fa6 100644 --- a/configure.ac +++ b/configure.ac @@ -60,6 +60,12 @@ AS_IF([expr "$host_os" : ".*freebsd.*" > /dev/null], LIBS="-lexecinfo $LIBS"], [AC_MSG_RESULT([no])]) +AC_MSG_CHECKING([whether OS is OpenBSD]) +AS_IF([expr "$host_os" : ".*openbsd.*" > /dev/null], + [AC_MSG_RESULT([yes]) + LIBS="-lexecinfo $LIBS"], + [AC_MSG_RESULT([no])]) + AC_MSG_CHECKING([whether OS is macOS]) AS_IF([expr "$host_os" : ".*darwin.*" > /dev/null], [AC_MSG_RESULT([yes])