diff options
| -rw-r--r-- | indra/cmake/OpenJPEG.cmake | 70 | ||||
| -rw-r--r-- | indra/llimagej2coj/llimagej2coj.cpp | 2 | ||||
| -rw-r--r-- | indra/newview/licenses-linux.txt | 44 |
3 files changed, 6 insertions, 110 deletions
diff --git a/indra/cmake/OpenJPEG.cmake b/indra/cmake/OpenJPEG.cmake index 125f32e711..fbe028a199 100644 --- a/indra/cmake/OpenJPEG.cmake +++ b/indra/cmake/OpenJPEG.cmake @@ -6,70 +6,10 @@ include(Linking) add_library( ll::openjpeg INTERFACE IMPORTED ) -#use_system_binary(openjpeg) -#use_prebuilt_binary(openjpeg) +include(FindPkgConfig) +pkg_check_modules(Openjpeg REQUIRED libopenjp2) +target_include_directories(ll::openjpeg SYSTEM INTERFACE ${Openjpeg_INCLUDE_DIRS}) +target_link_directories(ll::openjpeg INTERFACE ${Openjpeg_LIBRARY_DIRS}) +target_link_libraries(ll::openjpeg INTERFACE ${Openjpeg_LIBRARIES}) -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}/openjpeg-2.5.3.tar.gz) - file(DOWNLOAD - https://github.com/uclouvain/openjpeg/archive/refs/tags/v2.5.3.tar.gz - ${CMAKE_BINARY_DIR}/openjpeg-2.5.3.tar.gz - ) - endif () - file(ARCHIVE_EXTRACT - INPUT ${CMAKE_BINARY_DIR}/openjpeg-2.5.3.tar.gz - DESTINATION ${CMAKE_BINARY_DIR} - ) - - if (${LINUX_DISTRO} MATCHES ubuntu) - try_compile(OPENJPEG_RESULT - PROJECT OPENJPEG - SOURCE_DIR ${CMAKE_BINARY_DIR}/openjpeg-2.5.3 - BINARY_DIR ${CMAKE_BINARY_DIR}/openjpeg-2.5.3 - TARGET openjp2 - CMAKE_FLAGS - -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} - -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHITECTURES} - -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=${CMAKE_OSX_DEPLOYMENT_TARGET} - -DCMAKE_INSTALL_PREFIX:PATH=${LIBS_PREBUILT_DIR} - -DCMAKE_INSTALL_LIBDIR:PATH=${ARCH_PREBUILT_DIRS_RELEASE} - -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=ON - -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS} - -DBUILD_CODEC:BOOL=OFF - ) - if (${OPENJPEG_RESULT}) - execute_process( - COMMAND ${CMAKE_MAKE_PROGRAM} install - WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/openjpeg-2.5.3 - OUTPUT_VARIABLE openjpeg_installed - ) - endif () - - else () - execute_process( - COMMAND ${CMAKE_COMMAND} -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHITECTURES} -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=${CMAKE_OSX_DEPLOYMENT_TARGET} -DCMAKE_INSTALL_PREFIX:PATH=${LIBS_PREBUILT_DIR} -DCMAKE_INSTALL_LIBDIR:PATH=${ARCH_PREBUILT_DIRS_RELEASE} -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=ON -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS} -DBUILD_CODEC:BOOL=OFF - WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/openjpeg-2.5.3 - OUTPUT_VARIABLE openjpeg_installed - ) - endif () - - file( - COPY - ${CMAKE_BINARY_DIR}/openjpeg-2.5.3/src/lib/openjp2/cio.h - ${CMAKE_BINARY_DIR}/openjpeg-2.5.3/src/lib/openjp2/event.h - ${CMAKE_BINARY_DIR}/openjpeg-2.5.3/src/lib/openjp2/opj_config_private.h - DESTINATION ${LIBS_PREBUILT_DIR}/include/openjpeg-2.5 - ) - file(WRITE ${PREBUILD_TRACKING_DIR}/openjpeg_installed "${openjpeg_installed}") -endif () - -if (${LINUX_DISTRO} MATCHES ubuntu) -target_link_libraries(ll::openjpeg INTERFACE openjp2 ) -else () - include(FindPkgConfig) - pkg_check_modules(Openjpeg REQUIRED libopenjp2) - target_include_directories(ll::openjpeg SYSTEM INTERFACE ${Openjpeg_INCLUDE_DIRS}) - target_link_directories(ll::openjpeg INTERFACE ${Openjpeg_LIBRARY_DIRS}) - target_link_libraries(ll::openjpeg INTERFACE ${Openjpeg_LIBRARIES}) -endif () target_include_directories( ll::openjpeg SYSTEM INTERFACE ${LIBS_PREBUILT_DIR}/include) diff --git a/indra/llimagej2coj/llimagej2coj.cpp b/indra/llimagej2coj/llimagej2coj.cpp index 9350901324..7cfadb889d 100644 --- a/indra/llimagej2coj/llimagej2coj.cpp +++ b/indra/llimagej2coj/llimagej2coj.cpp @@ -28,7 +28,7 @@ #include "llimagej2coj.h" // this is defined so that we get static linking. -#include <openjpeg-2.5/openjpeg.h> +#include "openjpeg.h" // Factory function: see declaration in llimagej2c.cpp LLImageJ2CImpl* fallbackCreateLLImageJ2CImpl() diff --git a/indra/newview/licenses-linux.txt b/indra/newview/licenses-linux.txt index e83989b4a7..d443bd3385 100644 --- a/indra/newview/licenses-linux.txt +++ b/indra/newview/licenses-linux.txt @@ -196,50 +196,6 @@ Redistribution and use in source and binary forms, with or Cass Everitt - cass@r3.nu -================ -OpenJPEG License -================ - -/* - * The copyright in this software is being made available under the 2-clauses - * BSD License, included below. This software may be subject to other third - * party and contributor rights, including patent rights, and no such rights - * are granted under this license. - * - * Copyright (c) 2002-2014, Universite catholique de Louvain (UCL), Belgium - * Copyright (c) 2002-2014, Professor Benoit Macq - * Copyright (c) 2003-2014, Antonin Descampe - * Copyright (c) 2003-2009, Francois-Olivier Devaux - * Copyright (c) 2005, Herve Drolon, FreeImage Team - * Copyright (c) 2002-2003, Yannick Verschueren - * Copyright (c) 2001-2003, David Janssens - * Copyright (c) 2011-2012, Centre National d'Etudes Spatiales (CNES), France - * Copyright (c) 2012, CS Systemes d'Information, France - * - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS `AS IS' - * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE - * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF - * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN - * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - */ - =============== OpenSSL License |
