summaryrefslogtreecommitdiff
path: root/cpp/src
diff options
context:
space:
mode:
authorStephen D. Huston <shuston@apache.org>2009-10-07 23:43:27 +0000
committerStephen D. Huston <shuston@apache.org>2009-10-07 23:43:27 +0000
commitd5c872e6f0e840de21cb47f882f45c9412873061 (patch)
tree21638a4ef648d77dbf43debefbbb31bbc4851b80 /cpp/src
parentfae0620a65c5b34ba3ec582954ba8f64e1acd9b0 (diff)
downloadqpid-python-d5c872e6f0e840de21cb47f882f45c9412873061.tar.gz
Added more install-related content to the CMake structure.
Adds changes requested in QPID-2123, modified somewhat. Also adds Windows-specific installer content in cpp/packaging. Other specific packaging things can be added there as well. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@822965 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src')
-rw-r--r--cpp/src/CMakeLists.txt186
1 files changed, 153 insertions, 33 deletions
diff --git a/cpp/src/CMakeLists.txt b/cpp/src/CMakeLists.txt
index f4bdb197ef..5795654986 100644
--- a/cpp/src/CMakeLists.txt
+++ b/cpp/src/CMakeLists.txt
@@ -118,19 +118,6 @@ if (ENABLE_VALGRIND AND NOT VALGRIND)
message(STATUS "Can't locate the valgrind command; no run-time error detection")
endif (ENABLE_VALGRIND AND NOT VALGRIND)
-set(QPIDC_INSTALL_LIBDIR ${CMAKE_INSTALL_PREFIX}/lib CACHE STRING
- "Directory to install library files")
-set(QPIDC_INSTALL_CONFDIR ${CMAKE_INSTALL_PREFIX}/etc CACHE STRING
- "Directory to install configuration files")
-set(QPIDC_MODULE_DIR ${QPIDC_INSTALL_LIBDIR}/qpid/client CACHE STRING
- "Directory to load client plug-in modules from")
-set(QPIDD_MODULE_DIR ${QPIDC_INSTALL_LIBDIR}/qpid/daemon CACHE STRING
- "Directory to load broker plug-in modules from")
-set(QPIDC_CONF_FILE ${QPIDC_INSTALL_CONFDIR}/qpid/qpidc.conf CACHE STRING
- "Name of the Qpid client configuration file")
-set(QPIDD_CONF_FILE ${QPIDC_INSTALL_CONFDIR}/qpid/qpidd.conf CACHE STRING
- "Name of the Qpid broker configuration file")
-
option(ENABLE_WARNINGS "Enable lots of compiler warnings (recommended)" ON)
if (ENABLE_WARNINGS AND CMAKE_COMPILER_IS_GNUCXX)
# Warnings: Enable as many as possible, keep the code clean. Please
@@ -272,6 +259,9 @@ if (BUILD_XML)
PREFIX ""
LINK_FLAGS -Wl,--no-undefined)
endif (CMAKE_COMPILER_IS_GNUCXX)
+ install (TARGETS xml RUNTIME
+ DESTINATION ${QPIDD_MODULE_DIR}
+ COMPONENT ${QPID_COMPONENT_BROKER})
set(xml_tests XmlClientSessionTest)
@@ -301,6 +291,9 @@ if (BUILD_ACL)
PREFIX ""
LINK_FLAGS -Wl,--no-undefined)
endif (CMAKE_COMPILER_IS_GNUCXX)
+ install (TARGETS acl RUNTIME
+ DESTINATION ${QPIDD_MODULE_DIR}
+ COMPONENT ${QPID_COMPONENT_BROKER})
endif (BUILD_ACL)
# Check for optional cluster support requirements
@@ -329,7 +322,7 @@ if (CMAKE_SYSTEM_NAME STREQUAL Windows)
)
endif (MSVC)
- set (libqpidcommon_platform_SOURCES
+ set (qpidcommon_platform_SOURCES
qpid/log/windows/SinkOptions.cpp
qpid/sys/windows/AsynchIO.cpp
qpid/sys/windows/FileSysDir.cpp
@@ -346,15 +339,22 @@ if (CMAKE_SYSTEM_NAME STREQUAL Windows)
qpid/sys/windows/Time.cpp
qpid/sys/windows/uuid.cpp
)
- set (libqpidcommon_platform_LIBS
+ set (qpidcommon_platform_LIBS
rpcrt4 ws2_32
)
- set (libqpidbroker_platform_SOURCES
+ set (qpidcommon_platform_INSTALL_HEADERS
+ ../include/qpid/sys/windows/Condition.h
+ ../include/qpid/sys/windows/IntegerTypes.h
+ ../include/qpid/sys/windows/Mutex.h
+ ../include/qpid/sys/windows/Time.h
+ ../include/qpid/sys/windows/check.h
+ )
+ set (qpidbroker_platform_SOURCES
qpid/broker/windows/BrokerDefaults.cpp
qpid/broker/windows/SaslAuthenticator.cpp
)
- set (libqpidclient_platform_SOURCES
+ set (qpidclient_platform_SOURCES
qpid/client/windows/SaslFactory.cpp
)
@@ -375,7 +375,7 @@ else (CMAKE_SYSTEM_NAME STREQUAL Windows)
set (qpid_poller_module qpid/sys/solaris/ECFPoller.cpp)
endif (CMAKE_SYSTEM_NAME STREQUAL SunOS)
- set (libqpidcommon_platform_SOURCES
+ set (qpidcommon_platform_SOURCES
qpid/sys/posix/AsynchIO.cpp
qpid/sys/posix/Fork.cpp
qpid/sys/posix/FileSysDir.cpp
@@ -394,14 +394,22 @@ else (CMAKE_SYSTEM_NAME STREQUAL Windows)
${qpid_poller_module}
)
- set (libqpidcommon_platform_LIBS
+ set (qpidcommon_platform_LIBS
${Boost_PROGRAM_OPTIONS_LIBRARY}
${Boost_FILESYSTEM_LIBRARY}
uuid
${CMAKE_DL_LIBS}
)
+ set (qpidcommon_platform_INSTALL_HEADERS
+ ../include/qpid/sys/posix/Condition.h
+ ../include/qpid/sys/posix/IntegerTypes.h
+ ../include/qpid/sys/posix/Mutex.h
+ ../include/qpid/sys/posix/PrivatePosix.h
+ ../include/qpid/sys/posix/Time.h
+ ../include/qpid/sys/posix/check.h
+ )
- set (libqpidbroker_platform_SOURCES
+ set (qpidbroker_platform_SOURCES
qpid/broker/Daemon.cpp
qpid/broker/SaslAuthenticator.cpp
qpid/broker/SignalHandler.h
@@ -409,7 +417,7 @@ else (CMAKE_SYSTEM_NAME STREQUAL Windows)
qpid/broker/posix/BrokerDefaults.cpp
)
- set (libqpidclient_platform_SOURCES
+ set (qpidclient_platform_SOURCES
qpid/client/SaslFactory.cpp
)
@@ -418,9 +426,9 @@ else (CMAKE_SYSTEM_NAME STREQUAL Windows)
)
endif (CMAKE_SYSTEM_NAME STREQUAL Windows)
-set (libqpidcommon_SOURCES
+set (qpidcommon_SOURCES
${rgen_framing_srcs}
- ${libqpidcommon_platform_SOURCES}
+ ${qpidcommon_platform_SOURCES}
${qpidcommon_sasl_source}
qpid/assert.cpp
qpid/Address.cpp
@@ -476,19 +484,23 @@ set (libqpidcommon_SOURCES
qpid/sys/Shlib.cpp
qpid/sys/Timer.cpp
)
-add_library (qpidcommon SHARED ${libqpidcommon_SOURCES})
+
+add_library (qpidcommon SHARED ${qpidcommon_SOURCES})
if (CLOCK_GETTIME_IN_RT)
- set (libqpidcommon_platform_LIBS ${libqpidcommon_platform_LIBS} rt)
+ set (qpidcommon_platform_LIBS ${qpidcommon_platform_LIBS} rt)
endif (CLOCK_GETTIME_IN_RT)
target_link_libraries (qpidcommon
- ${libqpidcommon_platform_LIBS}
+ ${qpidcommon_platform_LIBS}
${qpidcommon_sasl_lib})
set_target_properties (qpidcommon PROPERTIES
VERSION ${qpidc_version})
+install (TARGETS qpidcommon
+ DESTINATION ${QPID_INSTALL_LIBDIR}
+ COMPONENT ${QPID_COMPONENT_COMMON})
-set (libqpidclient_SOURCES
+set (qpidclient_SOURCES
${rgen_client_srcs}
- ${libqpidclient_platform_SOURCES}
+ ${qpidclient_platform_SOURCES}
qpid/client/Bounds.cpp
qpid/client/Completion.cpp
qpid/client/Connection.cpp
@@ -562,13 +574,100 @@ set (libqpidclient_SOURCES
qpid/client/amqp0_10/SenderImpl.h
qpid/client/amqp0_10/SenderImpl.cpp
)
-add_library (qpidclient SHARED ${libqpidclient_SOURCES})
+set (qpidclient_INSTALL_HEADERS
+ ../include/qpid/Address.h
+ ../include/qpid/CommonImportExport.h
+ ../include/qpid/Exception.h
+ ../include/qpid/InlineAllocator.h
+ ../include/qpid/InlineVector.h
+ ../include/qpid/Msg.h
+ ../include/qpid/Options.h
+ ../include/qpid/RangeSet.h
+ ../include/qpid/SessionId.h
+ ../include/qpid/Url.h
+ ../include/qpid/client/AsyncSession.h
+ ../include/qpid/client/ClientImportExport.h
+ ../include/qpid/client/Completion.h
+ ../include/qpid/client/Connection.h
+ ../include/qpid/client/ConnectionSettings.h
+ ../include/qpid/client/FailoverManager.h
+ ../include/qpid/client/FlowControl.h
+ ../include/qpid/client/Future.h
+ ../include/qpid/client/FutureCompletion.h
+ ../include/qpid/client/FutureResult.h
+ ../include/qpid/client/Handle.h
+ ../include/qpid/client/LocalQueue.h
+ ../include/qpid/client/Message.h
+ ../include/qpid/client/MessageListener.h
+ ../include/qpid/client/MessageReplayTracker.h
+ ../include/qpid/client/QueueOptions.h
+ ../include/qpid/client/Session.h
+ ../include/qpid/client/SessionBase_0_10.h
+ ../include/qpid/client/Subscription.h
+ ../include/qpid/client/SubscriptionManager.h
+ ../include/qpid/client/SubscriptionSettings.h
+ ../include/qpid/client/TypedResult.h
+ ../include/qpid/framing/Array.h
+ ../include/qpid/framing/Buffer.h
+ ../include/qpid/framing/FieldTable.h
+ ../include/qpid/framing/FieldValue.h
+ ../include/qpid/framing/List.h
+ ../include/qpid/framing/ProtocolVersion.h
+ ../include/qpid/framing/SequenceNumber.h
+ ../include/qpid/framing/SequenceSet.h
+ ../include/qpid/framing/StructHelper.h
+ ../include/qpid/framing/Uuid.h
+ ../include/qpid/framing/amqp_types.h
+ ../include/qpid/framing/amqp_types_full.h
+ ../include/qpid/log/Logger.h
+ ../include/qpid/log/Options.h
+ ../include/qpid/log/Selector.h
+ ../include/qpid/log/SinkOptions.h
+ ../include/qpid/log/Statement.h
+ ../include/qpid/management/Args.h
+ ../include/qpid/management/Manageable.h
+ ../include/qpid/management/ManagementEvent.h
+ ../include/qpid/management/ManagementObject.h
+ ../include/qpid/sys/Condition.h
+ ../include/qpid/sys/IOHandle.h
+ ../include/qpid/sys/IntegerTypes.h
+ ../include/qpid/sys/Monitor.h
+ ../include/qpid/sys/Mutex.h
+ ../include/qpid/sys/Runnable.h
+ ../include/qpid/sys/StrError.h
+ ../include/qpid/sys/SystemInfo.h
+ ../include/qpid/sys/Thread.h
+ ../include/qpid/sys/Time.h
+ ../include/qpid/messaging/Address.h
+ ../include/qpid/messaging/Connection.h
+ ../include/qpid/messaging/Codec.h
+ ../include/qpid/messaging/Filter.h
+ ../include/qpid/messaging/ListContent.h
+ ../include/qpid/messaging/ListView.h
+ ../include/qpid/messaging/MapContent.h
+ ../include/qpid/messaging/MapView.h
+ ../include/qpid/messaging/Message.h
+ ../include/qpid/messaging/MessageListener.h
+ ../include/qpid/messaging/Sender.h
+ ../include/qpid/messaging/Receiver.h
+ ../include/qpid/messaging/Session.h
+ ../include/qpid/messaging/Variant.h
+ ../include/qpid/client/amqp0_10/Codecs.h
+)
+
+add_library (qpidclient SHARED ${qpidclient_SOURCES})
target_link_libraries (qpidclient qpidcommon)
set_target_properties (qpidclient PROPERTIES VERSION ${qpidc_version})
-
-set (libqpidbroker_SOURCES
+install (TARGETS qpidclient
+ DESTINATION ${QPID_INSTALL_LIBDIR}
+ COMPONENT ${QPID_COMPONENT_CLIENT})
+install (DIRECTORY ../include/qpid DESTINATION ${QPID_INSTALL_INCLUDEDIR}
+ COMPONENT ${QPID_COMPONENT_CLIENT_INCLUDE}
+ PATTERN ".svn" EXCLUDE)
+
+set (qpidbroker_SOURCES
${mgen_broker_cpp}
- ${libqpidbroker_platform_SOURCES}
+ ${qpidbroker_platform_SOURCES}
qpid/amqp_0_10/Connection.h
qpid/amqp_0_10/Connection.cpp
qpid/broker/Broker.cpp
@@ -633,12 +732,15 @@ set (libqpidbroker_SOURCES
qpid/management/ManagementExchange.cpp
qpid/sys/TCPIOPlugin.cpp
)
-add_library (qpidbroker SHARED ${libqpidbroker_SOURCES})
+add_library (qpidbroker SHARED ${qpidbroker_SOURCES})
target_link_libraries (qpidbroker qpidcommon)
set_target_properties (qpidbroker PROPERTIES VERSION ${qpidc_version})
if (MSVC)
set_target_properties (qpidbroker PROPERTIES COMPILE_FLAGS /wd4290)
endif (MSVC)
+install (TARGETS qpidbroker RUNTIME
+ DESTINATION ${QPID_INSTALL_LIBDIR}
+ COMPONENT ${QPID_COMPONENT_BROKER})
set (qpidd_SOURCES
${qpidd_platform_SOURCES}
@@ -648,6 +750,9 @@ set (qpidd_SOURCES
add_executable (qpidd ${qpidd_SOURCES})
target_link_libraries (qpidd qpidbroker qpidcommon ${Boost_PROGRAM_OPTIONS_LIBRARY}
${Boost_FILESYSTEM_LIBRARY})
+install (TARGETS qpidd RUNTIME
+ DESTINATION ${QPID_INSTALL_BINDIR}
+ COMPONENT ${QPID_COMPONENT_BROKER})
# QMF library
# Library Version Information (CURRENT.REVISION.AGE):
@@ -667,6 +772,9 @@ add_library (qmf SHARED ${qmf_SOURCES})
target_link_libraries (qmf qmfengine)
set_target_properties (qmf PROPERTIES
VERSION ${qmf_version})
+install (TARGETS qmf RUNTIME
+ DESTINATION ${QPID_INSTALL_LIBDIR}
+ COMPONENT ${QPID_COMPONENT_QMF})
set (qmfengine_SOURCES
qmf/engine/Agent.cpp
@@ -698,6 +806,9 @@ add_library (qmfengine SHARED ${qmfengine_SOURCES})
target_link_libraries (qmfengine qpidclient)
set_target_properties (qmfengine PROPERTIES
VERSION ${qmfengine_version})
+install (TARGETS qmfengine
+ DESTINATION ${QPID_INSTALL_LIBDIR}
+ COMPONENT ${QPID_COMPONENT_QMF})
# QMF console library
#module_hdr += \
@@ -744,6 +855,9 @@ add_library (qmfconsole SHARED ${qmfconsole_SOURCES})
target_link_libraries (qmfconsole qpidclient)
set_target_properties (qmfconsole PROPERTIES
VERSION ${qpidc_version})
+install (TARGETS qmfconsole
+ DESTINATION ${QPID_INSTALL_LIBDIR}
+ COMPONENT ${QPID_COMPONENT_QMF})
# A queue event listener plugin that creates messages on a replication
# queue corresponding to enqueue and dequeue events:
@@ -759,6 +873,9 @@ if (CMAKE_COMPILER_IS_GNUCXX)
set_target_properties(replicating_listener PROPERTIES
LINK_FLAGS -Wl,--no-undefined)
endif (CMAKE_COMPILER_IS_GNUCXX)
+install (TARGETS replicating_listener
+ DESTINATION ${QPIDD_MODULE_DIR}
+ COMPONENT ${QPID_COMPONENT_BROKER})
# A custom exchange plugin that allows an exchange to be created that
# can process the messages from a replication queue (populated on the
@@ -776,6 +893,9 @@ if (CMAKE_COMPILER_IS_GNUCXX)
set_target_properties(replicating_exchange PROPERTIES
LINK_FLAGS -Wl,--no-undefined)
endif (CMAKE_COMPILER_IS_GNUCXX)
+install (TARGETS replicating_exchange
+ DESTINATION ${QPIDD_MODULE_DIR}
+ COMPONENT ${QPID_COMPONENT_BROKER})
# This is only really needed until all the trunk builds (Linux, UNIX, Windows)
# are all on cmake only. This is because cmake builds always have a config.h