|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r53010 - in branches/release/libs/asio: . test
From: troy_at_[hidden]
Date: 2009-05-14 21:49:06
Author: troy
Date: 2009-05-14 21:49:06 EDT (Thu, 14 May 2009)
New Revision: 53010
URL: http://svn.boost.org/trac/boost/changeset/53010
Log:
cleanup of asio tests in cmakeland... link tests still broken
Text files modified:
branches/release/libs/asio/CMakeLists.txt | 2
branches/release/libs/asio/test/CMakeLists.txt | 211 +++++++++++++++------------------------
2 files changed, 82 insertions(+), 131 deletions(-)
Modified: branches/release/libs/asio/CMakeLists.txt
==============================================================================
--- branches/release/libs/asio/CMakeLists.txt (original)
+++ branches/release/libs/asio/CMakeLists.txt 2009-05-14 21:49:06 EDT (Thu, 14 May 2009)
@@ -10,7 +10,7 @@
boost_library_project(
asio
# SRCDIRS
- # TESTDIRS
+ TESTDIRS test
HEADERS ${lib_headers}
# DOCDIRS
DESCRIPTION "Portable networking, including sockets, timers, hostname resolution and socket iostreams."
Modified: branches/release/libs/asio/test/CMakeLists.txt
==============================================================================
--- branches/release/libs/asio/test/CMakeLists.txt (original)
+++ branches/release/libs/asio/test/CMakeLists.txt 2009-05-14 21:49:06 EDT (Thu, 14 May 2009)
@@ -1,10 +1,7 @@
-boost_additional_test_dependencies(asio BOOST_DEPENDS test)
-
-message(STATUS "asio Testing needs love")
+boost_additional_test_dependencies(asio BOOST_DEPENDS test system)
set (dep_libs "")
-
if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
set(os_defines "-D_XOPEN_SOURCE=600 -D_GNU_SOURCE=1")
endif(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
@@ -28,139 +25,93 @@
set(os_defines "-D_XOPEN_SOURCE_EXTENDED")
endif(${CMAKE_SYSTEM_NAME} STREQUAL "hpux")
+message(STATUS "!!!> missing some qnx stuff")
set (USE_SELECT "-DBOOST_ASIO_DISABLE_DEV_POLL -DBOOST_ASIO_DISABLE_EPOLL -DBOOST_ASIO_DISABLE_KQUEUE -DBOOST_ASIO_DISABLE_IOCP")
-set (dep_libs "boost_system boost_date_time boost_thread")
-
-set (os_defines "${os_defines} -DBOOST_ALL_NO_LIB=1")
+set (depends "boost_system;boost_date_time;boost_thread")
-boost_test_link(basic_datagram_socket basic_datagram_socket.cpp )
-boost_test_link(basic_datagram_socket_select basic_datagram_socket.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(basic_deadline_timer basic_deadline_timer.cpp )
-boost_test_link(basic_deadline_timer_select basic_deadline_timer.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(basic_socket_acceptor basic_socket_acceptor.cpp )
-boost_test_link(basic_socket_acceptor_select basic_socket_acceptor.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(basic_stream_socket basic_stream_socket.cpp )
-boost_test_link(basic_stream_socket_select basic_stream_socket.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffer buffer.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffer_select buffer.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffered_read_stream COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffered_read_stream_select buffered_read_stream.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffered_stream COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffered_stream_select buffered_stream.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffered_write_stream COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffered_write_stream_select buffered_write_stream.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(buffers_iterator COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(buffers_iterator_select buffers_iterator.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(completion_condition completion_condition.cpp )
-boost_test_link(completion_condition_select completion_condition.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(datagram_socket_service datagram_socket_service.cpp )
-boost_test_link(datagram_socket_service_select datagram_socket_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(deadline_timer_service deadline_timer_service.cpp )
-boost_test_link(deadline_timer_service_select deadline_timer_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(deadline_timer COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}")
-boost_test_run(deadline_timer_select deadline_timer.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(error COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}")
-boost_test_run(error_select error.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(io_service COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(io_service_select io_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_address ip/address.cpp)
-boost_test_link(ip_address_select ip/address.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_address_v4 ip/address_v4.cpp)
-boost_test_link(ip_address_v4_select ip/address_v4.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_address_v6 ip/address_v6.cpp)
-boost_test_link(ip_address_v6_select ip/address_v6.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_basic_endpoint ip/basic_endpoint.cpp)
-boost_test_link(ip_basic_endpoint_select ip/basic_endpoint.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_basic_resolver ip/basic_resolver.cpp)
-boost_test_link(ip_basic_resolver_select ip/basic_resolver.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_basic_resolver_entry ip/basic_resolver_entry.cpp)
-boost_test_link(ip_basic_resolver_entry_select ip/basic_resolver_entry.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_basic_resolver_iterator ip/basic_resolver_iterator.cpp)
-boost_test_link(ip_basic_resolver_iterator_select ip/basic_resolver_iterator.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_basic_resolver_query ip/basic_resolver_query.cpp )
-boost_test_link(ip_basic_resolver_query_select ip/basic_resolver_query.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(ip_host_name ip/host_name.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(ip_host_name_select ip/host_name.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(ip_multicast ip/multicast.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(ip_multicast_select ip/multicast.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_resolver_query_base ip/resolver_query_base.cpp)
-boost_test_link(ip_resolver_query_base_select ip/resolver_query_base.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(ip_resolver_service ip/resolver_service.cpp)
-boost_test_link(ip_resolver_service_select ip/resolver_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(ip_tcp ip/tcp.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(ip_tcp_select ip/tcp.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(ip_udp ip/udp.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(ip_udp_select ip/udp.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(ip_unicast ip/unicast.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(ip_unicast_select ip/unicast.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(ip_v6_only ip/v6_only.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(ip_v6_only_select ip/v6_only.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(is_read_buffered is_read_buffered.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(is_read_buffered_select is_read_buffered.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(is_write_buffered is_write_buffered.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(is_write_buffered_select is_write_buffered.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(local_basic_endpoint local/basic_endpoint.cpp)
-boost_test_link(local_basic_endpoint_select local/basic_endpoint.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(local_connect_pair local/connect_pair.cpp)
-boost_test_link(local_connect_pair_select local/connect_pair.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(local_datagram_protocol local/datagram_protocol.cpp)
-boost_test_link(local_datagram_protocol_select local/datagram_protocol.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(local_stream_protocol local/stream_protocol.cpp)
-boost_test_link(local_stream_protocol_select local/stream_protocol.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(placeholders placeholders.cpp )
-boost_test_link(placeholders_select placeholders.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(posix_basic_descriptor posix/basic_descriptor.cpp)
-boost_test_link(posix_basic_descriptor_select posix/basic_descriptor.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(posix_basic_stream_descriptor posix/basic_stream_descriptor.cpp)
-boost_test_link(posix_basic_stream_descriptor_select posix/basic_stream_descriptor.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(posix_descriptor_base posix/descriptor_base.cpp)
-boost_test_link(posix_descriptor_base_select posix/descriptor_base.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(posix_stream_descriptor posix/stream_descriptor.cpp)
-boost_test_link(posix_stream_descriptor_select posix/stream_descriptor.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(posix_stream_descriptor_service posix/stream_descriptor_service.cpp)
-boost_test_link(posix_stream_descriptor_service_select posix/stream_descriptor_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(read read.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(read_select read.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(read_at read_at.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(read_at_select read_at.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(read_until read_until.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(read_until_select read_until.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(socket_acceptor_service socket_acceptor_service.cpp )
-boost_test_link(socket_acceptor_service_select socket_acceptor_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(socket_base socket_base.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(socket_base_select socket_base.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(strand strand.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(strand_select strand.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(stream_socket_service stream_socket_service.cpp )
-boost_test_link(stream_socket_service_select stream_socket_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(time_traits time_traits.cpp )
-boost_test_link(time_traits_select time_traits.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
+set (os_defines "${os_defines} -DBOOST_ALL_NO_LIB=1")
+macro(asio_test_run NAME)
+ boost_test_run(${NAME} ${NAME}.cpp
+ COMPILE_FLAGS "${os_defines}"
+ LINK_LIBS "${dep_libs}"
+ DEPENDS ${depends}
+ )
+ boost_test_run(${NAME}_select ${NAME}.cpp
+ COMPILE_FLAGS "${os_defines} ${USE_SELECT}"
+ LINK_LIBS "${dep_libs}"
+ DEPENDS ${depends}
+ )
+endmacro(asio_test_run)
+
+macro(asio_test_link NAME)
+ boost_test_link(${NAME} ${NAME}.cpp
+ COMPILE_FLAGS "${os_defines}"
+ LINK_LIBS "${dep_libs};${depends}"
+ )
+ boost_test_link(${NAME}_select ${NAME}.cpp
+ COMPILE_FLAGS "${os_defines} ${USE_SELECT}"
+ LINK_LIBS "${dep_libs}:${depends}"
+ )
+endmacro(asio_test_link)
+
+foreach(test
+ basic_datagram_socket
+ basic_deadline_timer
+ basic_socket_acceptor
+ basic_stream_socket
+ completion_condition
+ datagram_socket_service
+ deadline_timer_service
+ socket_acceptor_service
+ stream_socket_service
+ time_traits
+ )
+ asio_test_link(${test})
+endforeach()
+
+foreach(test
+ buffer
+ buffered_read_stream
+ buffered_stream
+ buffered_write_stream
+ buffers_iterator
+ deadline_timer
+ error
+ io_service
+ placeholders
+ is_read_buffered
+ is_write_buffered
+ read
+ read_at
+ read_until
+ socket_base
+ strand
+ write
+ write_at
+ )
+ asio_test_run(${test})
+endforeach()
+
+add_subdirectory(ip)
+add_subdirectory(local)
+add_subdirectory(posix)
# Test Windows specific Behaviors
if (MSVC)
-boost_test_link(windows_basic_handle windows/basic_handle.cpp)
-boost_test_link(windows_basic_handle_select windows/basic_handle.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(windows_basic_random_access_handle windows/basic_random_access_handle.cpp)
-boost_test_link(windows_basic_random_access_handle_select windows/basic_random_access_handle.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(windows_basic_stream_handle windows/basic_stream_handle.cpp)
-boost_test_link(windows_basic_stream_handle_select windows/basic_stream_handle.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(windows_overlapped_ptr windows/overlapped_ptr.cpp)
-boost_test_link(windows_overlapped_ptr_select windows/overlapped_ptr.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(windows_random_access_handle windows/random_access_handle.cpp)
-boost_test_link(windows_random_access_handle_select windows/random_access_handle.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(windows_random_access_handle_service windows/random_access_handle_service.cpp)
-boost_test_link(windows_random_access_handle_service_select windows/random_access_handle_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(windows_stream_handle windows/stream_handle.cpp)
-boost_test_link(windows_stream_handle_select windows/stream_handle.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_link(windows_stream_handle_service windows/stream_handle_service.cpp)
-boost_test_link(windows_stream_handle_service_select windows/stream_handle_service.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
+foreach(test
+ windows_basic_handle
+ windows_basic_random_access_handle
+ windows_basic_stream_handle
+ windows_overlapped_ptr
+ windows_random_access_handle
+ windows_random_access_handle_service
+ windows_stream_handle
+ windows_stream_handle_service
+ )
+ boost_test_link(${test})
endif (MSVC)
-
-boost_test_run(write write.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(write_select write.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
-boost_test_run(write_at write_at.cpp COMPILE_FLAGS "${os_defines}" LINK_LIBS "${dep_libs}" )
-boost_test_run(write_at_select write_at.cpp COMPILE_FLAGS "${os_defines} ${USE_SELECT}" LINK_LIBS "${dep_libs}")
+add_subdirectory(ssl)
\ No newline at end of file
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk