diff options
author | Steven Shaw <steshaw@apache.org> | 2006-11-30 14:18:03 +0000 |
---|---|---|
committer | Steven Shaw <steshaw@apache.org> | 2006-11-30 14:18:03 +0000 |
commit | 4d7f04636758d39a3ef7250cbcc745edb3de7685 (patch) | |
tree | 7244bc2128d6027cf60c58c27b87cade8c2477eb | |
parent | 97eabaa7419f61015067d6b3fc29c3317f795b9e (diff) | |
download | qpid-python-4d7f04636758d39a3ef7250cbcc745edb3de7685.tar.gz |
Changes for building on RHEL3. Also bundle debug and release libs
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@480934 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | cpp/Makefile | 1 | ||||
-rw-r--r-- | cpp/README.rhel3 | 26 | ||||
-rwxr-xr-x | cpp/build.rhel3 | 7 | ||||
-rw-r--r-- | cpp/options-rhel3.mk | 3 | ||||
-rwxr-xr-x | cpp/release.client.rhel3 | 24 | ||||
-rw-r--r-- | cpp/src/qpid/ExceptionHolder.h | 2 |
6 files changed, 36 insertions, 27 deletions
diff --git a/cpp/Makefile b/cpp/Makefile index 8f7b6795b2..d5df4cccaf 100644 --- a/cpp/Makefile +++ b/cpp/Makefile @@ -28,6 +28,7 @@ test: unittest pythontest .PHONY: show-vars show-vars: + @echo RELEASE=$(RELEASE) @echo APR_LDFLAGS=$(APR_LDFLAGS) @echo APR_CFLAGS=$(APR_CFLAGS) @echo CXXFLAGS=$(CXXFLAGS) diff --git a/cpp/README.rhel3 b/cpp/README.rhel3 index 7a9989ced9..7e0c88512c 100644 --- a/cpp/README.rhel3 +++ b/cpp/README.rhel3 @@ -1,29 +1,23 @@ Building on RHEL3 without access to root (i.e. no yum) ====================================================== -Install make-3.80 into ~/local/make-3.80 +Install or soft link the following: -Install apr-1.2.7 into ~/local/apr-1.2.7. + make-3.80 into ~/local/make-3.80 + apr-1.2.7 into ~/local/apr-1.2.7. + boost-1.33.1 into ~/local/boost-1.33.1 + cppunit-1.11.4 into ~/local/cppunit-1.11.4 + JDK 5.0 to ~/local/jdk-1.5 -Install boost-1.33.1 into ~/local/boost-1.33.1 - -Install cppunit-1.11.4 into ~/local/cppunit-1.11.4 - -If you want a standard release build skip this step. If you want a debug -build do the following: - - 1. Edit options-rhel3.mk. Comment out definition of RELEASE. - 2. Edit release.client.rhel3. Change buildType to "debug". - -Build using the following command: +Build using the following command (builds release and debug profiles): $ ./build.rhel3 -Generate cppclient tarball: +Generate cpp-client tarball (includes release and debug libs): - $ ./release.client.rhel3 + $ ./release.client.rhel3 # will use the svn revision as release number -or if you want to name the release: +or if you want to explicitly name the release version: $ ./release.client.rhel3 1.0-RC1 diff --git a/cpp/build.rhel3 b/cpp/build.rhel3 index 84ce7500a1..bc35b7cfa2 100755 --- a/cpp/build.rhel3 +++ b/cpp/build.rhel3 @@ -5,7 +5,14 @@ ln -fs options-rhel3.mk options-local.mk PATH=~/local/make-3.80/bin:$PATH PATH=~/local/apr-1.2.7/bin:$PATH PATH=~/local/cppunit-1.11.4/bin:$PATH +PATH=~/local/jdk-1.5/bin:$PATH LD_LIBRARY_PATH=~/local/apr-1.2.7/lib:$LD_LIBRARY_PATH +export GENTOOLS_DIR=../gentools + +echo Building release build +RELEASE=1 make "$@" + +echo Building debug build make "$@" diff --git a/cpp/options-rhel3.mk b/cpp/options-rhel3.mk index f2108d89e0..be5741e8c6 100644 --- a/cpp/options-rhel3.mk +++ b/cpp/options-rhel3.mk @@ -2,9 +2,6 @@ # Expects dependencies in ~/local # -# Comment out the setting of RELEASE to build a debug release. -RELEASE := 1 - # Configure Boost. BOOST_CXXFLAGS := -I$(HOME)/local/boost-1.33.1/include/boost-1_33_1 CXXFLAGS := $(CXXFLAGS) $(BOOST_CXXFLAGS) diff --git a/cpp/release.client.rhel3 b/cpp/release.client.rhel3 index 52b9d731d9..839277a5c0 100755 --- a/cpp/release.client.rhel3 +++ b/cpp/release.client.rhel3 @@ -1,7 +1,5 @@ #!/bin/bash -buildType="release" # change to "debug" to build a debug release - if [[ $# -eq 1 ]]; then name=$1 elif [[ $# -ne 0 ]]; then @@ -9,8 +7,13 @@ elif [[ $# -ne 0 ]]; then exit 2 else # Default the name to the svn revision - svnRevision=$(svn info | grep ^Revision: | awk '{print $2}') - name=r${svnRevision} + if which svn >/dev/null 2>&1; then + svnRevision=$(svn info | grep ^Revision: | awk '{print $2}') + name=r${svnRevision} + else + echo "You need to have svn in your PATH or specify a release name" + exit 2 + fi fi name=qpid-cpp-client-$name @@ -28,11 +31,16 @@ mkdir $dir # mkdir $dir/lib cp \ - build/apr-$buildType/lib/libqpid_client.so.1.0 \ - build/apr-$buildType/lib/libqpid_common.so.1.0 \ + build/apr-release/lib/libqpid_client.so.1.0 \ + build/apr-release/lib/libqpid_common.so.1.0 \ $dir/lib -cp -r ~/local/apr-1.2.7 $dir/lib -cp -r ~/local/boost-1.33.1 $dir/lib +mkdir $dir/lib.debug +cp \ + build/apr-debug/lib/libqpid_client.so.1.0 \ + build/apr-debug/lib/libqpid_common.so.1.0 \ + $dir/lib.debug +#cp -r ~/local/apr-1.2.7 $dir/lib +#cp -r ~/local/boost-1.33.1 $dir/lib # # Copy over headers. diff --git a/cpp/src/qpid/ExceptionHolder.h b/cpp/src/qpid/ExceptionHolder.h index c2deca803e..2ce3f5ab9e 100644 --- a/cpp/src/qpid/ExceptionHolder.h +++ b/cpp/src/qpid/ExceptionHolder.h @@ -47,6 +47,8 @@ class ExceptionHolder : public Exception, public boost::shared_ptr<Exception> ExceptionHolder(const Exception& e) throw() : shared_ptr(e.clone()) {} ExceptionHolder(const std::exception& e); + ~ExceptionHolder() throw() {} + const char* what() const throw() { return (*this)->what(); } std::string toString() const throw() { return (*this)->toString(); } virtual Exception* clone() const throw() { return (*this)->clone(); } |