From 2198708d8ec1746360ed7f768b0187b2d98d72b1 Mon Sep 17 00:00:00 2001 From: Phillip Mienk Date: Wed, 26 Oct 2016 16:54:28 -0700 Subject: [PATCH 1/3] Regenerate build artifacts. --- configure.ac | 6 +++--- install.sh | 37 ++++++++++++++++++++++++++++++++----- 2 files changed, 35 insertions(+), 8 deletions(-) diff --git a/configure.ac b/configure.ac index b342ca73..f2914e9d 100644 --- a/configure.ac +++ b/configure.ac @@ -129,15 +129,15 @@ AS_CASE([${enable_shared}], [yes], AC_DEFINE([BOOST_ALL_DYN_LINK])) # Check dependencies. #============================================================================== -# Require Boost of at least version 1.56.0 and output ${boost_CPPFLAGS/LDFLAGS}. +# Require Boost of at least version 1.57.0 and output ${boost_CPPFLAGS/LDFLAGS}. #------------------------------------------------------------------------------ AS_CASE([${CC}], [*], - [AX_BOOST_BASE([1.56.0], + [AX_BOOST_BASE([1.57.0], [AC_SUBST([boost_CPPFLAGS], [${BOOST_CPPFLAGS}]) AC_SUBST([boost_LDFLAGS], [${BOOST_LDFLAGS}]) AC_MSG_NOTICE([boost_CPPFLAGS : ${boost_CPPFLAGS}]) AC_MSG_NOTICE([boost_LDFLAGS : ${boost_LDFLAGS}])], - [AC_MSG_ERROR([Boost 1.56.0 or later is required but was not found.])])]) + [AC_MSG_ERROR([Boost 1.57.0 or later is required but was not found.])])]) AS_CASE([${with_tests}], [yes], [AX_BOOST_UNIT_TEST_FRAMEWORK diff --git a/install.sh b/install.sh index 9acccb20..edb05e61 100755 --- a/install.sh +++ b/install.sh @@ -30,10 +30,14 @@ #------------------------------------------------------------------------------ BUILD_DIR="build-libbitcoin-server" +# The default object directory. +#------------------------------------------------------------------------------ +OBJECT_DIR="bin-objects" + # Boost archive. #------------------------------------------------------------------------------ -BOOST_URL="http://downloads.sourceforge.net/project/boost/boost/1.56.0/boost_1_56_0.tar.bz2" -BOOST_ARCHIVE="boost_1_56_0.tar.bz2" +BOOST_URL="http://downloads.sourceforge.net/project/boost/boost/1.57.0/boost_1_57_0.tar.bz2" +BOOST_ARCHIVE="boost_1_57_0.tar.bz2" # Initialize the build environment. @@ -277,6 +281,18 @@ configure_options() ./configure "$@" } +configure_options_object_dir() +{ + echo "configure options:" + for OPTION in "$@"; do + if [[ $OPTION ]]; then + echo $OPTION + fi + done + + ../configure "$@" +} + configure_links() { # Configure dynamic linker run-time bindings when installing to system. @@ -315,11 +331,14 @@ make_current_directory() local JOBS=$1 shift 1 + create_directory "$OBJECT_DIR" ./autogen.sh - configure_options "$@" + push_directory "$OBJECT_DIR" + configure_options_object_dir "$@" make_jobs $JOBS make install configure_links + pop_directory } # make_jobs jobs [make_options] @@ -453,6 +472,7 @@ build_from_tarball() # Use the suffixed archive name as the extraction directory. local EXTRACT="build-$ARCHIVE" + push_directory "$BUILD_DIR" create_directory $EXTRACT push_directory $EXTRACT @@ -485,6 +505,8 @@ build_from_tarball() # Restore flags to prevent side effects. export LDFLAGS=$SAVE_LDFLAGS export CPPFLAGS=$SAVE_LCPPFLAGS + + pop_directory } # Because boost ICU detection assumes in incorrect ICU path. @@ -570,6 +592,7 @@ build_from_tarball_boost() # Use the suffixed archive name as the extraction directory. local EXTRACT="build-$ARCHIVE" + push_directory "$BUILD_DIR" create_directory $EXTRACT push_directory $EXTRACT @@ -635,11 +658,14 @@ build_from_tarball_boost() "$@" pop_directory + pop_directory } # Standard build from github. build_from_github() { + push_directory "$BUILD_DIR" + local ACCOUNT=$1 local REPO=$2 local BRANCH=$3 @@ -660,6 +686,7 @@ build_from_github() push_directory $REPO make_current_directory $JOBS "${CONFIGURATION[@]}" pop_directory + pop_directory } # Standard build of current directory. @@ -691,8 +718,8 @@ build_from_travis() # The primary build is not downloaded if we are running in Travis. if [[ $TRAVIS == true ]]; then - push_directory ".." build_from_local "Local $TRAVIS_REPO_SLUG" $JOBS "${OPTIONS[@]}" "$@" + push_directory "$OBJECT_DIR" make_tests $JOBS pop_directory else @@ -727,5 +754,5 @@ build_all() create_directory "$BUILD_DIR" push_directory "$BUILD_DIR" initialize_git -time build_all "${CONFIGURE_OPTIONS[@]}" pop_directory +time build_all "${CONFIGURE_OPTIONS[@]}" From b8b34bab24d98748a20273509466f5886708e83d Mon Sep 17 00:00:00 2001 From: Phillip Mienk Date: Wed, 26 Oct 2016 17:26:40 -0700 Subject: [PATCH 2/3] Restore maximum_archive_files configuration property. --- console/executor.cpp | 8 ++++---- src/parser.cpp | 5 +++++ 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/console/executor.cpp b/console/executor.cpp index a4b95702..7eb92271 100644 --- a/console/executor.cpp +++ b/console/executor.cpp @@ -63,8 +63,8 @@ executor::executor(parser& metadata, std::istream& input, network.archive_directory, network.rotation_size, network.maximum_archive_size, - network.minimum_free_space - ////network.maximum_archive_files + network.minimum_free_space, + network.maximum_archive_files }; const log::rotable_file error_file @@ -73,8 +73,8 @@ executor::executor(parser& metadata, std::istream& input, network.archive_directory, network.rotation_size, network.maximum_archive_size, - network.minimum_free_space - ////network.maximum_archive_files + network.minimum_free_space, + network.maximum_archive_files }; log::stream console_out(&output_, null_deleter()); diff --git a/src/parser.cpp b/src/parser.cpp index 0a7feb36..4845e69e 100644 --- a/src/parser.cpp +++ b/src/parser.cpp @@ -159,6 +159,11 @@ options_metadata parser::load_settings() value(&configured.network.minimum_free_space), "The minimum free space required in the archive directory, defaults to 0." ) + ( + "log.maximum_archive_files", + value(&configured.network.maximum_archive_files), + "The maximum number of logs to persist, defaults to 'maximum'." + ) /* [network] */ ( "network.threads", From 607acbe64e5ef39be34754653d38f467bc0d9d69 Mon Sep 17 00:00:00 2001 From: Phillip Mienk Date: Thu, 27 Oct 2016 03:20:40 -0700 Subject: [PATCH 3/3] Regenerate build artifacts. --- install.sh | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) diff --git a/install.sh b/install.sh index edb05e61..c351769d 100755 --- a/install.sh +++ b/install.sh @@ -30,10 +30,6 @@ #------------------------------------------------------------------------------ BUILD_DIR="build-libbitcoin-server" -# The default object directory. -#------------------------------------------------------------------------------ -OBJECT_DIR="bin-objects" - # Boost archive. #------------------------------------------------------------------------------ BOOST_URL="http://downloads.sourceforge.net/project/boost/boost/1.57.0/boost_1_57_0.tar.bz2" @@ -281,18 +277,6 @@ configure_options() ./configure "$@" } -configure_options_object_dir() -{ - echo "configure options:" - for OPTION in "$@"; do - if [[ $OPTION ]]; then - echo $OPTION - fi - done - - ../configure "$@" -} - configure_links() { # Configure dynamic linker run-time bindings when installing to system. @@ -331,14 +315,11 @@ make_current_directory() local JOBS=$1 shift 1 - create_directory "$OBJECT_DIR" ./autogen.sh - push_directory "$OBJECT_DIR" - configure_options_object_dir "$@" + configure_options "$@" make_jobs $JOBS make install configure_links - pop_directory } # make_jobs jobs [make_options] @@ -719,9 +700,7 @@ build_from_travis() # The primary build is not downloaded if we are running in Travis. if [[ $TRAVIS == true ]]; then build_from_local "Local $TRAVIS_REPO_SLUG" $JOBS "${OPTIONS[@]}" "$@" - push_directory "$OBJECT_DIR" make_tests $JOBS - pop_directory else build_from_github $ACCOUNT $REPO $BRANCH $JOBS "${OPTIONS[@]}" "$@" push_directory $REPO