Merge branch 'master' of github.com:jthornber/thin-provisioning-tools

This commit is contained in:
Joe Thornber 2016-02-10 14:25:50 +00:00
commit 6101398b02
7 changed files with 29 additions and 19 deletions

View File

@ -1,3 +1,8 @@
v0.6.1
======
./configure --enable-static-cxx
v0.6.0
======

View File

@ -111,7 +111,14 @@ CXXFLAGS+=@CXXDEBUG_FLAG@
CXXFLAGS+=@CXX_STRERROR_FLAG@
CXXFLAGS+=@LFS_FLAGS@
INCLUDES+=-I$(TOP_BUILDDIR) -I$(TOP_DIR) -I$(TOP_DIR)/thin-provisioning
LIBS:=-lstdc++ -laio -lexpat
LIBS:=-laio -lexpat
ifeq ("@STATIC_CXX@", "yes")
CXXLIB+=-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic -Wl,--as-needed
else
CXXLIB+=-lstdc++
endif
INSTALL:=@INSTALL@
PREFIX:=@prefix@
BINDIR:=$(DESTDIR)$(PREFIX)/sbin
@ -150,7 +157,7 @@ lib/libpdata.a: $(OBJECTS)
bin/pdata_tools: $(OBJECTS)
@echo " [LD] $@"
$(V) $(CXX) $(CXXFLAGS) $(LDFLAGS) -o $@ $+ $(LIBS)
$(V) $(CXX) $(CXXFLAGS) $(LDFLAGS) -o $@ $+ $(LIBS) $(CXXLIB)
#----------------------------------------------------------------

View File

@ -1 +1 @@
0.6.0
0.6.1

View File

@ -137,6 +137,14 @@ AC_ARG_ENABLE(testing,
TESTING=$enableval, TESTING=no)
AC_MSG_RESULT($TESTING)
################################################################################
dnl -- Enable static libstdc++
AC_MSG_CHECKING(whether to statically link libstdc++)
AC_ARG_ENABLE(static_cxx,
AC_HELP_STRING(--enable-static-cxx, [enable static link of libstdc++]),
STATIC_CXX=$enableval, STATIC_CXX=no)
AC_MSG_RESULT($STATIC_CXX)
################################################################################
dnl -- Check for getopt
AC_CHECK_HEADERS(getopt.h, AC_DEFINE([HAVE_GETOPTLONG], 1, [Define to 1 if getopt_long is available.]))
@ -164,6 +172,7 @@ AC_SUBST(RELEASE_DATE)
AC_SUBST(RELEASE_DATE)
AC_SUBST(TESTING)
AC_SUBST(THIN_PROVISIONING_TOOLS_VERSION)
AC_SUBST(STATIC_CXX)
################################################################################
dnl -- First and last lines should not contain files to generate in order to

View File

@ -100,8 +100,11 @@ namespace base {
else {
typename rset::const_iterator b = runs_.begin();
// Some versions of gcc give a spurious warning here.
maybe last = b->end_;
// Some versions of gcc give a spurious
// warning here. So we initialize it to
// get round it.
maybe last(0);
last = b->end_;
if (b->begin_)
replacement.insert(run<T>(maybe(), *(b->begin_)));

View File

@ -87,17 +87,6 @@ namespace {
} else
return dump_(path, cout, format, flags);
}
void usage(ostream &out, string const &cmd) {
out << "Usage: " << cmd << " [options] {device|file}" << endl
<< "Options:" << endl
<< " {-h|--help}" << endl
<< " {-f|--format} {xml|human_readable}" << endl
<< " {-r|--repair}" << endl
<< " {-m|--metadata-snap} [block#]" << endl
<< " {-o <xml file>}" << endl
<< " {-V|--version}" << endl;
}
}
//----------------------------------------------------------------

View File

@ -58,9 +58,6 @@ namespace {
return 0;
}
void usage(ostream &out, string const &cmd) {
}
}
//----------------------------------------------------------------