#1: Set ports library version #2: Don't pick up an installed linux/e2fsprogs libuuid.so #3: llvm-ar (used for LTO) is installed as ar #4: OpenBSD isn't multi-arch Index: configure.ac --- configure.ac.orig +++ configure.ac @@ -126,7 +126,7 @@ VERSION=PYTHON_VERSION # Version number of Python's own shared library file. AC_SUBST(SOVERSION) -SOVERSION=1.0 +SOVERSION=${LIBpython3.10_VERSION} # The later defininition of _XOPEN_SOURCE disables certain features # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone). @@ -483,7 +483,7 @@ case $ac_sys_system/$ac_sys_release in # As this has a different meaning on Linux, only define it on OpenBSD AC_DEFINE(_BSD_SOURCE, 1, [Define on OpenBSD to activate all library features]) ;; - OpenBSD/*) + OpenBSD/* | SecBSD/*) # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is # also defined. This can be overridden by defining _BSD_SOURCE # As this has a different meaning on Linux, only define it on OpenBSD @@ -876,6 +876,8 @@ AC_MSG_CHECKING([for multiarch]) AS_CASE([$ac_sys_system], [Darwin*], [MULTIARCH=""], [FreeBSD*], [MULTIARCH=""], + [OpenBSD*], [MULTIARCH=""], + [SecBSD*], [MULTIARCH=""], [MULTIARCH=$($CC --print-multiarch 2>/dev/null)] ) AC_SUBST([MULTIARCH]) @@ -1149,7 +1151,7 @@ if test $enable_shared = "yes"; then PY3LIBRARY=libpython3.so fi ;; - Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*|OpenBSD*|VxWorks*) + Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*|OpenBSD*|SecBSD*|VxWorks*) LDLIBRARY='libpython$(LDVERSION).so' BLDLIBRARY='-L. -lpython$(LDVERSION)' RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}} @@ -1380,9 +1382,9 @@ fi], [AC_MSG_RESULT(no)]) if test "$Py_LTO" = 'true' ; then case $CC in - *clang*) + *clang*|cc) AC_SUBST(LLVM_AR) - AC_PATH_TOOL(LLVM_AR, llvm-ar, '', ${llvm_path}) + AC_PATH_TOOL(LLVM_AR, ar, '', ${llvm_path}) AC_SUBST(LLVM_AR_FOUND) if test -n "${LLVM_AR}" -a -x "${LLVM_AR}" then @@ -1473,7 +1475,7 @@ then fi LLVM_PROF_ERR=no case $CC in - *clang*) + *clang*|cc) # Any changes made here should be reflected in the GCC+Darwin case below PGO_PROF_GEN_FLAG="-fprofile-instr-generate" PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd" @@ -2723,7 +2725,7 @@ then else LDSHARED="ld -Bshareable" fi;; - OpenBSD*) + OpenBSD*|SecBSD*) if [[ "`$CC -dM -E - ]], [[ -#ifndef uuid_generate_time_safe -void *x = uuid_generate_time_safe -#endif -]])], - [AC_DEFINE(HAVE_UUID_GENERATE_TIME_SAFE, 1, Define if uuid_generate_time_safe() exists.) - AC_MSG_RESULT(yes)], - [AC_MSG_RESULT(no)] -) +AC_CHECK_HEADERS([uuid.h]) # check for libuuid from util-linux save_LIBS=$LIBS