[asterisk-scf-commits] asterisk-scf/release/ice-util-cpp.git branch "master" updated.
Commits to the Asterisk SCF project code repositories
asterisk-scf-commits at lists.digium.com
Wed Jun 1 13:25:02 CDT 2011
branch "master" has been updated
via 0b44631d5135fe1ff99346ec991fd722b9785701 (commit)
via 0c0f80099d313b7afb061c0edf1848a1260599fc (commit)
via 5c2cfb8e126af44f886a835297e61c9f00099b44 (commit)
from 4e628d126cdbdcce2d0e45206f0c02bbbc1eaef7 (commit)
Summary of changes:
CMakeLists.txt | 10 ++++++++++
src/CMakeLists.txt | 19 -------------------
src/ThreadPool/CMakeLists.txt | 18 +++---------------
src/WorkQueue/CMakeLists.txt | 20 ++++----------------
test/Async/CMakeLists.txt | 2 --
test/CMakeLists.txt | 24 ++++++++++--------------
test/Replication/CMakeLists.txt | 2 --
test/ThreadPool/CMakeLists.txt | 22 ++--------------------
test/ThreadPool/TestThreadPool.cpp | 12 ++++++++++--
test/WorkQueue/CMakeLists.txt | 12 ++++--------
test/WorkQueue/TestSuspendableWorkQueue.cpp | 2 +-
test/WorkQueue/TestWorkQueue.cpp | 4 ++--
12 files changed, 46 insertions(+), 101 deletions(-)
- Log -----------------------------------------------------------------
commit 0b44631d5135fe1ff99346ec991fd722b9785701
Author: Kevin P. Fleming <kpfleming at digium.com>
Date: Wed Jun 1 13:10:59 2011 -0500
Get TestThreadPool, TestWorkQueue and TestSuspendableWorkQueue to actually
compile and run
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index d81da48..b26ab49 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -14,4 +14,5 @@ target_link_libraries(ice-util-cpp-test asterisk-scf-api)
add_subdirectory(Async)
add_subdirectory(Replication)
-
+add_subdirectory(ThreadPool)
+add_subdirectory(WorkQueue)
diff --git a/test/ThreadPool/CMakeLists.txt b/test/ThreadPool/CMakeLists.txt
index eff9e7f..f7a2c70 100644
--- a/test/ThreadPool/CMakeLists.txt
+++ b/test/ThreadPool/CMakeLists.txt
@@ -6,31 +6,13 @@
# All rights reserved.
#
-asterisk_scf_component_init(ThreadPoolTest CXX)
-
-include_directories(${API_INCLUDE_DIR})
include_directories(../../src/ThreadPool)
-# The test requires a work queue
-include_directories(../../include)
-
+asterisk_scf_component_init(ThreadPoolTest)
asterisk_scf_component_add_file(ThreadPoolTest TestThreadPool.cpp)
asterisk_scf_component_add_file(ThreadPoolTest test.cpp)
asterisk_scf_component_add_boost_libraries(ThreadPoolTest unit_test_framework)
-
-# asterisk_scf_component_add_file(ProofOfConcept ProofOfConcept.cpp)
-# asterisk_scf_component_add_file(ProofOfConcept test.cpp)
-# asterisk_scf_component_add_boost_libraries(ProofOfConcept unit_test_framework)
-
asterisk_scf_component_build_standalone(ThreadPoolTest)
target_link_libraries(ThreadPoolTest asterisk-scf-api)
-target_link_libraries(ThreadPoolTest ThreadPool)
-target_link_libraries(ThreadPoolTest WorkQueue)
-
-# asterisk_scf_component_build_standalone(ProofOfConcept)
-# target_link_libraries(ProofOfConcept asterisk-scf-api)
-# target_link_libraries(ProofOfConcept ThreadPool)
-# target_link_libraries(ProofOfConcept WorkQueue)
-
+target_link_libraries(ThreadPoolTest ice-util-cpp)
asterisk_scf_test_boost(ThreadPoolTest)
-# asterisk_scf_test_boost(ProofOfConcept)
diff --git a/test/ThreadPool/TestThreadPool.cpp b/test/ThreadPool/TestThreadPool.cpp
index 8f2c2d7..05b032f 100644
--- a/test/ThreadPool/TestThreadPool.cpp
+++ b/test/ThreadPool/TestThreadPool.cpp
@@ -18,8 +18,8 @@
#include <boost/thread.hpp>
#include <boost/thread/locks.hpp>
-#include <AsteriskSCF/WorkQueue.h>
-#include <AsteriskSCF/ThreadPool.h>
+#include <AsteriskSCF/WorkQueue/WorkQueue.h>
+#include <AsteriskSCF/ThreadPool/ThreadPool.h>
using namespace AsteriskSCF::System::ThreadPool::V1;
using namespace AsteriskSCF::ThreadPool;
@@ -57,6 +57,14 @@ public:
mEmptyNotice = true;
}
+ void threadStart()
+ {
+ }
+
+ void threadStop()
+ {
+ }
+
Ice::Long mActive;
Ice::Long mIdle;
Ice::Long mZombie;
diff --git a/test/WorkQueue/CMakeLists.txt b/test/WorkQueue/CMakeLists.txt
index 87185b4..8747c05 100644
--- a/test/WorkQueue/CMakeLists.txt
+++ b/test/WorkQueue/CMakeLists.txt
@@ -6,27 +6,23 @@
# All rights reserved.
#
-asterisk_scf_component_init(WorkQueueTest CXX)
-
-include_directories(${API_INCLUDE_DIR})
include_directories(../../src/WorkQueue)
-include_directories(../../include)
+asterisk_scf_component_init(WorkQueueTest)
asterisk_scf_component_add_file(WorkQueueTest TestWorkQueue.cpp)
asterisk_scf_component_add_file(WorkQueueTest test.cpp)
asterisk_scf_component_add_boost_libraries(WorkQueueTest unit_test_framework)
-
asterisk_scf_component_build_standalone(WorkQueueTest)
target_link_libraries(WorkQueueTest asterisk-scf-api)
-target_link_libraries(WorkQueueTest WorkQueue)
+target_link_libraries(WorkQueueTest ice-util-cpp)
+asterisk_scf_component_init(SuspendableWorkQueueTest)
asterisk_scf_component_add_file(SuspendableWorkQueueTest TestSuspendableWorkQueue.cpp)
asterisk_scf_component_add_file(SuspendableWorkQueueTest test2.cpp)
asterisk_scf_component_add_boost_libraries(SuspendableWorkQueueTest unit_test_framework thread)
-
asterisk_scf_component_build_standalone(SuspendableWorkQueueTest)
target_link_libraries(SuspendableWorkQueueTest asterisk-scf-api)
-target_link_libraries(SuspendableWorkQueueTest WorkQueue)
+target_link_libraries(SuspendableWorkQueueTest ice-util-cpp)
asterisk_scf_test_boost(WorkQueueTest)
asterisk_scf_test_boost(SuspendableWorkQueueTest)
diff --git a/test/WorkQueue/TestSuspendableWorkQueue.cpp b/test/WorkQueue/TestSuspendableWorkQueue.cpp
index 9894193..78276ee 100644
--- a/test/WorkQueue/TestSuspendableWorkQueue.cpp
+++ b/test/WorkQueue/TestSuspendableWorkQueue.cpp
@@ -17,7 +17,7 @@
#include <boost/test/unit_test.hpp>
#include <boost/thread.hpp>
-#include <AsteriskSCF/SuspendableWorkQueue.h>
+#include <AsteriskSCF/WorkQueue/SuspendableWorkQueue.h>
using namespace AsteriskSCF::System::WorkQueue::V1;
using namespace AsteriskSCF::WorkQueue;
diff --git a/test/WorkQueue/TestWorkQueue.cpp b/test/WorkQueue/TestWorkQueue.cpp
index 08a9cea..535cece 100644
--- a/test/WorkQueue/TestWorkQueue.cpp
+++ b/test/WorkQueue/TestWorkQueue.cpp
@@ -17,8 +17,8 @@
#include <boost/test/unit_test.hpp>
#include <boost/thread.hpp>
-#include <AsteriskSCF/WorkQueue.h>
-#include <AsteriskSCF/DefaultQueueListener.h>
+#include <AsteriskSCF/WorkQueue/WorkQueue.h>
+#include <AsteriskSCF/WorkQueue/DefaultQueueListener.h>
using namespace AsteriskSCF::System::WorkQueue::V1;
using namespace AsteriskSCF::WorkQueue;
commit 0c0f80099d313b7afb061c0edf1848a1260599fc
Author: Kevin P. Fleming <kpfleming at digium.com>
Date: Wed Jun 1 13:10:24 2011 -0500
More CMake script cleanups, this time for the ice-util-cpp unit tests
diff --git a/test/Async/CMakeLists.txt b/test/Async/CMakeLists.txt
index 4079ce4..5477439 100644
--- a/test/Async/CMakeLists.txt
+++ b/test/Async/CMakeLists.txt
@@ -1,5 +1,3 @@
-include_directories("../src")
-
asterisk_scf_component_init(ami-collector-test)
asterisk_scf_component_add_file(ami-collector-test ResponseCollector-test.cpp)
asterisk_scf_component_add_file(ami-collector-test IceIntegration-test.cpp)
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 40b9f87..d81da48 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -1,19 +1,14 @@
-asterisk_scf_slice_include_directories(${API_SLICE_DIR})
-asterisk_scf_component_init(ice-util-cpp-test CXX)
-include_directories("../include")
-asterisk_scf_component_add_slice(ice-util-cpp-test ./ProxyHelper/SimpleIf.ice)
-asterisk_scf_component_add_file(ice-util-cpp-test ./LocatorRegistration/LocatorRegistrationTest.cpp)
-asterisk_scf_component_add_file(ice-util-cpp-test ./LocatorRegistration/LocatorRegistrationTest.h)
-asterisk_scf_component_add_file(ice-util-cpp-test ./PropertyHelper/PropertyHelperTest.cpp)
-asterisk_scf_component_add_file(ice-util-cpp-test ./PropertyHelper/PropertyHelperTest.h)
-asterisk_scf_component_add_file(ice-util-cpp-test ./ProxyHelper/ProxyHelperTests.cpp)
-asterisk_scf_component_add_file(ice-util-cpp-test ./ProxyHelper/ProxyHelperTests.h)
+asterisk_scf_component_init(ice-util-cpp-test)
+asterisk_scf_component_add_slice(ice-util-cpp-test ProxyHelper/SimpleIf.ice)
+asterisk_scf_component_add_file(ice-util-cpp-test LocatorRegistration/LocatorRegistrationTest.cpp)
+asterisk_scf_component_add_file(ice-util-cpp-test LocatorRegistration/LocatorRegistrationTest.h)
+asterisk_scf_component_add_file(ice-util-cpp-test PropertyHelper/PropertyHelperTest.cpp)
+asterisk_scf_component_add_file(ice-util-cpp-test PropertyHelper/PropertyHelperTest.h)
+asterisk_scf_component_add_file(ice-util-cpp-test ProxyHelper/ProxyHelperTests.cpp)
+asterisk_scf_component_add_file(ice-util-cpp-test ProxyHelper/ProxyHelperTests.h)
asterisk_scf_component_add_file(ice-util-cpp-test UtilityTests.cpp)
-
asterisk_scf_component_add_ice_libraries(ice-util-cpp-test IceBox)
asterisk_scf_component_add_boost_libraries(ice-util-cpp-test unit_test_framework date_time thread)
-
-include_directories(${API_INCLUDE_DIR})
asterisk_scf_component_build_icebox(ice-util-cpp-test)
target_link_libraries(ice-util-cpp-test asterisk-scf-api)
diff --git a/test/Replication/CMakeLists.txt b/test/Replication/CMakeLists.txt
index d054323..829e50d 100644
--- a/test/Replication/CMakeLists.txt
+++ b/test/Replication/CMakeLists.txt
@@ -1,5 +1,3 @@
-include_directories("../include")
-
asterisk_scf_component_init(StateReplicatorTest)
asterisk_scf_component_add_file(StateReplicatorTest TestStateReplicator.cpp)
asterisk_scf_component_add_file(StateReplicatorTest SharedTestData.h)
commit 5c2cfb8e126af44f886a835297e61c9f00099b44
Author: Kevin P. Fleming <kpfleming at digium.com>
Date: Wed Jun 1 11:25:12 2011 -0500
Clean up CMake scripts:
* Move common steps to top-level script
* Remove duplicate function calls
* Remove unnecessary function calls
diff --git a/CMakeLists.txt b/CMakeLists.txt
index bbaf307..74b1a43 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -4,5 +4,15 @@ if (integrated_build STREQUAL "true")
set(utils_dir ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
endif()
+include_directories(include)
+include_directories(${API_INCLUDE_DIR})
+if(NOT logger_dir)
+ message(FATAL_ERROR "The logger directory could not be found ${logger_dir}")
+endif()
+include_directories(${logger_dir}/include)
+asterisk_scf_slice_include_directories(${API_SLICE_DIR})
+
add_subdirectory(src)
add_subdirectory(test)
+
+asterisk_scf_headers_install(include/)
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 5dc7319..61a4ebf 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -9,10 +9,6 @@
# Ice Utilities for C++
asterisk_scf_component_init(ice-util-cpp)
-
-include_directories(../include)
-asterisk_scf_slice_include_directories(${API_SLICE_DIR})
-
asterisk_scf_component_add_file(ice-util-cpp ../include/AsteriskSCF/Discovery/SmartProxy.h)
asterisk_scf_component_add_file(ice-util-cpp ../include/AsteriskSCF/Discovery/LocatorRegistrationWrapper.h)
asterisk_scf_component_add_file(ice-util-cpp ../include/AsteriskSCF/Async/AmiCollector.h)
@@ -34,32 +30,17 @@ asterisk_scf_component_add_file(ice-util-cpp ThreadPool/ThreadPool.cpp)
asterisk_scf_component_add_file(ice-util-cpp ThreadPool/WorkerThread.cpp)
asterisk_scf_component_add_file(ice-util-cpp ../include/AsteriskSCF/CollocatedIceStorm/CollocatedIceStorm.h)
asterisk_scf_component_add_file(ice-util-cpp CollocatedIceStorm/CollocatedIceStorm.cpp)
-
#
# Note, strictly speaking this isn't for component development, but as it is part of this
# library it sort of belongs here.
#
asterisk_scf_component_add_file(ice-util-cpp ../include/AsteriskSCF/Testing/IceBoxBoostTest.h)
-
asterisk_scf_component_add_file(ice-util-cpp IceUtilCpp.cpp)
-
asterisk_scf_component_add_ice_libraries(ice-util-cpp IceStorm)
asterisk_scf_component_add_ice_libraries(ice-util-cpp IceBox)
-
asterisk_scf_component_add_boost_libraries(ice-util-cpp core thread date_time)
-
-if(NOT logger_dir)
- message(FATAL_ERROR "The logger directory could not be found ${logger_dir}")
-endif()
-include_directories(${logger_dir}/include)
-include_directories(${API_INCLUDE_DIR})
-
asterisk_scf_component_build_library(ice-util-cpp)
-
-include_directories(${API_INCLUDE_DIR})
target_link_libraries(ice-util-cpp logging-client)
target_link_libraries(ice-util-cpp asterisk-scf-api)
# don't install the component. it's just there to make Visual Studio happy
-# _do_ install the header files
-asterisk_scf_headers_install(include/)
diff --git a/src/ThreadPool/CMakeLists.txt b/src/ThreadPool/CMakeLists.txt
index 584d4d4..28fd27f 100644
--- a/src/ThreadPool/CMakeLists.txt
+++ b/src/ThreadPool/CMakeLists.txt
@@ -6,24 +6,12 @@
# All rights reserved.
#
-asterisk_scf_slice_include_directories(${API_SLICE_DIR})
-
-asterisk_scf_component_init(ThreadPool CXX)
-
-include_directories(../include)
-include_directories(../../WorkQueue/include)
-include_directories(${API_INCLUDE_DIR})
-
-asterisk_scf_component_add_file(ThreadPool
- ../include/AsteriskSCF/ThreadPool.h)
-asterisk_scf_component_add_file(ThreadPool
- ../include/AsteriskSCF/WorkerThread.h)
+asterisk_scf_component_init(ThreadPool)
+asterisk_scf_component_add_file(ThreadPool ../include/AsteriskSCF/ThreadPool.h)
+asterisk_scf_component_add_file(ThreadPool ../include/AsteriskSCF/WorkerThread.h)
asterisk_scf_component_add_file(ThreadPool ThreadPool.cpp)
asterisk_scf_component_add_file(ThreadPool WorkerThread.cpp)
asterisk_scf_component_add_boost_libraries(ThreadPool thread date_time)
-
asterisk_scf_component_build_library(ThreadPool)
target_link_libraries(ThreadPool WorkQueue)
target_link_libraries(ThreadPool asterisk-scf-api)
-
-asterisk_scf_headers_install(../include/)
diff --git a/src/WorkQueue/CMakeLists.txt b/src/WorkQueue/CMakeLists.txt
index 31d8d88..d642f69 100644
--- a/src/WorkQueue/CMakeLists.txt
+++ b/src/WorkQueue/CMakeLists.txt
@@ -6,26 +6,14 @@
# All rights reserved.
#
-asterisk_scf_slice_include_directories(${API_SLICE_DIR})
-
-asterisk_scf_component_init(WorkQueue CXX)
-
-include_directories(../include)
-include_directories(${API_INCLUDE_DIR})
-
-asterisk_scf_component_add_file(WorkQueue
- ../include/AsteriskSCF/WorkQueue.h)
-asterisk_scf_component_add_file(WorkQueue
- ../include/AsteriskSCF/SuspendableWorkQueue.h)
-asterisk_scf_component_add_file(WorkQueue
- ../include/AsteriskSCF/DefaultQueueListener.h)
+asterisk_scf_component_init(WorkQueue)
+asterisk_scf_component_add_file(WorkQueue ../include/AsteriskSCF/WorkQueue.h)
+asterisk_scf_component_add_file(WorkQueue ../include/AsteriskSCF/SuspendableWorkQueue.h)
+asterisk_scf_component_add_file(WorkQueue ../include/AsteriskSCF/DefaultQueueListener.h)
asterisk_scf_component_add_file(WorkQueue WorkQueue.cpp)
asterisk_scf_component_add_file(WorkQueue SuspendableWorkQueue.cpp)
asterisk_scf_component_add_file(WorkQueue DefaultQueueListener.cpp)
asterisk_scf_component_add_boost_libraries(WorkQueue thread date_time)
-
asterisk_scf_component_build_library(WorkQueue)
target_link_libraries(WorkQueue asterisk-scf-api)
-
-asterisk_scf_headers_install(../include/)
asterisk_scf_component_install(WorkQueue)
-----------------------------------------------------------------------
--
asterisk-scf/release/ice-util-cpp.git
More information about the asterisk-scf-commits
mailing list