Skip to content

Commit 883175f

Browse files
committed
build: Updates for OpenBSD
- LevelDB platform was not guessed correctly (it ended up defining `-DOS_OPENBSD59` instead of `-DOS_OPENBSD`) - On OpenBSD there is no convenience link from `python3.5` to `python3`: add detection for other python interpreter names. - If it has to guess the LevelDB OS, print a autoconf warning so that the user can check.
1 parent 12892db commit 883175f

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

configure.ac

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,8 @@ AC_PATH_TOOL(RANLIB, ranlib)
6666
AC_PATH_TOOL(STRIP, strip)
6767
AC_PATH_TOOL(GCOV, gcov)
6868
AC_PATH_PROG(LCOV, lcov)
69-
AC_PATH_PROGS([PYTHON], [python3 python2.7 python2 python])
69+
dnl Python 3.x is supported from 3.4 on (see https://github.com/bitcoin/bitcoin/issues/7893)
70+
AC_PATH_PROGS([PYTHON], [python3.6 python3.5 python3.4 python3 python2.7 python2 python])
7071
AC_PATH_PROG(GENHTML, genhtml)
7172
AC_PATH_PROG([GIT], [git])
7273
AC_PATH_PROG(CCACHE,ccache)
@@ -355,8 +356,15 @@ case $host in
355356
TARGET_OS=linux
356357
LEVELDB_TARGET_FLAGS="-DOS_LINUX"
357358
;;
359+
*freebsd*)
360+
LEVELDB_TARGET_FLAGS="-DOS_FREEBSD"
361+
;;
362+
*openbsd*)
363+
LEVELDB_TARGET_FLAGS="-DOS_OPENBSD"
364+
;;
358365
*)
359366
OTHER_OS=`echo ${host_os} | awk '{print toupper($0)}'`
367+
AC_MSG_WARN([Guessing LevelDB OS as OS_${OTHER_OS}, please check whether this is correct, if not add an entry to configure.ac.])
360368
LEVELDB_TARGET_FLAGS="-DOS_${OTHER_OS}"
361369
;;
362370
esac

0 commit comments

Comments
 (0)