You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@thrift.apache.org by dr...@apache.org on 2010/08/31 18:51:28 UTC

svn commit: r991253 - in /incubator/thrift/trunk: aclocal/ax_boost_base.m4 compiler/cpp/Makefile.am configure.ac

Author: dreiss
Date: Tue Aug 31 16:51:28 2010
New Revision: 991253

URL: http://svn.apache.org/viewvc?rev=991253&view=rev
Log:
THRIFT-507. Only use Boost for building the C++ library

- Make AX_BOOST_BASE warn instead of fataling if Boost is not found.
- If Boost is not found, disable compilation of the C++ library.
- Do not use CPPFLAGS or LDFLAGS from Boost when building the compiler.

Modified:
    incubator/thrift/trunk/aclocal/ax_boost_base.m4
    incubator/thrift/trunk/compiler/cpp/Makefile.am
    incubator/thrift/trunk/configure.ac

Modified: incubator/thrift/trunk/aclocal/ax_boost_base.m4
URL: http://svn.apache.org/viewvc/incubator/thrift/trunk/aclocal/ax_boost_base.m4?rev=991253&r1=991252&r2=991253&view=diff
==============================================================================
--- incubator/thrift/trunk/aclocal/ax_boost_base.m4 (original)
+++ incubator/thrift/trunk/aclocal/ax_boost_base.m4 Tue Aug 31 16:51:28 2010
@@ -24,6 +24,7 @@
 # LAST MODIFICATION
 #
 #   2007-07-28
+#   Modified for use in Thrift
 #
 # COPYLEFT
 #
@@ -181,9 +182,9 @@ if test "x$want_boost" = "xyes"; then
 
 	if test "$succeeded" != "yes" ; then
 		if test "$_version" = "0" ; then
-			AC_MSG_ERROR([[We could not detect the boost libraries (version $boost_lib_version_req_shorten or higher). If you have a staged boost library (still not installed) please specify \$BOOST_ROOT in your environment and do not give a PATH to --with-boost option.  If you are sure you have boost installed, then check your version number looking in <boost/version.hpp>. See http://randspringer.de/boost for more documentation.]])
+			AC_MSG_WARN([[We could not detect the boost libraries (version $boost_lib_version_req_shorten or higher). If you have a staged boost library (still not installed) please specify \$BOOST_ROOT in your environment and do not give a PATH to --with-boost option.  If you are sure you have boost installed, then check your version number looking in <boost/version.hpp>. See http://randspringer.de/boost for more documentation.]])
 		else
-			AC_MSG_NOTICE([Your boost libraries seems to old (version $_version).])
+			AC_MSG_WARN([Your boost libraries seems to old (version $_version).])
 		fi
 	else
 		AC_SUBST(BOOST_CPPFLAGS)

Modified: incubator/thrift/trunk/compiler/cpp/Makefile.am
URL: http://svn.apache.org/viewvc/incubator/thrift/trunk/compiler/cpp/Makefile.am?rev=991253&r1=991252&r2=991253&view=diff
==============================================================================
--- incubator/thrift/trunk/compiler/cpp/Makefile.am (original)
+++ incubator/thrift/trunk/compiler/cpp/Makefile.am Tue Aug 31 16:51:28 2010
@@ -108,8 +108,8 @@ if THRIFT_GEN_js
 thrift_SOURCES += src/generate/t_js_generator.cc
 endif
 
-thrift_CXXFLAGS = -Wall -I$(srcdir)/src $(BOOST_CPPFLAGS)
-thrift_LDFLAGS = -Wall $(BOOST_LDFLAGS)
+thrift_CXXFLAGS = -Wall -I$(srcdir)/src
+thrift_LDFLAGS = -Wall
 
 thrift_LDADD = @LEXLIB@
 

Modified: incubator/thrift/trunk/configure.ac
URL: http://svn.apache.org/viewvc/incubator/thrift/trunk/configure.ac?rev=991253&r1=991252&r2=991253&view=diff
==============================================================================
--- incubator/thrift/trunk/configure.ac (original)
+++ incubator/thrift/trunk/configure.ac Tue Aug 31 16:51:28 2010
@@ -74,14 +74,14 @@ AC_PROG_LN_S
 AC_PROG_MKDIR_P
 
 AC_LANG([C++])
-AX_BOOST_BASE([1.33.1])
 
 AX_THRIFT_LIB(cpp, [C++], yes)
 have_cpp=no
 if test "$with_cpp" = "yes";  then
-  # Just set this to yes for now, since there is no way
-  # to get through configure without the C++ requirements.
-  have_cpp="yes"
+  AX_BOOST_BASE([1.33.1])
+  if test "x$succeeded" == "xyes" ; then
+    have_cpp="yes"
+  fi
 
   AX_LIB_EVENT([1.0])
   have_libevent=$success