diff options
author | Erik Kundiman <erik@megapahit.org> | 2024-10-18 19:35:04 +0800 |
---|---|---|
committer | Erik Kundiman <erik@megapahit.org> | 2024-10-18 20:23:09 +0800 |
commit | 7bde555dde67829e27b26161e3f58bdcc193a024 (patch) | |
tree | 3ec6d66bd523415d49642d8f355bd946d17390e8 /indra/cmake | |
parent | d353111de315f9d37bf914b54a52d217c45a6e19 (diff) | |
parent | ceca01eb37ea7c56be87474b6488eecdf0b7c893 (diff) |
Merge branch 'main' into 2024.09-ExtraFPS
Diffstat (limited to 'indra/cmake')
-rw-r--r-- | indra/cmake/00-Common.cmake | 4 | ||||
-rw-r--r-- | indra/cmake/Boost.cmake | 12 | ||||
-rw-r--r-- | indra/cmake/CURL.cmake | 4 | ||||
-rw-r--r-- | indra/cmake/LLPrimitive.cmake | 203 | ||||
-rw-r--r-- | indra/cmake/LLWindow.cmake | 2 | ||||
-rw-r--r-- | indra/cmake/Meshoptimizer.cmake | 99 | ||||
-rw-r--r-- | indra/cmake/NDOF.cmake | 18 | ||||
-rw-r--r-- | indra/cmake/OpenJPEG.cmake | 98 | ||||
-rw-r--r-- | indra/cmake/OpenSSL.cmake | 224 | ||||
-rw-r--r-- | indra/cmake/ViewerMiscLibs.cmake | 8 | ||||
-rw-r--r-- | indra/cmake/WebRTC.cmake | 2 |
11 files changed, 319 insertions, 355 deletions
diff --git a/indra/cmake/00-Common.cmake b/indra/cmake/00-Common.cmake index 3d2b4e7406..b31b077abd 100644 --- a/indra/cmake/00-Common.cmake +++ b/indra/cmake/00-Common.cmake @@ -58,7 +58,7 @@ set(CMAKE_CONFIGURATION_TYPES "RelWithDebInfo;Release" CACHE STRING "Supported b # Platform-specific compilation flags. -if (WINDOWS) +if (NOT CMAKE_CXX_COMPILER_ID MATCHES GNU AND WINDOWS) # Don't build DLLs. set(BUILD_SHARED_LIBS OFF) @@ -114,7 +114,7 @@ if (WINDOWS) string(REPLACE "/Zi" "/Z7" CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELWITHDEBINFO}") string(REPLACE "/Zi" "/Z7" CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO}") endif() -endif (WINDOWS) +endif (NOT CMAKE_CXX_COMPILER_ID MATCHES GNU AND WINDOWS) if (LINUX OR CMAKE_SYSTEM_NAME MATCHES "FreeBSD") set( CMAKE_BUILD_WITH_INSTALL_RPATH TRUE ) diff --git a/indra/cmake/Boost.cmake b/indra/cmake/Boost.cmake index 31bb4124c2..26c0843300 100644 --- a/indra/cmake/Boost.cmake +++ b/indra/cmake/Boost.cmake @@ -9,13 +9,17 @@ if( USE_CONAN ) target_compile_definitions( ll::boost INTERFACE BOOST_ALLOW_DEPRECATED_HEADERS BOOST_BIND_GLOBAL_PLACEHOLDERS ) return() elseif( NOT USE_AUTOBUILD_3P ) - if (DARWIN) - set(sfx "-mt") + if (WINDOWS) + set(sfx -mt) + target_include_directories( ll::boost SYSTEM INTERFACE /opt/local/x86_64-w64-mingw32/include) + target_link_directories( ll::boost INTERFACE /opt/local/x86_64-w64-mingw32/lib) + elseif (DARWIN) + set(sfx -mt) target_include_directories( ll::boost SYSTEM INTERFACE /opt/local/libexec/boost/1.81/include) target_link_directories( ll::boost INTERFACE /opt/local/libexec/boost/1.81/lib) - else (DARWIN) + else (WINDOWS) find_package( Boost REQUIRED ) - endif (DARWIN) + endif (WINDOWS) target_link_libraries( ll::boost INTERFACE boost_context${sfx} boost_fiber${sfx} diff --git a/indra/cmake/CURL.cmake b/indra/cmake/CURL.cmake index c1ef0c3447..b85de3b845 100644 --- a/indra/cmake/CURL.cmake +++ b/indra/cmake/CURL.cmake @@ -27,7 +27,7 @@ use_prebuilt_binary(curl) ) endif (NOT ${curl_archs} STREQUAL ${CMAKE_OSX_ARCHITECTURES}) endif (DARWIN) -elseif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/curl_installed OR NOT ${curl_installed} EQUAL 0) +elseif (CMAKE_SYSTEM_NAME MATCHES FreeBSD AND (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/curl_installed OR NOT ${curl_installed} EQUAL 0)) if (NOT EXISTS ${CMAKE_BINARY_DIR}/3p-curl-7.54.1-r1.tar.gz) file(DOWNLOAD https://github.com/secondlife/3p-curl/archive/refs/tags/v7.54.1-r1.tar.gz @@ -89,7 +89,7 @@ elseif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRA ) file(WRITE ${PREBUILD_TRACKING_DIR}/curl_installed "${curl_installed}") endif (DARWIN OR LINUX OR NOT USESYSTEMLIBS) -if (WINDOWS) +if (WINDOWS AND NOT USESYSTEMLIBS) target_link_libraries(ll::libcurl INTERFACE ${ARCH_PREBUILT_DIRS_RELEASE}/libcurl.lib ll::openssl diff --git a/indra/cmake/LLPrimitive.cmake b/indra/cmake/LLPrimitive.cmake index e491eb2e32..39c07e3377 100644 --- a/indra/cmake/LLPrimitive.cmake +++ b/indra/cmake/LLPrimitive.cmake @@ -19,112 +19,117 @@ if( USE_CONAN ) endif() if( USESYSTEMLIBS ) - if( LINUX OR CMAKE_SYSTEM_NAME MATCHES FreeBSD) + if( WINDOWS ) + include(FindPkgConfig) + pkg_check_modules(Colladadom REQUIRED collada-dom-141) + target_compile_definitions( ll::colladadom INTERFACE COLLADA_DOM_SUPPORT141 ) + target_include_directories( ll::colladadom SYSTEM INTERFACE ${Colladadom_INCLUDE_DIRS} ) + target_link_directories( ll::colladadom INTERFACE ${Colladadom_LIBRARY_DIRS} ) + target_link_libraries( ll::colladadom INTERFACE ${Colladadom_LIBRARIES} ) + return () + elseif( LINUX OR CMAKE_SYSTEM_NAME MATCHES FreeBSD ) # Build of the collada-dom for Linux and FreeBSD is done in # indra/llprimitive/CMakeLists.txt return () - endif( LINUX OR CMAKE_SYSTEM_NAME MATCHES FreeBSD) - include(FindPkgConfig) - pkg_check_modules(Minizip REQUIRED minizip) - pkg_check_modules(Libxml2 REQUIRED libxml-2.0) - pkg_check_modules(Libpcrecpp libpcrecpp) - target_link_libraries( ll::minizip-ng INTERFACE ${Minizip_LIBRARIES} ) - target_link_libraries( ll::libxml INTERFACE ${Libxml2_LIBRARIES} ) - if ( ${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/colladadom_installed OR NOT ${colladadom_installed} EQUAL 0 ) - if (NOT EXISTS ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4.tar.gz) - file(DOWNLOAD - https://github.com/secondlife/3p-colladadom/archive/refs/tags/v2.3-r4.tar.gz - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4.tar.gz - ) - endif (NOT EXISTS ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4.tar.gz) - file(ARCHIVE_EXTRACT - INPUT ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4.tar.gz - DESTINATION ${CMAKE_BINARY_DIR} - ) - file(MAKE_DIRECTORY ${LIBS_PREBUILT_DIR}/include/collada/1.4) - if( DARWIN ) - try_compile(COLLADADOM_RESULT - PROJECT colladadom - SOURCE_DIR ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4 - BINARY_DIR ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4 - TARGET collada14dom - CMAKE_FLAGS - -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - -DCMAKE_CXX_FLAGS:STRING=-I${Minizip_INCLUDE_DIRS} - "-DCMAKE_SHARED_LINKER_FLAGS:STRING=-L${Minizip_LIBRARY_DIRS} -L${Minizip_LIBRARY_DIRS}exec/boost/1.81/lib" - -Dlibpcrecpp_LIBRARIES:STRING=pcrecpp - -DZLIB_LIBRARIES:STRING=${Libxml2_LIBRARIES} - -DBoost_FILESYSTEM_LIBRARY:STRING=boost_filesystem-mt - -DBoost_SYSTEM_LIBRARY:STRING=boost_system-mt - -Dlibpcrecpp_CFLAGS_OTHERS:STRING=-I${Libpcrecpp_INCLUDE_DIRS} - -DEXTRA_COMPILE_FLAGS:STRING=-I${Libxml2_INCLUDE_DIRS} - -DBoost_CFLAGS:STRING=-I${Libpcrecpp_LIBRARY_DIRS}exec/boost/1.81/include - -DOPT_COLLADA14:BOOL=ON - -DCOLLADA_DOM_INCLUDE_INSTALL_DIR:FILEPATH=${LIBS_PREBUILT_DIR}/include/collada - -DCOLLADA_DOM_SOVERSION:STRING=0 - -DCOLLADA_DOM_VERSION:STRING=2.3-r4 - -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHITECTURES} - -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=10.15 - OUTPUT_VARIABLE colladadom_installed - ) - if (${COLLADADOM_RESULT}) - file( - COPY - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src/1.4/libcollada14dom.2.3-r4.dylib - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src/1.4/libcollada14dom.0.dylib - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src/1.4/libcollada14dom.dylib - DESTINATION ${LIBS_PREBUILT_DIR}/lib/release - FOLLOW_SYMLINK_CHAIN + else( WINDOWS ) + include(FindPkgConfig) + pkg_check_modules(Minizip REQUIRED minizip) + pkg_check_modules(Libxml2 REQUIRED libxml-2.0) + pkg_check_modules(Libpcrecpp libpcrecpp) + target_link_libraries( ll::minizip-ng INTERFACE ${Minizip_LIBRARIES} ) + target_link_libraries( ll::libxml INTERFACE ${Libxml2_LIBRARIES} ) + if( ${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/colladadom_installed OR NOT ${colladadom_installed} EQUAL 0 ) + if( NOT EXISTS ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4.tar.gz ) + file(DOWNLOAD + https://github.com/secondlife/3p-colladadom/archive/refs/tags/v2.3-r4.tar.gz + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4.tar.gz ) - endif (${COLLADADOM_RESULT}) - else( DARWIN ) - execute_process( - COMMAND sed -i "" -e "s/SHARED/STATIC/g" 1.4/CMakeLists.txt - WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src - ) - try_compile(COLLADADOM_RESULT - PROJECT colladadom - SOURCE_DIR ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4 - BINARY_DIR ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4 - TARGET collada14dom - CMAKE_FLAGS - -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - -DCMAKE_CXX_FLAGS:STRING=-I${Minizip_INCLUDE_DIRS} - -DCMAKE_SHARED_LINKER_FLAGS:STRING=-L${Minizip_LIBRARY_DIRS} - -Dlibpcrecpp_LIBRARIES:STRING=pcrecpp - -DZLIB_LIBRARIES:STRING=${Libxml2_LIBRARIES} - -DBoost_FILESYSTEM_LIBRARY:STRING=boost_filesystem - -DBoost_SYSTEM_LIBRARY:STRING=boost_system - -DEXTRA_COMPILE_FLAGS:STRING=-I${Libxml2_INCLUDE_DIRS} - -DBoost_CFLAGS:STRING=-I${Libpcrecpp_INCLUDE_DIRS} - -DOPT_COLLADA14:BOOL=ON - -DCOLLADA_DOM_INCLUDE_INSTALL_DIR:FILEPATH=${LIBS_PREBUILT_DIR}/include/collada - -DCOLLADA_DOM_SOVERSION:STRING=0 - -DCOLLADA_DOM_VERSION:STRING=2.3-r4 - OUTPUT_VARIABLE colladadom_installed + endif( NOT EXISTS ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4.tar.gz ) + file(ARCHIVE_EXTRACT + INPUT ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4.tar.gz + DESTINATION ${CMAKE_BINARY_DIR} ) - if (${COLLADADOM_RESULT}) + file(MAKE_DIRECTORY ${LIBS_PREBUILT_DIR}/include/collada/1.4) + if( DARWIN ) + try_compile(COLLADADOM_RESULT + PROJECT colladadom + SOURCE_DIR ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4 + BINARY_DIR ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4 + TARGET collada14dom + CMAKE_FLAGS + -DCMAKE_CXX_FLAGS:STRING=-I${Minizip_INCLUDE_DIRS} + "-DCMAKE_SHARED_LINKER_FLAGS:STRING=-L${Minizip_LIBRARY_DIRS} -L${Minizip_LIBRARY_DIRS}exec/boost/1.81/lib" + -Dlibpcrecpp_LIBRARIES:STRING=pcrecpp + -DZLIB_LIBRARIES:STRING=${Libxml2_LIBRARIES} + -DBoost_FILESYSTEM_LIBRARY:STRING=boost_filesystem-mt + -DBoost_SYSTEM_LIBRARY:STRING=boost_system-mt + -Dlibpcrecpp_CFLAGS_OTHERS:STRING=-I${Libpcrecpp_INCLUDE_DIRS} + -DEXTRA_COMPILE_FLAGS:STRING=-I${Libxml2_INCLUDE_DIRS} + -DBoost_CFLAGS:STRING=-I${Libpcrecpp_LIBRARY_DIRS}exec/boost/1.81/include + -DOPT_COLLADA14:BOOL=ON + -DCOLLADA_DOM_INCLUDE_INSTALL_DIR:FILEPATH=${LIBS_PREBUILT_DIR}/include/collada + -DCOLLADA_DOM_SOVERSION:STRING=0 + -DCOLLADA_DOM_VERSION:STRING=2.3-r4 + OUTPUT_VARIABLE colladadom_installed + ) + if( ${COLLADADOM_RESULT} ) + file( + COPY + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src/1.4/libcollada14dom.2.3-r4.dylib + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src/1.4/libcollada14dom.0.dylib + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src/1.4/libcollada14dom.dylib + DESTINATION ${LIBS_PREBUILT_DIR}/lib/release + FOLLOW_SYMLINK_CHAIN + ) + endif( ${COLLADADOM_RESULT} ) + else( DARWIN ) + execute_process( + COMMAND sed -i "" -e "s/SHARED/STATIC/g" 1.4/CMakeLists.txt + WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src + ) + try_compile(COLLADADOM_RESULT + PROJECT colladadom + SOURCE_DIR ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4 + BINARY_DIR ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4 + TARGET collada14dom + CMAKE_FLAGS + -DCMAKE_CXX_FLAGS:STRING=-I${Minizip_INCLUDE_DIRS} + -DCMAKE_SHARED_LINKER_FLAGS:STRING=-L${Minizip_LIBRARY_DIRS} + -Dlibpcrecpp_LIBRARIES:STRING=pcrecpp + -DZLIB_LIBRARIES:STRING=${Libxml2_LIBRARIES} + -DBoost_FILESYSTEM_LIBRARY:STRING=boost_filesystem + -DBoost_SYSTEM_LIBRARY:STRING=boost_system + -Dlibpcrecpp_CFLAGS_OTHERS:STRING=-I${Libpcrecpp_INCLUDE_DIRS} + -DEXTRA_COMPILE_FLAGS:STRING=-I${Libxml2_INCLUDE_DIRS} + -DOPT_COLLADA14:BOOL=ON + -DCOLLADA_DOM_INCLUDE_INSTALL_DIR:FILEPATH=${LIBS_PREBUILT_DIR}/include/collada + -DCOLLADA_DOM_SOVERSION:STRING=0 + -DCOLLADA_DOM_VERSION:STRING=2.3-r4 + OUTPUT_VARIABLE colladadom_installed + ) + if( ${COLLADADOM_RESULT} ) + file( + COPY ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src/1.4/libcollada14dom.a + DESTINATION ${LIBS_PREBUILT_DIR}/lib/release + ) + endif( ${COLLADADOM_RESULT} ) + endif( DARWIN ) + if( ${COLLADADOM_RESULT} ) + file(REMOVE_RECURSE ${LIBS_PREBUILT_DIR}/include/collada/1.4) file( - COPY ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/src/1.4/libcollada14dom.a - DESTINATION ${LIBS_PREBUILT_DIR}/lib/release + COPY + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/1.4 + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/1.5 + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/dae + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/dae.h + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/dom.h + ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/modules + DESTINATION ${LIBS_PREBUILT_DIR}/include/collada ) - endif (${COLLADADOM_RESULT}) - endif( DARWIN ) - if (${COLLADADOM_RESULT}) - file(REMOVE_RECURSE ${LIBS_PREBUILT_DIR}/include/collada/1.4) - file( - COPY - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/1.4 - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/1.5 - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/dae - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/dae.h - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/dom.h - ${CMAKE_BINARY_DIR}/3p-colladadom-2.3-r4/include/modules - DESTINATION ${LIBS_PREBUILT_DIR}/include/collada - ) - file(WRITE ${PREBUILD_TRACKING_DIR}/colladadom_installed "${colladadom_installed}") - endif (${COLLADADOM_RESULT}) - endif( ${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/colladadom_installed OR NOT ${colladadom_installed} EQUAL 0 ) + file(WRITE ${PREBUILD_TRACKING_DIR}/colladadom_installed "${colladadom_installed}") + endif( ${COLLADADOM_RESULT} ) + endif( ${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/colladadom_installed OR NOT ${colladadom_installed} EQUAL 0 ) + endif( WINDOWS ) else( USESYSTEMLIBS ) use_system_binary( colladadom ) diff --git a/indra/cmake/LLWindow.cmake b/indra/cmake/LLWindow.cmake index 383051a4a6..31907d31df 100644 --- a/indra/cmake/LLWindow.cmake +++ b/indra/cmake/LLWindow.cmake @@ -7,7 +7,7 @@ include(Prebuilt) include_guard() add_library( ll::SDL INTERFACE IMPORTED ) -if (USESYSTEMLIBS AND NOT DARWIN) +if (USESYSTEMLIBS AND NOT (WINDOWS OR DARWIN)) include(FindPkgConfig) pkg_check_modules(Sdl2 REQUIRED sdl2) target_compile_definitions( ll::SDL INTERFACE LL_SDL=1) diff --git a/indra/cmake/Meshoptimizer.cmake b/indra/cmake/Meshoptimizer.cmake index 0dc4069431..e1bfe10e93 100644 --- a/indra/cmake/Meshoptimizer.cmake +++ b/indra/cmake/Meshoptimizer.cmake @@ -8,72 +8,49 @@ add_library( ll::meshoptimizer INTERFACE IMPORTED ) if (NOT USESYSTEMLIBS) use_system_binary(meshoptimizer) -else (NOT USESYSTEMLIBS) - if (NOT (${LINUX_DISTRO} MATCHES fedora OR (${LINUX_DISTRO} MATCHES opensuse-tumbleweed) OR DARWIN)) - find_package(meshoptimizer) - target_link_libraries( ll::meshoptimizer INTERFACE meshoptimizer) - endif (NOT (${LINUX_DISTRO} MATCHES fedora OR (${LINUX_DISTRO} MATCHES opensuse-tumbleweed) OR DARWIN)) +elseif (${LINUX_DISTRO} MATCHES debian OR (${LINUX_DISTRO} MATCHES ubuntu) OR CMAKE_SYSTEM_NAME MATCHES FreeBSD) + find_package(meshoptimizer) + target_link_libraries( ll::meshoptimizer INTERFACE meshoptimizer) + return () endif (NOT USESYSTEMLIBS) -if (${LINUX_DISTRO} MATCHES fedora OR (${LINUX_DISTRO} MATCHES opensuse-tumbleweed) OR DARWIN OR NOT USESYSTEMLIBS) - if (USESYSTEMLIBS) - if (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/meshoptimizer_installed OR NOT ${meshoptimizer_installed} EQUAL 0) - if (NOT EXISTS ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz) - file(DOWNLOAD - https://github.com/zeux/meshoptimizer/archive/refs/tags/v0.21.tar.gz - ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz - ) - endif (NOT EXISTS ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz) - file(ARCHIVE_EXTRACT - INPUT ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz - DESTINATION ${CMAKE_BINARY_DIR} - ) - if (DARWIN) - try_compile(MESHOPTIMIZER_RESULT - PROJECT meshoptimizer - SOURCE_DIR ${CMAKE_BINARY_DIR}/meshoptimizer-0.21 - BINARY_DIR ${CMAKE_BINARY_DIR}/meshoptimizer-0.21 - TARGET meshoptimizer - CMAKE_FLAGS - -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHITECTURES} - -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=10.15 - OUTPUT_VARIABLE meshoptimizer_installed - ) - else (DARWIN) - try_compile(MESHOPTIMIZER_RESULT - PROJECT meshoptimizer - SOURCE_DIR ${CMAKE_BINARY_DIR}/meshoptimizer-0.21 - BINARY_DIR ${CMAKE_BINARY_DIR}/meshoptimizer-0.21 - TARGET meshoptimizer - CMAKE_FLAGS - -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - OUTPUT_VARIABLE meshoptimizer_installed - ) - endif (DARWIN) - if (${MESHOPTIMIZER_RESULT}) - file( - COPY ${CMAKE_BINARY_DIR}/meshoptimizer-0.21/src/meshoptimizer.h - DESTINATION ${LIBS_PREBUILT_DIR}/include/meshoptimizer - ) - file( - COPY ${CMAKE_BINARY_DIR}/meshoptimizer-0.21/libmeshoptimizer.a - DESTINATION ${LIBS_PREBUILT_DIR}/lib/release - ) - file(WRITE ${PREBUILD_TRACKING_DIR}/meshoptimizer_installed "0") - endif (${MESHOPTIMIZER_RESULT}) - endif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/meshoptimizer_installed OR NOT ${meshoptimizer_installed} EQUAL 0) - else (USESYSTEMLIBS) +if (LINUX OR NOT USESYSTEMLIBS) use_prebuilt_binary(meshoptimizer) - endif (USESYSTEMLIBS) +elseif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/meshoptimizer_installed OR NOT ${meshoptimizer_installed} EQUAL 0) + if (NOT EXISTS ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz) + file(DOWNLOAD + https://github.com/zeux/meshoptimizer/archive/refs/tags/v0.21.tar.gz + ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz + ) + endif (NOT EXISTS ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz) + file(ARCHIVE_EXTRACT + INPUT ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz + DESTINATION ${CMAKE_BINARY_DIR} + ) + try_compile(MESHOPTIMIZER_RESULT + PROJECT meshoptimizer + SOURCE_DIR ${CMAKE_BINARY_DIR}/meshoptimizer-0.21 + BINARY_DIR ${CMAKE_BINARY_DIR}/meshoptimizer-0.21 + TARGET meshoptimizer + OUTPUT_VARIABLE meshoptimizer_installed + ) + if (${MESHOPTIMIZER_RESULT}) + file( + COPY ${CMAKE_BINARY_DIR}/meshoptimizer-0.21/src/meshoptimizer.h + DESTINATION ${LIBS_PREBUILT_DIR}/include/meshoptimizer + ) + file( + COPY ${CMAKE_BINARY_DIR}/meshoptimizer-0.21/libmeshoptimizer.a + DESTINATION ${LIBS_PREBUILT_DIR}/lib/release + ) + file(WRITE ${PREBUILD_TRACKING_DIR}/meshoptimizer_installed "${meshoptimizer_installed}") + endif (${MESHOPTIMIZER_RESULT}) +endif (LINUX OR NOT USESYSTEMLIBS) -if (WINDOWS) +if (NOT USESYSTEMLIBS AND WINDOWS) target_link_libraries( ll::meshoptimizer INTERFACE meshoptimizer.lib) -elseif (LINUX) +else (NOT USESYSTEMLIBS AND WINDOWS) target_link_libraries( ll::meshoptimizer INTERFACE libmeshoptimizer.a) -elseif (DARWIN) - target_link_libraries( ll::meshoptimizer INTERFACE libmeshoptimizer.a) -endif (WINDOWS) +endif (NOT USESYSTEMLIBS AND WINDOWS) target_include_directories( ll::meshoptimizer SYSTEM INTERFACE ${LIBS_PREBUILT_DIR}/include/meshoptimizer) -endif (${LINUX_DISTRO} MATCHES fedora OR (${LINUX_DISTRO} MATCHES opensuse-tumbleweed) OR DARWIN OR NOT USESYSTEMLIBS) diff --git a/indra/cmake/NDOF.cmake b/indra/cmake/NDOF.cmake index 1bf6c5086c..b75bb2509d 100644 --- a/indra/cmake/NDOF.cmake +++ b/indra/cmake/NDOF.cmake @@ -8,8 +8,9 @@ add_library( ll::ndof INTERFACE IMPORTED ) if (NDOF) if (WINDOWS OR DARWIN) - if (USESYSTEMLIBS) - if (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/libndofdev_installed OR NOT ${libndofdev_installed} EQUAL 0) + if (NOT USESYSTEMLIBS) + use_prebuilt_binary(libndofdev) + elseif (DARWIN AND (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/libndofdev_installed OR NOT ${libndofdev_installed} EQUAL 0)) file(DOWNLOAD https://github.com/secondlife/3p-libndofdev/archive/refs/tags/v0.1.8e9edc7.tar.gz ${CMAKE_BINARY_DIR}/3p-libndofdev-0.1.8e9edc7.tar.gz @@ -23,11 +24,7 @@ if (NDOF) SOURCE_DIR ${CMAKE_BINARY_DIR}/3p-libndofdev-0.1.8e9edc7/libndofdev BINARY_DIR ${CMAKE_BINARY_DIR}/3p-libndofdev-0.1.8e9edc7/libndofdev TARGET ndofdev - CMAKE_FLAGS - -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHITECTURES} - -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=10.15 - -DCMAKE_C_FLAGS:STRING=-DTARGET_OS_MAC\ -Wno-int-conversion + CMAKE_FLAGS -DCMAKE_C_FLAGS:STRING=-DTARGET_OS_MAC\ -Wno-int-conversion OUTPUT_VARIABLE libndofdev_installed ) if (${LIBNDOFDEV_RESULT}) @@ -39,12 +36,9 @@ if (NDOF) COPY ${CMAKE_BINARY_DIR}/3p-libndofdev-0.1.8e9edc7/libndofdev/src/libndofdev.dylib DESTINATION ${LIBS_PREBUILT_DIR}/lib/release ) - file(WRITE ${PREBUILD_TRACKING_DIR}/libndofdev_installed "0") + file(WRITE ${PREBUILD_TRACKING_DIR}/libndofdev_installed "${libndofdev_installed}") endif (${LIBNDOFDEV_RESULT}) - endif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/libndofdev_installed OR NOT ${libndofdev_installed} EQUAL 0) - else (USESYSTEMLIBS) - use_prebuilt_binary(libndofdev) - endif (USESYSTEMLIBS) + endif (NOT USESYSTEMLIBS) elseif (LINUX) use_prebuilt_binary(open-libndofdev) endif (WINDOWS OR DARWIN) diff --git a/indra/cmake/OpenJPEG.cmake b/indra/cmake/OpenJPEG.cmake index b1f776ad1d..463e4365ce 100644 --- a/indra/cmake/OpenJPEG.cmake +++ b/indra/cmake/OpenJPEG.cmake @@ -7,65 +7,47 @@ add_library( ll::openjpeg INTERFACE IMPORTED ) if (NOT USESYSTEMLIBS) use_system_binary(openjpeg) endif (NOT USESYSTEMLIBS) -if (USESYSTEMLIBS AND NOT LINUX) - if (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/openjpeg_installed OR NOT ${openjpeg_installed} EQUAL 0) - if (NOT EXISTS ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248.tar.gz) - file(DOWNLOAD - https://github.com/secondlife/3p-openjpeg/archive/refs/tags/v2.5.0.ea12248.tar.gz - ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248.tar.gz - ) - endif (NOT EXISTS ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248.tar.gz) - file(ARCHIVE_EXTRACT - INPUT ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248.tar.gz - DESTINATION ${CMAKE_BINARY_DIR} - ) - if (DARWIN) - try_compile(OPENJPEG_RESULT - PROJECT OPENJPEG - SOURCE_DIR ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg - BINARY_DIR ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg - TARGET openjp2 - CMAKE_FLAGS - -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - -DBUILD_SHARED_LIBS:BOOL=OFF - -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHITECTURES} - -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=10.15 - OUTPUT_VARIABLE openjpeg_installed - ) - else (DARWIN) - try_compile(OPENJPEG_RESULT - PROJECT OPENJPEG - SOURCE_DIR ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg - BINARY_DIR ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg - TARGET openjp2 - CMAKE_FLAGS - -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - -DBUILD_SHARED_LIBS:BOOL=OFF - -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=ON - OUTPUT_VARIABLE openjpeg_installed - ) - endif (DARWIN) - if (${OPENJPEG_RESULT}) - file( - COPY - ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/cio.h - ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/event.h - ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/openjpeg.h - ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/opj_config.h - ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/opj_config_private.h - ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/opj_stdint.h - DESTINATION ${LIBS_PREBUILT_DIR}/include/openjpeg - ) - file( - COPY ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/bin/libopenjp2.a - DESTINATION ${LIBS_PREBUILT_DIR}/lib/release - ) - file(WRITE ${PREBUILD_TRACKING_DIR}/openjpeg_installed "${openjpeg_installed}") - endif (${OPENJPEG_RESULT}) - endif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/openjpeg_installed OR NOT ${openjpeg_installed} EQUAL 0) -else (USESYSTEMLIBS AND NOT LINUX) +if (LINUX OR NOT USESYSTEMLIBS) use_prebuilt_binary(openjpeg) -endif (USESYSTEMLIBS AND NOT LINUX) +elseif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/openjpeg_installed OR NOT ${openjpeg_installed} EQUAL 0) + if (NOT EXISTS ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248.tar.gz) + file(DOWNLOAD + https://github.com/secondlife/3p-openjpeg/archive/refs/tags/v2.5.0.ea12248.tar.gz + ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248.tar.gz + ) + endif (NOT EXISTS ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248.tar.gz) + file(ARCHIVE_EXTRACT + INPUT ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248.tar.gz + DESTINATION ${CMAKE_BINARY_DIR} + ) + try_compile(OPENJPEG_RESULT + PROJECT OPENJPEG + SOURCE_DIR ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg + BINARY_DIR ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg + TARGET openjp2 + CMAKE_FLAGS + -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS} + -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=ON + OUTPUT_VARIABLE openjpeg_installed + ) + if (${OPENJPEG_RESULT}) + file( + COPY + ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/cio.h + ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/event.h + ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/openjpeg.h + ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/opj_config.h + ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/opj_config_private.h + ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/src/lib/openjp2/opj_stdint.h + DESTINATION ${LIBS_PREBUILT_DIR}/include/openjpeg + ) + file( + COPY ${CMAKE_BINARY_DIR}/3p-openjpeg-2.5.0.ea12248/openjpeg/bin/libopenjp2.a + DESTINATION ${LIBS_PREBUILT_DIR}/lib/release + ) + file(WRITE ${PREBUILD_TRACKING_DIR}/openjpeg_installed "${openjpeg_installed}") + endif (${OPENJPEG_RESULT}) +endif (LINUX OR NOT USESYSTEMLIBS) target_link_libraries(ll::openjpeg INTERFACE openjp2 ) target_include_directories( ll::openjpeg SYSTEM INTERFACE ${LIBS_PREBUILT_DIR}/include) diff --git a/indra/cmake/OpenSSL.cmake b/indra/cmake/OpenSSL.cmake index 801850b7ab..c6481c89e9 100644 --- a/indra/cmake/OpenSSL.cmake +++ b/indra/cmake/OpenSSL.cmake @@ -42,7 +42,7 @@ use_prebuilt_binary(openssl) ) endif (NOT ${ssl_archs} STREQUAL ${CMAKE_OSX_ARCHITECTURES}) endif (DARWIN) -elseif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/openssl_installed OR NOT ${openssl_installed} EQUAL 0) +elseif (CMAKE_SYSTEM_NAME MATCHES FreeBSD AND (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/openssl_installed OR NOT ${openssl_installed} EQUAL 0)) if (NOT EXISTS ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w.tar.gz) file(DOWNLOAD https://github.com/openssl/openssl/archive/refs/tags/OpenSSL_1_1_1w.tar.gz @@ -55,135 +55,137 @@ elseif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRA ) execute_process( COMMAND ./config no-shared - WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w + WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w ) execute_process( COMMAND make -j${MAKE_JOBS} - WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w + WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w RESULT_VARIABLE openssl_installed ) file( COPY - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/aes.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/asn1.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/asn1_mac.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/asn1err.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/asn1t.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/async.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/asyncerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/bio.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/bioerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/blowfish.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/bn.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/bnerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/buffer.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/buffererr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/camellia.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/cast.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/cmac.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/cms.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/cmserr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/comp.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/comperr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/conf.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/conf_api.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/conferr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/crypto.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/cryptoerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ct.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/cterr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/des.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/dh.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/dherr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/dsa.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/dsaerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/dtls1.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/e_os2.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ebcdic.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ec.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ecdh.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ecdsa.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ecerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/engine.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/engineerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/err.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/evp.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/evperr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/hmac.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/idea.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/kdf.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/kdferr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/lhash.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/md2.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/md4.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/md5.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/mdc2.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/modes.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/obj_mac.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/objects.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/objectserr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ocsp.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ocsperr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/opensslconf.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/opensslv.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ossl_typ.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/pem.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/pem2.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/pemerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/pkcs12.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/pkcs12err.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/pkcs7.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/pkcs7err.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/rand.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/rand_drbg.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/randerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/rc2.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/rc4.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/rc5.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ripemd.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/rsa.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/rsaerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/safestack.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/seed.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/sha.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/srp.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/srtp.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ssl.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ssl2.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ssl3.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/sslerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/stack.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/store.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/storeerr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/symhacks.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/tls1.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ts.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/tserr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/txt_db.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/ui.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/uierr.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/whrlpool.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/x509.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/x509_vfy.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/x509err.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/x509v3.h - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/include/openssl/x509v3err.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/aes.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/asn1.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/asn1_mac.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/asn1err.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/asn1t.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/async.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/asyncerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/bio.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/bioerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/blowfish.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/bn.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/bnerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/buffer.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/buffererr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/camellia.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/cast.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/cmac.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/cms.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/cmserr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/comp.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/comperr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/conf.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/conf_api.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/conferr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/crypto.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/cryptoerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ct.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/cterr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/des.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/dh.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/dherr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/dsa.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/dsaerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/dtls1.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/e_os2.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ebcdic.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ec.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ecdh.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ecdsa.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ecerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/engine.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/engineerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/err.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/evp.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/evperr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/hmac.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/idea.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/kdf.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/kdferr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/lhash.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/md2.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/md4.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/md5.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/mdc2.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/modes.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/obj_mac.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/objects.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/objectserr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ocsp.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ocsperr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/opensslconf.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/opensslv.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ossl_typ.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/pem.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/pem2.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/pemerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/pkcs12.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/pkcs12err.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/pkcs7.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/pkcs7err.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/rand.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/rand_drbg.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/randerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/rc2.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/rc4.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/rc5.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ripemd.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/rsa.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/rsaerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/safestack.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/seed.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/sha.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/srp.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/srtp.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ssl.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ssl2.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ssl3.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/sslerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/stack.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/store.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/storeerr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/symhacks.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/tls1.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ts.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/tserr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/txt_db.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/ui.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/uierr.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/whrlpool.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/x509.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/x509_vfy.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/x509err.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/x509v3.h + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/include/openssl/x509v3err.h DESTINATION ${LIBS_PREBUILT_DIR}/include/openssl ) file( COPY - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/libcrypto.a - ${CMAKE_BINARY_DIR}/OpenSSL_1_1_1w/libssl.a + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/libcrypto.a + ${CMAKE_BINARY_DIR}/openssl-OpenSSL_1_1_1w/libssl.a DESTINATION ${LIBS_PREBUILT_DIR}/lib/release ) file(WRITE ${PREBUILD_TRACKING_DIR}/openssl_installed "${openssl_installed}") endif (DARWIN OR LINUX OR NOT USESYSTEMLIBS) -if (WINDOWS) +if (WINDOWS AND NOT USESYSTEMLIBS) target_link_libraries(ll::openssl INTERFACE ${ARCH_PREBUILT_DIRS_RELEASE}/libssl.lib ${ARCH_PREBUILT_DIRS_RELEASE}/libcrypto.lib Crypt32.lib) elseif (LINUX) target_link_libraries(ll::openssl INTERFACE ${ARCH_PREBUILT_DIRS_RELEASE}/libssl.a ${ARCH_PREBUILT_DIRS_RELEASE}/libcrypto.a dl) else() target_link_libraries(ll::openssl INTERFACE ssl crypto) -endif (WINDOWS) +endif (WINDOWS AND NOT USESYSTEMLIBS) +if (NOT (WINDOWS AND USESYSTEMLIBS)) target_include_directories( ll::openssl SYSTEM INTERFACE ${LIBS_PREBUILT_DIR}/include) +endif (NOT (WINDOWS AND USESYSTEMLIBS)) diff --git a/indra/cmake/ViewerMiscLibs.cmake b/indra/cmake/ViewerMiscLibs.cmake index 0a5191ff08..13f5ebf862 100644 --- a/indra/cmake/ViewerMiscLibs.cmake +++ b/indra/cmake/ViewerMiscLibs.cmake @@ -1,12 +1,12 @@ # -*- cmake -*- include(Prebuilt) -if (NOT DARWIN) +if (NOT (WINDOWS OR DARWIN)) add_library( ll::fontconfig INTERFACE IMPORTED ) find_package(Fontconfig REQUIRED) target_link_libraries( ll::fontconfig INTERFACE Fontconfig::Fontconfig ) -endif (NOT DARWIN) +endif (NOT (WINDOWS OR DARWIN)) if( USE_AUTOBUILD_3P ) use_prebuilt_binary(libhunspell) @@ -16,8 +16,8 @@ if (NOT USESYSTEMLIBS) use_prebuilt_binary(slvoice) endif (NOT USESYSTEMLIBS) -if ((${LINUX_DISTRO} MATCHES debian OR DARWIN) OR NOT USESYSTEMLIBS) +if ((${LINUX_DISTRO} MATCHES debian OR WINDOWS OR DARWIN) OR NOT USESYSTEMLIBS) use_prebuilt_binary(nanosvg) -endif ((${LINUX_DISTRO} MATCHES debian OR DARWIN) OR NOT USESYSTEMLIBS) +endif ((${LINUX_DISTRO} MATCHES debian OR WINDOWS OR DARWIN) OR NOT USESYSTEMLIBS) use_prebuilt_binary(viewer-fonts) use_prebuilt_binary(emoji_shortcodes) diff --git a/indra/cmake/WebRTC.cmake b/indra/cmake/WebRTC.cmake index 89ac794c89..eec4e2ce7a 100644 --- a/indra/cmake/WebRTC.cmake +++ b/indra/cmake/WebRTC.cmake @@ -8,7 +8,7 @@ add_library( ll::webrtc INTERFACE IMPORTED ) target_include_directories( ll::webrtc SYSTEM INTERFACE "${LIBS_PREBUILT_DIR}/include/webrtc" "${LIBS_PREBUILT_DIR}/include/webrtc/third_party/abseil-cpp") if (${LINUX_DISTRO} MATCHES debian OR CMAKE_OSX_ARCHITECTURES MATCHES x86_64) use_prebuilt_binary(webrtc) -elseif (NOT CMAKE_SYSTEM_NAME MATCHES FreeBSD) +elseif (NOT (WINDOWS OR CMAKE_SYSTEM_NAME MATCHES FreeBSD)) target_compile_definitions(ll::webrtc INTERFACE CM_WEBRTC=1) if (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/webrtc_installed OR NOT ${webrtc_installed} EQUAL 0) if (DARWIN) |