Skip to content

Commit 01c88b0

Browse files
committed
4.0.3.0-leisure
Added: - Replace NeuralNetwork with portable C++ scraper #1387 (@jamescowens, @tomasbrod, @Cycy, @TheCharlatan, @denravonska). - Allow compile flags to be used for depends #1423 (@G-UK). - Add stake splitting and side staking info to getmininginfo #1424 (@jamescowens). - Add freedesktop.org desktop file and icon set #1438 (@a123b). Changed: - Disable Qt for windows Travis builds #1276 (@TheCharlatan). - Replace use of AppCache PROJECT section with strongly-typed structures #1415 (@cyrossignol). - Change dumpwallet to use appropriate data directory #1416 (@jamescowens). - Optimize ExtractXML() calls by avoiding unnecessary string copies #1419 (@cyrossignol). - Change signature of IsLockTimeWithinMinutes #1422 (@jamescowens). - Restore old poll output for getmininginfo RPC #1437 (@a123b). - Prevent segfault when using rpc savescraperfilemanifest #1439 (@jamescowens). - Improve miner status messages for ineligible staking balances #1447 (@cyrossignol). - Enhance scraper log archiving #1449 (@jamescowens). Fixed: - Re-enable full GUI 32-bit Windows builds - part of #1387 (@jamescowens). - Re-activate Windows Installer #1409 (@TheCharlatan). - Fix Depends and Travis build issues for ARM #1417 (@jamescowens). - Fix syncupdate icons #1421 (@jamescowens). - Fix potential BOINC crash when reading projects #1426 (@cyrossignol). - Fix freeze when unlocking wallet #1428 (@denravonska). - Fix RPC after high priority alert #1432 (@denravonska). - Fix missing poll in GUI when most recent poll expired #1455 (@cyrossignol). Removed: - Remove old, rudimentary side staking implementation #1381 (@denravonska). - Remove auto unlock #1402 (@denravonska). - Remove superblock forwarding #1430 (@denravonska).
2 parents 004c6b8 + 587516f commit 01c88b0

File tree

324 files changed

+11572
-21659
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

324 files changed

+11572
-21659
lines changed

.travis.yml

