exchange

Base system with REST service to issue digital coins, run by the payment service provider
Log | Files | Refs | Submodules | README | LICENSE

commit a8143b31ca41d5e10c4085fc4176cf2cbd5705c5
parent 171b4accb128ee260754048f472f7e5fce9eda4b
Author: Christian Grothoff <grothoff@gnunet.org>
Date:   Sun, 12 Oct 2025 19:32:44 +0200

improve multiarch lib detection logic

Diffstat:
Mconfigure.ac | 28+++++++++++++++++-----------
1 file changed, 17 insertions(+), 11 deletions(-)

diff --git a/configure.ac b/configure.ac @@ -56,6 +56,12 @@ AC_ARG_ENABLE([only-doc], AC_MSG_RESULT($doc_only) AM_CONDITIONAL([DOC_ONLY], [test "x$doc_only" = "xyes"]) +AC_CHECK_PROG([DPKG_ARCH], [dpkg-architecture], [yes], [no]) +if test "x$DPKG_ARCH" = "xyes"; then + MULTIARCH=`dpkg-architecture -qDEB_HOST_MULTIARCH` +else + MULTIARCH="" +fi # Not indented, as most of the file falls under this one... AS_IF([test "x$doc_only" != xyes],[ @@ -138,7 +144,7 @@ AC_ARG_WITH([microhttpd], AS_CASE([$with_microhttpd], [yes], [], [no], [AC_MSG_ERROR([--with-microhttpd is required])], - [LDFLAGS="-L$with_microhttpd/lib $LDFLAGS" + [LDFLAGS="-L$with_microhttpd/lib/$MULTIARCH -L$with_microhttpd/lib/ $LDFLAGS" CPPFLAGS="-I$with_microhttpd/include $CPPFLAGS"]) MHD_VERSION_AT_LEAST([0.9.71]) @@ -153,7 +159,7 @@ AC_ARG_WITH([microhttpd2], AS_CASE([$with_microhttpd2], [yes],[], [no],[], - [LDFLAGS="-L$with_microhttpd2/lib $LDFLAGS" + [LDFLAGS="-L$with_microhttpd2/lib/$MULTIARCH -L$with_microhttpd2/lib/ $LDFLAGS" CPPFLAGS="-I$with_microhttpd2/include $CPPFLAGS"]) MHD2_VERSION_AT_LEAST([1.99.0]) @@ -169,7 +175,7 @@ AC_ARG_WITH([jansson], AS_CASE([$with_jansson], [yes], [], [no], [AC_MSG_ERROR([--with-jansson is required])], - [LDFLAGS="-L$with_jansson/lib $LDFLAGS" + [LDFLAGS="-L$with_jansson/lib/$MULTIARCH -L$with_jansson/lib/ $LDFLAGS" CPPFLAGS="-I$with_jansson/include $CPPFLAGS"]) AC_CHECK_LIB(jansson,json_dumpb, [AC_CHECK_HEADER([jansson.h],[jansson=1])]) @@ -191,7 +197,7 @@ AC_ARG_WITH(gnunet, AS_CASE([$with_gnunet], [yes], [], [no], [AC_MSG_ERROR([--with-gnunet is required])], - [LDFLAGS="-L$with_gnunet/lib $LDFLAGS" + [LDFLAGS="-L$with_gnunet/lib/$MULTIARCH -L$with_gnunet/lib/ $LDFLAGS" CPPFLAGS="-I$with_gnunet/include $CPPFLAGS"]) AC_CHECK_HEADERS([gnunet/gnunet_util_lib.h], [AC_CHECK_LIB([gnunetutil], [GNUNET_SCHEDULER_run], libgnunetutil=1)]) @@ -215,7 +221,7 @@ AC_ARG_WITH(gnunet, AS_CASE([$with_gnunet], [yes], [], [no], [AC_MSG_ERROR([--with-gnunet is required])], - [LDFLAGS="-L$with_gnunet/lib $LDFLAGS" + [LDFLAGS="-L$with_gnunet/lib/$MULTIARCH -L$with_gnunet/lib/ $LDFLAGS" CPPFLAGS="-I$with_gnunet/include $CPPFLAGS"]) AC_CHECK_HEADERS([gnunet/gnunet_mhd_lib.h], [AC_CHECK_LIB([gnunetmhd], [GNUNET_MHD_post_parser], [libgnunetmhd=1])]) @@ -268,7 +274,7 @@ AC_ARG_WITH(gnunet, AS_CASE([$with_gnunet], [yes], [], [no], [AC_MSG_ERROR([--with-gnunet is required])], - [LDFLAGS="-L$with_gnunet/lib $LDFLAGS" + [LDFLAGS="-L$with_gnunet/lib/$MULTIARCH -L$with_gnunet/lib/ $LDFLAGS" CPPFLAGS="-I$with_gnunet/include $CPPFLAGS"]) AC_CHECK_HEADERS([gnunet/gnunet_curl_lib.h], [AC_CHECK_LIB([gnunetcurl], [GNUNET_CURL_get_select_info], libgnunetcurl=1)]) @@ -312,7 +318,7 @@ AC_ARG_WITH(gnunet, AS_CASE([$with_gnunet], [yes], [], [no], [AC_MSG_ERROR([--with-gnunet is required])], - [LDFLAGS="-L$with_gnunet/lib $LDFLAGS" + [LDFLAGS="-L$with_gnunet/lib/$MULTIARCH -L$with_gnunet/lib/ $LDFLAGS" CPPFLAGS="-I$with_gnunet/include ${CPPFLAGS}"]) CPPFLAGS="${CPPFLAGS} ${POSTGRESQL_CPPFLAGS}" AC_CHECK_HEADERS([gnunet/gnunet_pq_lib.h], @@ -353,11 +359,11 @@ AC_ARG_WITH(sqlite, AC_CHECK_HEADERS(sqlite3.h, sqlite=true)], [ - LDFLAGS="-L$with_sqlite/lib $LDFLAGS" + LDFLAGS="-L$with_sqlite/lib/$MULTIARCH -L$with_sqlite/lib/ $LDFLAGS" CPPFLAGS="-I$with_sqlite/include $CPPFLAGS" AC_CHECK_HEADERS(sqlite3.h, - EXT_LIB_PATH="-L$with_sqlite/lib $EXT_LIB_PATH" - SQLITE_LDFLAGS="-L$with_sqlite/lib" + EXT_LIB_PATH="-L$with_sqlite/lib/$MULTIARCH -L$with_sqlite/lib/ $EXT_LIB_PATH" + SQLITE_LDFLAGS="-L$with_sqlite/lib/$MULTIARCH -L$with_sqlite/lib/" SQLITE_CPPFLAGS="-I$with_sqlite/include" sqlite=true) LDFLAGS=$SAVE_LDFLAGS @@ -381,7 +387,7 @@ AC_ARG_WITH([twister], AS_CASE([$with_twister], [yes], [], [no], [AC_MSG_WARN([no twister-testing will be compiled])], - [LDFLAGS="-L$with_twister/lib $LDFLAGS" + [LDFLAGS="-L$with_twister/lib/$MULTIARCH -L$with_twister/lib/ $LDFLAGS" CPPFLAGS="-I$with_twister/include $CPPFLAGS"]) AC_CHECK_HEADERS([taler/taler_twister_service.h],