@@ -138,11 +138,11 @@ AC_ARG_ENABLE([extended-functional-tests],
138138 [ use_extended_functional_tests=$enableval] ,
139139 [ use_extended_functional_tests=no] )
140140
141- AC_ARG_WITH ( [ qrencode ] ,
142- [ AS_HELP_STRING ( [ --with-qrencode ] ,
143- [ enable QR code support (default is yes if qt is enabled and libqrencode is found)] ) ] ,
144- [ use_qr =$withval] ,
145- [ use_qr =auto] )
141+ AC_ARG_WITH ( [ qtcharts ] ,
142+ [ AS_HELP_STRING ( [ --with-qtcharts ] ,
143+ [ enable QTCHARTS code support (default is yes if qt is enabled and qtchartview is found)] ) ] ,
144+ [ use_qtcharts =$withval] ,
145+ [ use_qtcharts =auto] )
146146
147147AC_ARG_ENABLE ( [ hardening] ,
148148 [ AS_HELP_STRING ( [ --disable-hardening] ,
@@ -1024,11 +1024,12 @@ if test x$use_pkgconfig = xyes; then
10241024 PKG_CHECK_MODULES([ SSL] , [ libssl] ,, [ AC_MSG_ERROR ( openssl not found. ) ] )
10251025 PKG_CHECK_MODULES([ CRYPTO] , [ libcrypto] ,,[ AC_MSG_ERROR ( libcrypto not found. ) ] )
10261026 BITCOIN_QT_CHECK([ PKG_CHECK_MODULES([ PROTOBUF] , [ protobuf] , [ have_protobuf=yes] , [ BITCOIN_QT_FAIL(libprotobuf not found)] )] )
1027- if test x$use_qr != xno; then
1028- BITCOIN_QT_CHECK([ PKG_CHECK_MODULES([ QR] , [ libqrencode] , [ have_qrencode=yes] , [ have_qrencode=no] )] )
1027+ BITCOIN_QT_CHECK([ PKG_CHECK_MODULES([ QR] , [ libqrencode] , [ have_qrencode=yes] , [ have_qrencode=no] )] )
1028+ if test x$use_qtcharts != xno; then
1029+ BITCOIN_QT_CHECK([ PKG_CHECK_MODULES([ CHARTS] , [ Qt5Charts] ,[ have_qtcharts=yes] , [ have_qtcharts=no] )] )
10291030 fi
10301031 BITCOIN_QT_CHECK([ PKG_CHECK_MODULES([ SVG] , [ Qt5Svg] ,,[ BITCOIN_QT_FAIL(qtsvg not found)] )] )
1031- BITCOIN_QT_CHECK( [ PKG_CHECK_MODULES( [ CHARTS ] , [ Qt5Charts ] ,, [ BITCOIN_QT_FAIL(qtcharts not found) ] ) ] )
1032+
10321033 if test x$build_bitcoin_utils$build_bitcoind$bitcoin_enable_qt$use_tests != xnononono; then
10331034 PKG_CHECK_MODULES([ EVENT] , [ libevent] ,, [ AC_MSG_ERROR ( libevent not found. ) ] )
10341035 if test x$TARGET_OS != xwindows; then
@@ -1088,9 +1089,12 @@ else
10881089 BITCOIN_QT_CHECK(AC_CHECK_LIB ( [ protobuf] ,[ main] ,[ PROTOBUF_LIBS=-lprotobuf] , BITCOIN_QT_FAIL ( libprotobuf not found )) )
10891090 BITCOIN_QT_CHECK([ AC_CHECK_LIB ( [ Qt5Svg] , [ main] ,[ SVG_LIBS=-lQt5Svg] , BITCOIN_QT_FAIL ( svg not found )) ] )
10901091 BITCOIN_QT_CHECK([ AC_CHECK_LIB ( [ Qt5Charts] , [ main] ,[ CHARTS_LIBS=-lQt5Charts] , BITCOIN_QT_FAIL ( charts not found )) ] )
1091- if test x$use_qr != xno; then
1092- BITCOIN_QT_CHECK([ AC_CHECK_LIB ( [ qrencode] , [ main] ,[ QR_LIBS=-lqrencode] , [ have_qrencode=no] ) ] )
1093- BITCOIN_QT_CHECK([ AC_CHECK_HEADER ( [ qrencode.h] ,, have_qrencode=no ) ] )
1092+
1093+ BITCOIN_QT_CHECK([ AC_CHECK_LIB ( [ qrencode] , [ main] ,[ QR_LIBS=-lqrencode] , [ have_qrencode=no] ) ] )
1094+ BITCOIN_QT_CHECK([ AC_CHECK_HEADER ( [ qrencode.h] ,, have_qrencode=no ) ] )
1095+ if test x$use_qtcharts != xno; then
1096+ BITCOIN_QT_CHECK([ AC_CHECK_LIB ( [ Qt5Charts] , [ main] ,[ CHARTS_LIBS=-lQt5Charts] , [ have_qtcharts=no] ) ] )
1097+ BITCOIN_QT_CHECK([ AC_CHECK_HEADER ( [ qchartview.h] ,, have_qtcharts=no ) ] )
10941098 fi
10951099fi
10961100
@@ -1269,18 +1273,18 @@ if test x$bitcoin_enable_qt != xno; then
12691273 fi
12701274 AC_MSG_RESULT ( $bitcoin_enable_qt_dbus )
12711275
1272- dnl enable qr support
1273- AC_MSG_CHECKING ( [ whether to build GUI with support for QR codes] )
1274- if test x$have_qrencode = xno; then
1275- if test x$use_qr = xyes; then
1276- AC_MSG_ERROR ( "QR support requested but cannot be built. use -- without-qrencode " )
1276+ dnl enable qtcharts support
1277+ AC_MSG_CHECKING ( [ whether to build GUI with support for qtcharts codes] )
1278+ if test x$have_qtcharts = xno; then
1279+ if test x$use_qtcharts = xyes; then
1280+ AC_MSG_ERROR ( "QTCharts support requested but cannot be built. use -- without-qtcharts " )
12771281 fi
12781282 AC_MSG_RESULT ( no )
12791283 else
1280- if test x$use_qr != xno; then
1284+ if test x$use_qtcharts != xno; then
12811285 AC_MSG_RESULT ( yes )
1282- AC_DEFINE ( [ USE_QRCODE ] ,[ 1] ,[ Define if QR support should be compiled in] )
1283- use_qr =yes
1286+ AC_DEFINE ( [ USE_QTCHARTS ] ,[ 1] ,[ Define if QTCHARTS support should be compiled in] )
1287+ use_qtcharts =yes
12841288 else
12851289 AC_MSG_RESULT ( no )
12861290 fi
@@ -1345,7 +1349,7 @@ AM_CONDITIONAL([ENABLE_TESTS],[test x$BUILD_TEST = xyes])
13451349AM_CONDITIONAL([ ENABLE_QT] ,[ test x$bitcoin_enable_qt = xyes] )
13461350AM_CONDITIONAL([ ENABLE_QT_TESTS] ,[ test x$BUILD_TEST_QT = xyes] )
13471351AM_CONDITIONAL([ ENABLE_BENCH] ,[ test x$use_bench = xyes] )
1348- AM_CONDITIONAL([ USE_QRCODE ] , [ test x$use_qr = xyes] )
1352+ AM_CONDITIONAL([ USE_QTCHARTS ] , [ test x$use_qtcharts = xyes] )
13491353AM_CONDITIONAL([ USE_LCOV] ,[ test x$use_lcov = xyes] )
13501354AM_CONDITIONAL([ GLIBC_BACK_COMPAT] ,[ test x$use_glibc_compat = xyes] )
13511355AM_CONDITIONAL([ HARDEN] ,[ test x$use_hardening = xyes] )
@@ -1394,7 +1398,7 @@ AC_SUBST(AVX2_CXXFLAGS)
13941398AC_SUBST ( SHANI_CXXFLAGS )
13951399AC_SUBST ( LIBTOOL_APP_LDFLAGS )
13961400AC_SUBST ( USE_UPNP )
1397- AC_SUBST ( USE_QRCODE )
1401+ AC_SUBST ( USE_QTCHARTS )
13981402AC_SUBST ( BOOST_LIBS )
13991403AC_SUBST ( TESTDEFS )
14001404AC_SUBST ( LEVELDB_TARGET_FLAGS )
@@ -1473,7 +1477,7 @@ echo "Options used to compile and link:"
14731477echo " with wallet = $enable_wallet"
14741478echo " with gui / qt = $bitcoin_enable_qt"
14751479if test x$bitcoin_enable_qt != xno; then
1476- echo " with qr = $use_qr "
1480+ echo " with QTCHARTS = $use_qtcharts "
14771481fi
14781482echo " with zmq = $use_zmq"
14791483echo " with bignum = $set_bignum"
0 commit comments