100755100644
+13-7
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
sudo: required
2-
dist: trusty
2+
dist: bionic
33
os: linux
44
language: minimal
55
cache:
@@ -21,31 +21,37 @@ env:
2121
- PYTHON_DEBUG=1
2222
- WINEDEBUG=fixme-all
2323
matrix:
24-
# ARM
25-
- HOST=arm-linux-gnueabihf PACKAGES="g++-arm-linux-gnueabihf" DEP_OPTS="NO_QT=1" CHECK_DOC=1 GOAL="install" GRIDCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports RUN_TESTS=false"
24+
# ARM - disabled for now, because Xenial has fPIC error with depends that can't be solved. Need to upgrade to Bionic, which is not available.
25+
#- HOST=arm-linux-gnueabihf PACKAGES="g++-arm-linux-gnueabihf zlib1g-dev" GCCFLAGS="-fPIC" DEP_OPTS="NO_QT=1" CHECK_DOC=1 GOAL="install" GRIDCOIN_CONFIG="--enable-glibc-back-compat --disable-tests RUN_TESTS=false"
2626
# Win32
2727
- HOST=i686-w64-mingw32 DPKG_ADD_ARCH="i386" DEP_OPTS="NO_QT=1" PACKAGES="python3 nsis g++-mingw-w64-i686 wine1.6" RUN_TESTS=false GOAL="" GRIDCOIN_CONFIG="--enable-reduce-exports"
2828
# Qt5 & system libs
29-
- HOST=x86_64-unknown-linux-gnu PACKAGES="libqt5gui5 libqt5core5a qtbase5-dev libqt5dbus5 qttools5-dev qttools5-dev-tools libssl-dev libevent-dev bsdmainutils libboost-system-dev libboost-filesystem-dev libboost-chrono-dev libboost-program-options-dev libboost-test-dev libboost-thread-dev libdb5.1++-dev libminiupnpc-dev protobuf-compiler libqrencode-dev xvfb" NO_DEPENDS=1 NEED_XVFB=1 RUN_TESTS=true GOAL="install" GRIDCOIN_CONFIG=" --with-incompatible-bdb --enable-reduce-exports --with-gui=qt5"
29+
- HOST=x86_64-unknown-linux-gnu PACKAGES="libqt5gui5 libqt5core5a qtbase5-dev libqt5dbus5 qttools5-dev qttools5-dev-tools libssl-dev libevent-dev bsdmainutils libboost-system-dev libboost-filesystem-dev libboost-chrono-dev libboost-iostreams-dev libboost-program-options-dev libboost-test-dev libboost-thread-dev libdb5.3++-dev libminiupnpc-dev protobuf-compiler libqrencode-dev xvfb zlib1g-dev" NO_DEPENDS=1 NEED_XVFB=1 RUN_TESTS=true GOAL="install" GRIDCOIN_CONFIG=" --with-incompatible-bdb --enable-reduce-exports --with-gui=qt5"
3030
# 32-bit + dash
3131
- HOST=i686-pc-linux-gnu PACKAGES="g++-multilib" DEP_OPTS="NO_QT=1" RUN_TESTS=false GOAL="install" GRIDCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports LDFLAGS=-static-libstdc++" USE_SHELL="/bin/dash"
3232
# Win64
33-
- HOST=x86_64-w64-mingw32 DPKG_ADD_ARCH="i386" PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine1.6 xvfb" RUN_TESTS=false GOAL="" GRIDCOIN_CONFIG="--enable-reduce-exports" NEED_XVFB=1
33+
- HOST=x86_64-w64-mingw32 DPKG_ADD_ARCH="i386" PACKAGES="gcc-7 python3 nsis g++-mingw-w64-x86-64 wine1.6 xvfb" DEP_OPTS="NO_QT=1" RUN_TESTS=false GOAL="" GRIDCOIN_CONFIG="--enable-reduce-exports" NEED_XVFB=1
3434
# Cross-Mac - disabled for now, since we cannot compile QtSVG with the SDK
3535
#- HOST=x86_64-apple-darwin11 PACKAGES="cmake imagemagick libcap-dev librsvg2-bin libz-dev libbz2-dev libtiff-tools python-dev" GRIDCOIN_CONFIG="--enable-gui --enable-reduce-exports" OSX_SDK=10.11 RUN_TESTS=false GOAL="deploy"
3636

3737
before_install:
3838
- export PATH=$(echo $PATH | tr ':' "\n" | sed '/\/opt\/python/d' | tr "\n" ":" | sed "s|::|:|g")
39+
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
40+
- sudo apt-get update -q
41+
- sudo apt-get install gcc-7 -y
42+
- sudo apt-get install gcc-5-arm-linux-gnueabihf -y
3943
install:
4044
- if [ -n "$DPKG_ADD_ARCH" ]; then sudo dpkg --add-architecture "$DPKG_ADD_ARCH" ; fi
4145
- if [ -n "$PACKAGES" ]; then travis_retry sudo apt-get update; fi
4246
- if [ -n "$PACKAGES" ]; then travis_retry sudo apt-get install --no-install-recommends --no-upgrade -qq $PACKAGES; fi
4347
before_script:
48+
- if [ "$HOST" == "i686-w64-mingw32" ]; then sudo update-alternatives --set i686-w64-mingw32-g++ /usr/bin/i686-w64-mingw32-g++-posix; fi
49+
- if [ "$HOST" == "x86_64-w64-mingw32" ]; then sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix; fi
4450
- unset CC; unset CXX
4551
- mkdir -p depends/SDKs depends/sdk-sources
4652
- if [ -n "$OSX_SDK" -a ! -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then curl --location --fail $SDK_URL/MacOSX${OSX_SDK}.sdk.tar.gz -o depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz; fi
4753
- if [ -n "$OSX_SDK" -a -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz; fi
48-
- if [ -z "$NO_DEPENDS" ]; then make $MAKEJOBS -C depends HOST=$HOST $DEP_OPTS; fi
54+
- if [ -z "$NO_DEPENDS" ]; then make $MAKEJOBS -C depends HOST=$HOST GCCFLAGS=$GCCFLAGS $DEP_OPTS; fi
4955
# Start xvfb if needed, as documented at https://docs.travis-ci.com/user/gui-and-headless-browsers/#Using-xvfb-to-Run-Tests-That-Require-a-GUI
5056
- if [ "$NEED_XVFB" = 1 ]; then export DISPLAY=:99.0; /sbin/start-stop-daemon --start --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -ac; fi
5157
script:
@@ -59,7 +65,7 @@ script:
5965
- make distdir VERSION=$HOST
6066
- cd gridcoin-$HOST
6167
- ./configure --cache-file=../config.cache $GRIDCOIN_CONFIG_ALL $GRIDCOIN_CONFIG || ( cat config.log && false)
62-
- make $MAKEJOBS $GOAL || ( echo "Build failure. Verbose build follows." && make $GOAL V=1 ; false )
68+
- make GCCFLAGS=$GCCFLAGS $MAKEJOBS $GOAL || ( echo "Build failure. Verbose build follows." && make GCCFLAGS=$GCCFLAGS $GOAL V=1 ; false )
6369
- export LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/depends/$HOST/lib
6470
- if [ "$HOST" = "x86_64-unknown-linux-gnu" ]; then travis_wait 30 make $MAKEJOBS check VERBOSE=1; fi
6571
- if [ "$TRAVIS_EVENT_TYPE" = "cron" ]; then extended="--extended --exclude pruning,dbcrash"; fi

CHANGELOG.md

+38-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,44 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](http://keepachangelog.com/)
55
and this project adheres to [Semantic Versioning](http://semver.org/).
66

7+
## [4.0.3.0] 2019-05-10, leisure
8+
### Added
9+
- Replace NeuralNetwork with portable C++ scraper #1387 (@jamescowens,
10+
@tomasbrod, @cycy, @TheCharlatan, @denravonska).
11+
- Allow compile flags to be used for depends #1423 (@G-UK).
12+
- Add stake splitting and side staking info to getmininginfo #1424
13+
(@jamescowens).
14+
- Add freedesktop.org desktop file and icon set #1438 (@a123b).
15+
16+
### Changed
17+
- Disable Qt for windows Travis builds #1276 (@TheCharlatan).
18+
- Replace use of AppCache PROJECT section with strongly-typed structures #1415
19+
(@cyrossignol).
20+
- Change dumpwallet to use appropriate data directory #1416 (@jamescowens).
21+
- Optimize ExtractXML() calls by avoiding unnecessary string copies #1419
22+
(@cyrossignol).
23+
- Change signature of IsLockTimeWithinMinutes #1422 (@jamescowens).
24+
- Restore old poll output for getmininginfo RPC #1437 (@a123b).
25+
- Prevent segfault when using rpc savescraperfilemanifest #1439 (@jamescowens).
26+
- Improve miner status messages for ineligible staking balances #1447
27+
(@cyrossignol).
28+
- Enhance scraper log archiving #1449 (@jamescowens).
29+
30+
### Fixed
31+
- Re-enable full GUI 32-bit Windows builds - part of #1387 (@jamescowens).
32+
- Re-activate Windows Installer #1409 (@TheCharlatan).
33+
- Fix Depends and Travis build issues for ARM #1417 (@jamescowens).
34+
- Fix syncupdate icons #1421 (@jamescowens).
35+
- Fix potential BOINC crash when reading projects #1426 (@cyrossignol).
36+
- Fix freeze when unlocking wallet #1428 (@denravonska).
37+
- Fix RPC after high priority alert #1432 (@denravonska).
38+
- Fix missing poll in GUI when most recent poll expired #1455 (@cyrossignol).
39+
40+
### Removed
41+
- Remove old, rudimentary side staking implementation #1381 (@denravonska).
42+
- Remove auto unlock #1402 (@denravonska).
43+
- Remove superblock forwarding #1430 (@denravonska).
44+
745
## [4.0.2.0] 2019-04-03, leisure
846
### Added
947
- Add `rainbymagnitude` RPC command #1235 (@Foggyx420).
@@ -53,7 +91,6 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
5391
#1336 (@denravonska).
5492
- Remove unused attachment functionality #1345 (@denravonska).
5593

56-
5794
## [4.0.1.0] 2018-11-30, leisure
5895
### Fixed
5996
- Wrong RA scan range causing reward calculation disagreements and forks

Makefile.am

+14-4
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export PYTHONPATH
1111

1212
BITCOIND_BIN=$(top_builddir)/src/$(GRIDCOIN_DAEMON_NAME)$(EXEEXT)
1313
BITCOIN_QT_BIN=$(top_builddir)/src/qt/$(GRIDCOIN_GUI_NAME)$(EXEEXT)
14-
#BITCOIN_WIN_INSTALLER=$(PACKAGE)-$(PACKAGE_VERSION)-win$(WINDOWS_BITS)-setup$(EXEEXT)
14+
BITCOIN_WIN_INSTALLER=$(PACKAGE)-$(PACKAGE_VERSION)-win$(WINDOWS_BITS)-setup$(EXEEXT)
1515

1616
empty :=
1717
space := $(empty) $(empty)
@@ -29,11 +29,13 @@ OSX_INSTALLER_ICONS=$(top_srcdir)/src/qt/res/icons/gridcoin.icns
2929
OSX_PLIST=$(top_builddir)/share/qt/Info.plist #not installed
3030
OSX_QT_TRANSLATIONS = da,de,es,hu,ru,uk,zh_CN,zh_TW
3131

32-
DIST_DOCS = $(wildcard doc/*.md) $(wildcard doc/release-notes/*.md)
32+
DIST_DOCS = $(wildcard $(top_srcdir)/doc/*.md) $(wildcard $(top_srcdir)/doc/release-notes/*.md)
33+
DIST_DESKTOPFILE = $(top_srcdir)/contrib/gridcoinresearch.desktop
34+
DIST_ICONS = $(subst $(top_srcdir)/,,$(wildcard $(top_srcdir)/share/icons/*/*/*/*))
3335

3436
BIN_CHECKS=$(top_srcdir)/contrib/devtools/symbol-check.py
3537

36-
WINDOWS_PACKAGING = $(top_srcdir)/share/pixmaps/bitcoin.ico \
38+
WINDOWS_PACKAGING = $(top_srcdir)/share/pixmaps/gridcoin.ico \
3739
$(top_srcdir)/share/pixmaps/nsis-header.bmp \
3840
$(top_srcdir)/share/pixmaps/nsis-wizard.bmp
3941

@@ -48,6 +50,14 @@ COVERAGE_INFO = baseline.info \
4850
baseline_filtered.info functional_test.info functional_test_filtered.info \
4951
test_bitcoin_coverage.info test_bitcoin.info
5052

53+
if ENABLE_QT
54+
desktopfiledir = $(datadir)/applications
55+
desktopfile_DATA = $(DIST_DESKTOPFILE)
56+
57+
iconsdir = $(prefix)
58+
nobase_icons_DATA = $(DIST_ICONS)
59+
endif
60+
5161
dist-hook:
5262
-$(GIT) archive --format=tar HEAD -- src/version.cpp | $(AMTAR) -C $(top_distdir) -xf -
5363

@@ -188,7 +198,7 @@ endif
188198

189199
dist_noinst_SCRIPTS = autogen.sh
190200

191-
EXTRA_DIST = $(top_srcdir)/share/genbuild.sh $(DIST_CONTRIB) $(DIST_DOCS) $(WINDOWS_PACKAGING) $(OSX_PACKAGING) $(BIN_CHECKS)
201+
EXTRA_DIST = $(top_srcdir)/share/genbuild.sh $(DIST_CONTRIB) $(DIST_DOCS) $(DIST_DESKTOPFILE) $(DIST_ICONS) $(WINDOWS_PACKAGING) $(OSX_PACKAGING) $(BIN_CHECKS)
192202

193203
CLEANFILES = $(OSX_DMG) $(BITCOIN_WIN_INSTALLER)
194204

build-aux/m4/ax_boost_iostreams.m4

+116
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
# ===========================================================================
2+
# https://www.gnu.org/software/autoconf-archive/ax_boost_iostreams.html
3+
# ===========================================================================
4+
#
5+
# SYNOPSIS
6+
#
7+
# AX_BOOST_IOSTREAMS
8+
#
9+
# DESCRIPTION
10+
#
11+
# Test for IOStreams library from the Boost C++ libraries. The macro
12+
# requires a preceding call to AX_BOOST_BASE. Further documentation is
13+
# available at <http://randspringer.de/boost/index.html>.
14+
#
15+
# This macro calls:
16+
#
17+
# AC_SUBST(BOOST_IOSTREAMS_LIB)
18+
#
19+
# And sets:
20+
#
21+
# HAVE_BOOST_IOSTREAMS
22+
#
23+
# LICENSE
24+
#
25+
# Copyright (c) 2008 Thomas Porschberg <[email protected]>
26+
#
27+
# Copying and distribution of this file, with or without modification, are
28+
# permitted in any medium without royalty provided the copyright notice
29+
# and this notice are preserved. This file is offered as-is, without any
30+
# warranty.
31+
32+
#serial 21
33+
34+
AC_DEFUN([AX_BOOST_IOSTREAMS],
35+
[
36+
AC_ARG_WITH([boost-iostreams],
37+
AS_HELP_STRING([--with-boost-iostreams@<:@=special-lib@:>@],
38+
[use the IOStreams library from boost - it is possible to specify a certain library for the linker
39+
e.g. --with-boost-iostreams=boost_iostreams-gcc-mt-d-1_33_1 ]),
40+
[
41+
if test "$withval" = "no"; then
42+
want_boost="no"
43+
elif test "$withval" = "yes"; then
44+
want_boost="yes"
45+
ax_boost_user_iostreams_lib=""
46+
else
47+
want_boost="yes"
48+
ax_boost_user_iostreams_lib="$withval"
49+
fi
50+
],
51+
[want_boost="yes"]
52+
)
53+
54+
if test "x$want_boost" = "xyes"; then
55+
AC_REQUIRE([AC_PROG_CC])
56+
CPPFLAGS_SAVED="$CPPFLAGS"
57+
CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS"
58+
export CPPFLAGS
59+
60+
LDFLAGS_SAVED="$LDFLAGS"
61+
LDFLAGS="$LDFLAGS $BOOST_LDFLAGS"
62+
export LDFLAGS
63+
64+
AC_CACHE_CHECK(whether the Boost::IOStreams library is available,
65+
ax_cv_boost_iostreams,
66+
[AC_LANG_PUSH([C++])
67+
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[@%:@include <boost/iostreams/filtering_stream.hpp>
68+
@%:@include <boost/range/iterator_range.hpp>
69+
]],
70+
[[std::string input = "Hello World!";
71+
namespace io = boost::iostreams;
72+
io::filtering_istream in(boost::make_iterator_range(input));
73+
return 0;
74+
]])],
75+
ax_cv_boost_iostreams=yes, ax_cv_boost_iostreams=no)
76+
AC_LANG_POP([C++])
77+
])
78+
if test "x$ax_cv_boost_iostreams" = "xyes"; then
79+
AC_DEFINE(HAVE_BOOST_IOSTREAMS,,[define if the Boost::IOStreams library is available])
80+
BOOSTLIBDIR=`echo $BOOST_LDFLAGS | sed -e 's/@<:@^\/@:>@*//'`
81+
if test "x$ax_boost_user_iostreams_lib" = "x"; then
82+
for libextension in `ls $BOOSTLIBDIR/libboost_iostreams*.so* $BOOSTLIBDIR/libboost_iostream*.dylib* $BOOSTLIBDIR/libboost_iostreams*.a* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^lib\(boost_iostreams.*\)\.so.*$;\1;' -e 's;^lib\(boost_iostream.*\)\.dylib.*$;\1;' -e 's;^lib\(boost_iostreams.*\)\.a.*$;\1;'` ; do
83+
ax_lib=${libextension}
84+
AC_CHECK_LIB($ax_lib, exit,
85+
[BOOST_IOSTREAMS_LIB="-l$ax_lib"; AC_SUBST(BOOST_IOSTREAMS_LIB) link_iostreams="yes"; break],
86+
[link_iostreams="no"])
87+
done
88+
if test "x$link_iostreams" != "xyes"; then
89+
for libextension in `ls $BOOSTLIBDIR/boost_iostreams*.dll* $BOOSTLIBDIR/boost_iostreams*.a* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^\(boost_iostreams.*\)\.dll.*$;\1;' -e 's;^\(boost_iostreams.*\)\.a.*$;\1;'` ; do
90+
ax_lib=${libextension}
91+
AC_CHECK_LIB($ax_lib, exit,
92+
[BOOST_IOSTREAMS_LIB="-l$ax_lib"; AC_SUBST(BOOST_IOSTREAMS_LIB) link_iostreams="yes"; break],
93+
[link_iostreams="no"])
94+
done
95+
fi
96+
97+
else
98+
for ax_lib in $ax_boost_user_iostreams_lib boost_iostreams-$ax_boost_user_iostreams_lib; do
99+
AC_CHECK_LIB($ax_lib, main,
100+
[BOOST_IOSTREAMS_LIB="-l$ax_lib"; AC_SUBST(BOOST_IOSTREAMS_LIB) link_iostreams="yes"; break],
101+
[link_iostreams="no"])
102+
done
103+
104+
fi
105+
if test "x$ax_lib" = "x"; then
106+
AC_MSG_ERROR(Could not find a version of the library!)
107+
fi
108+
if test "x$link_iostreams" != "xyes"; then
109+
AC_MSG_ERROR(Could not link against $ax_lib !)
110+
fi
111+
fi
112+
113+
CPPFLAGS="$CPPFLAGS_SAVED"
114+
LDFLAGS="$LDFLAGS_SAVED"
115+
fi
116+
])

build-aux/m4/ax_boost_zlib.m4

+90
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
# SYNOPSIS
2+
#
3+
# AX_BOOST_ZLIB
4+
#
5+
# DESCRIPTION
6+
#
7+
# Test for ZLib library from the Boost C++ libraries. The macro
8+
# requires a preceding call to AX_BOOST_BASE. Further documentation is
9+
# available at <http://randspringer.de/boost/index.html>.
10+
#
11+
# This macro calls:
12+
#
13+
# AC_SUBST(BOOST_ZLIB_LIB)
14+
#
15+
# And sets:
16+
#
17+
# HAVE_BOOST_ZLIB
18+
#
19+
# LICENSE
20+
#
21+
# Copyright (c) 2008 Thomas Porschberg <[email protected]>
22+
#
23+
# Copying and distribution of this file, with or without modification, are
24+
# permitted in any medium without royalty provided the copyright notice
25+
# and this notice are preserved. This file is offered as-is, without any
26+
# warranty.
27+
28+
#serial 21
29+
30+
AC_DEFUN([AX_BOOST_ZLIB],
31+
[
32+
AC_ARG_WITH([boost-zlib],
33+
AS_HELP_STRING([--with-boost-zlib@<:@=special-lib@:>@],
34+
[use the ZLib library from boost - it is possible to specify a certain library for the linker
35+
e.g. --with-boost-zlib=boost_zlib-gcc-mt-d-1_33_1 ]),
36+
[
37+
if test "$withval" = "no"; then
38+
want_boost="no"
39+
elif test "$withval" = "yes"; then
40+
want_boost="yes"
41+
ax_boost_user_zlib_lib=""
42+
else
43+
want_boost="yes"
44+
ax_boost_user_zlib_lib="$withval"
45+
fi
46+
],
47+
[want_boost="yes"]
48+
)
49+
50+
if test "x$want_boost" = "xyes"; then
51+
AC_REQUIRE([AC_PROG_CC])
52+
CPPFLAGS_SAVED="$CPPFLAGS"
53+
CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS"
54+
export CPPFLAGS
55+
56+
LDFLAGS_SAVED="$LDFLAGS"
57+
LDFLAGS="$LDFLAGS $BOOST_LDFLAGS"
58+
export LDFLAGS
59+
60+
AC_DEFINE(HAVE_BOOST_ZLIB,,[define if the Boost::zlib library is available])
61+
BOOSTLIBDIR=`echo $BOOST_LDFLAGS | sed -e 's/@<:@^\/@:>@*//'`
62+
if test "x$ax_boost_user_zlib_lib" = "x"; then
63+
for libextension in `ls $BOOSTLIBDIR/libboost_zlib*.so* $BOOSTLIBDIR/libboost_iostream*.dylib* $BOOSTLIBDIR/libboost_zlib*.a* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^lib\(boost_zlib.*\)\.so.*$;\1;' -e 's;^lib\(boost_iostream.*\)\.dylib.*$;\1;' -e 's;^lib\(boost_zlib.*\)\.a.*$;\1;'` ; do
64+
ax_lib=${libextension}
65+
AC_CHECK_LIB($ax_lib, exit,
66+
[BOOST_ZLIB_LIB="-l$ax_lib"; AC_SUBST(BOOST_ZLIB_LIB) link_zlib="yes"; break],
67+
[link_zlib="no"])
68+
done
69+
if test "x$link_zlib" != "xyes"; then
70+
for libextension in `ls $BOOSTLIBDIR/boost_zlib*.dll* $BOOSTLIBDIR/boost_zlib*.a* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^\(boost_zlib.*\)\.dll.*$;\1;' -e 's;^\(boost_zlib.*\)\.a.*$;\1;'` ; do
71+
ax_lib=${libextension}
72+
AC_CHECK_LIB($ax_lib, exit,
73+
[BOOST_ZLIB_LIB="-l$ax_lib"; AC_SUBST(BOOST_ZLIB_LIB) link_zlib="yes"; break],
74+
[link_zlib="no"])
75+
done
76+
fi
77+
78+
else
79+
for ax_lib in $ax_boost_user_zlib_lib boost_zlib-$ax_boost_user_zlib_lib; do
80+
AC_CHECK_LIB($ax_lib, main,
81+
[BOOST_ZLIB_LIB="-l$ax_lib"; AC_SUBST(BOOST_ZLIB_LIB) link_zlib="yes"; break],
82+
[link_zlib="no"])
83+
done
84+
85+
fi
86+
87+
CPPFLAGS="$CPPFLAGS_SAVED"
88+
LDFLAGS="$LDFLAGS_SAVED"
89+
fi
90+
])

0 commit comments

Comments
 (0)