From cda7a0f8cf03b7a99e077043daa2d99ac16ace81 Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Wed, 9 Feb 2011 23:32:46 -0800 Subject: STORM-987 : Create initial files for llimage_libtest (doesn't build) --- .../llimage_libtest/CMakeLists.txt | 114 +++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 indra/integration_tests/llimage_libtest/CMakeLists.txt (limited to 'indra/integration_tests/llimage_libtest/CMakeLists.txt') diff --git a/indra/integration_tests/llimage_libtest/CMakeLists.txt b/indra/integration_tests/llimage_libtest/CMakeLists.txt new file mode 100644 index 0000000000..e3c508659b --- /dev/null +++ b/indra/integration_tests/llimage_libtest/CMakeLists.txt @@ -0,0 +1,114 @@ +# -*- cmake -*- + +# Integration tests of the llimage library (JPEG2000 images reading and writing) + +if (VIEWER) + +project (llimage_libtest) + +include(00-Common) +include(LLCommon) +include(LLImage) +include(LLImageJ2COJ) +include(LLKDU) +include(LLMath) +#include(LLVFS) # ugh, needed for LLDir +#include(LLXML) +#include(LLXUIXML) +include(Linking) +# include(Tut) + +include_directories( + ${LLCOMMON_INCLUDE_DIRS} + ${LLIMAGE_INCLUDE_DIRS} + ${LLMATH_INCLUDE_DIRS} + ) + +set(llimage_libtest_SOURCE_FILES + llimage_libtest.cpp + ) + +set(llimage_libtest_HEADER_FILES + CMakeLists.txt + llimage_libtest.h + ) + +set_source_files_properties(${llimage_libtest_HEADER_FILES} + PROPERTIES HEADER_FILE_ONLY TRUE) + +list(APPEND llimage_libtest_SOURCE_FILES ${llimage_libtest_HEADER_FILES}) + +add_executable(llimage_libtest ${llimage_libtest_SOURCE_FILES}) + +# Link with OS-specific libraries +if (DARWIN) + find_library(COCOA_LIBRARY Cocoa) + set(OS_LIBRARIES ${COCOA_LIBRARY}) +elseif (WINDOWS) + #ll_stack_trace needs this now... + list(APPEND WINDOWS_LIBRARIES dbghelp) + set(OS_LIBRARIES ${WINDOWS_LIBRARIES}) +elseif (LINUX) + set(OS_LIBRARIES) +else (DARWIN) + message(FATAL_ERROR "unknown platform") +endif (DARWIN) + +# Libraries on which this library depends, needed for Linux builds +# Sort by high-level to low-level +target_link_libraries(llimage_libtest + ${LLIMAGE_LIBRARIES} + ${LLKDU_LIBRARIES} + ${KDU_LIBRARY} + ${LLIMAGEJ2COJ_LIBRARIES} + ${OS_LIBRARIES} + ${GOOGLE_PERFTOOLS_LIBRARIES} + ) + +if (DARWIN) + set_target_properties(llimage_libtest + PROPERTIES + OUTPUT_NAME "llimage_libtest" + MACOSX_BUNDLE_INFO_STRING "llimage test utility" + MACOSX_BUNDLE_GUI_IDENTIFIER "llimage_libtest" + MACOSX_BUNDLE_LONG_VERSION_STRING "0.5" + MACOSX_BUNDLE_BUNDLE_NAME "llimage_libtest" + MACOSX_BUNDLE_SHORT_VERSION_STRING "v0.5" + MACOSX_BUNDLE_BUNDLE_VERSION "v0.5" + MACOSX_BUNDLE_COPYRIGHT "Copyright Linden Lab 2011" + ) + # TODO : Copy over libs in the bundle +elseif (WINDOWS) + set_target_properties(llimage_libtest + PROPERTIES + LINK_FLAGS "/NODEFAULTLIB:LIBCMT" + LINK_FLAGS_DEBUG "/NODEFAULTLIB:MSVCRT /NODEFAULTLIB:LIBCMTD" + ) + + # Copy over OpenJPEG.dll + # *NOTE: On Windows with VS2005, only the first comment prints + set(OPENJPEG_RELEASE + "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release/openjpeg.dll") + add_custom_command( TARGET llimage_libtest POST_BUILD + COMMAND ${CMAKE_COMMAND} -E copy_if_different + ${OPENJPEG_RELEASE} ${CMAKE_CURRENT_BINARY_DIR} + COMMENT "Copying OpenJPEG DLLs to binary directory" + ) + set(OPENJPEG_DEBUG + "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug/openjpegd.dll") + add_custom_command( TARGET llimage_libtest POST_BUILD + COMMAND ${CMAKE_COMMAND} -E copy_if_different + ${OPENJPEG_DEBUG} ${CMAKE_CURRENT_BINARY_DIR} + ) +elseif (LINUX) + # TODO : please help me get this to build and run for Linux! +else (DARWIN) + message(FATAL_ERROR "unknown platform") +endif (DARWIN) + +# Ensure people working on the viewer don't break this library +# *NOTE: This could be removed, or only built by TeamCity, if the build +# and link times become too long. +add_dependencies(viewer llimage_libtest) + +endif (VIEWER) -- cgit v1.2.3 From b430cf7524d91e27aadcf8a37b03af9b6b4d3e42 Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Tue, 15 Feb 2011 18:13:44 -0800 Subject: STORM-987 : Clean-up very silly cmake issues prior to making Windows build --- indra/integration_tests/llimage_libtest/CMakeLists.txt | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'indra/integration_tests/llimage_libtest/CMakeLists.txt') diff --git a/indra/integration_tests/llimage_libtest/CMakeLists.txt b/indra/integration_tests/llimage_libtest/CMakeLists.txt index 0733e5e283..f59440be6b 100644 --- a/indra/integration_tests/llimage_libtest/CMakeLists.txt +++ b/indra/integration_tests/llimage_libtest/CMakeLists.txt @@ -53,11 +53,9 @@ if (DARWIN) find_library(COREFOUNDATION_LIBRARY CoreFoundation) set(OS_LIBRARIES ${COREFOUNDATION_LIBRARY}) elseif (WINDOWS) - #ll_stack_trace needs this now... - list(APPEND WINDOWS_LIBRARIES dbghelp) - set(OS_LIBRARIES ${WINDOWS_LIBRARIES}) +# set(OS_LIBRARIES) elseif (LINUX) - set(OS_LIBRARIES) +# set(OS_LIBRARIES) else (DARWIN) message(FATAL_ERROR "Unknown platform") endif (DARWIN) @@ -106,12 +104,15 @@ if (DARWIN) add_custom_command(TARGET llimage_libtest POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libapr-1.0.3.7.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} DEPENDS ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libapr-1.0.3.7.dylib - add_custom_command(TARGET llimage_libtest POST_BUILD + ) + add_custom_command(TARGET llimage_libtest POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libaprutil-1.0.3.8.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} DEPENDS ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libaprutil-1.0.3.8.dylib + ) add_custom_command(TARGET llimage_libtest POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libexception_handler.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} DEPENDS ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libexception_handler.dylib + ) add_custom_command(TARGET llimage_libtest POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libexpat.0.5.0.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} DEPENDS ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libexpat.0.5.0.dylib -- cgit v1.2.3 From df05762114bae02d18fe14bbfbb5ca45222104f8 Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Tue, 29 Mar 2011 16:54:52 -0700 Subject: STORM-987: Make building of llimage_libtest optional so that builf failure on Linux doesn't block autobuild merge --- indra/integration_tests/llimage_libtest/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/integration_tests/llimage_libtest/CMakeLists.txt') diff --git a/indra/integration_tests/llimage_libtest/CMakeLists.txt b/indra/integration_tests/llimage_libtest/CMakeLists.txt index f59440be6b..cab0546083 100644 --- a/indra/integration_tests/llimage_libtest/CMakeLists.txt +++ b/indra/integration_tests/llimage_libtest/CMakeLists.txt @@ -53,9 +53,9 @@ if (DARWIN) find_library(COREFOUNDATION_LIBRARY CoreFoundation) set(OS_LIBRARIES ${COREFOUNDATION_LIBRARY}) elseif (WINDOWS) -# set(OS_LIBRARIES) + set(OS_LIBRARIES) elseif (LINUX) -# set(OS_LIBRARIES) + set(OS_LIBRARIES) else (DARWIN) message(FATAL_ERROR "Unknown platform") endif (DARWIN) -- cgit v1.2.3 From 7b47c0a6f6f74bd42382f37102446742f91bd34a Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Wed, 30 Mar 2011 13:22:41 -0700 Subject: STORM-987 : cmake fixes so that llimage_libtest builds correctly on Mac with autobuild --- indra/integration_tests/llimage_libtest/CMakeLists.txt | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'indra/integration_tests/llimage_libtest/CMakeLists.txt') diff --git a/indra/integration_tests/llimage_libtest/CMakeLists.txt b/indra/integration_tests/llimage_libtest/CMakeLists.txt index cab0546083..fdd6770aca 100644 --- a/indra/integration_tests/llimage_libtest/CMakeLists.txt +++ b/indra/integration_tests/llimage_libtest/CMakeLists.txt @@ -102,20 +102,20 @@ add_custom_command(TARGET llimage_libtest POST_BUILD if (DARWIN) # Copy the required libraries to the package app add_custom_command(TARGET llimage_libtest POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libapr-1.0.3.7.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} - DEPENDS ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libapr-1.0.3.7.dylib + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../build-darwin-i386/packages/lib/release/libapr-1.0.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} + DEPENDS ${CMAKE_SOURCE_DIR}/../build-darwin-i386/packages/lib/release/libapr-1.0.dylib ) - add_custom_command(TARGET llimage_libtest POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libaprutil-1.0.3.8.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} - DEPENDS ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libaprutil-1.0.3.8.dylib + add_custom_command(TARGET llimage_libtest POST_BUILD + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../build-darwin-i386/packages/lib/release/libaprutil-1.0.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} + DEPENDS ${CMAKE_SOURCE_DIR}/../build-darwin-i386/packages/lib/release/libaprutil-1.0.dylib ) add_custom_command(TARGET llimage_libtest POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libexception_handler.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} - DEPENDS ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libexception_handler.dylib + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../build-darwin-i386/packages/lib/release/libexception_handler.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} + DEPENDS ${CMAKE_SOURCE_DIR}/../build-darwin-i386/packages/lib/release/libexception_handler.dylib ) add_custom_command(TARGET llimage_libtest POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libexpat.0.5.0.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} - DEPENDS ${CMAKE_SOURCE_DIR}/../libraries/universal-darwin/lib_release/libexpat.0.5.0.dylib + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/../build-darwin-i386/packages/lib/release/libexpat.1.5.2.dylib ${LLIMAGE_LIBTEST_DESTINATION_DIR} + DEPENDS ${CMAKE_SOURCE_DIR}/../build-darwin-i386/packages/lib/release/libexpat.1.5.2.dylib ) endif (DARWIN) -- cgit v1.2.3 From 48be3c6af841231f705d88598672588e68e2977e Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Wed, 30 Mar 2011 14:47:35 -0700 Subject: STORM-1121 : Simplify dependencies for llimage_libtest --- indra/integration_tests/llimage_libtest/CMakeLists.txt | 6 ------ 1 file changed, 6 deletions(-) (limited to 'indra/integration_tests/llimage_libtest/CMakeLists.txt') diff --git a/indra/integration_tests/llimage_libtest/CMakeLists.txt b/indra/integration_tests/llimage_libtest/CMakeLists.txt index fdd6770aca..a687e60610 100644 --- a/indra/integration_tests/llimage_libtest/CMakeLists.txt +++ b/indra/integration_tests/llimage_libtest/CMakeLists.txt @@ -6,19 +6,15 @@ project (llimage_libtest) include(00-Common) include(LLCommon) -include(Linking) -include(LLSharedLibs) include(LLImage) include(LLImageJ2COJ) include(LLKDU) -include(LLMath) include(LLVFS) include_directories( ${LLCOMMON_INCLUDE_DIRS} ${LLVFS_INCLUDE_DIRS} ${LLIMAGE_INCLUDE_DIRS} - ${LLMATH_INCLUDE_DIRS} ) set(llimage_libtest_SOURCE_FILES @@ -127,5 +123,3 @@ endif (WINDOWS) # *NOTE: This could be removed, or only built by TeamCity, if the build # and link times become too long. add_dependencies(viewer llimage_libtest) - -ll_deploy_sharedlibs_command(llimage_libtest) -- cgit v1.2.3