summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Scruggs <j.scruggs@gmail.com>2018-01-29 15:26:52 +0000
committerJonathan Scruggs <dracwyrm@gentoo.org>2018-01-30 20:59:39 +0000
commit65833f7dc77f342cfbd705d2548cc76f32de2d8e (patch)
treedc27f339244d3f1195a38e1f7a1681cb958391a7 /media-libs/opencollada/files
parentapp-emulation/free42: Bumps version to 2.0.12 (diff)
downloadgentoo-65833f7dc77f342cfbd705d2548cc76f32de2d8e.tar.gz
gentoo-65833f7dc77f342cfbd705d2548cc76f32de2d8e.tar.bz2
gentoo-65833f7dc77f342cfbd705d2548cc76f32de2d8e.zip
media-libs/opencollada: add 1.6.2 release
Closes: https://github.com/gentoo/gentoo/pull/6997
Diffstat (limited to 'media-libs/opencollada/files')
-rw-r--r--media-libs/opencollada/files/opencollada-1.6.62-cmake-fixes.patch122
1 files changed, 122 insertions, 0 deletions
diff --git a/media-libs/opencollada/files/opencollada-1.6.62-cmake-fixes.patch b/media-libs/opencollada/files/opencollada-1.6.62-cmake-fixes.patch
new file mode 100644
index 000000000000..8fc32784daa7
--- /dev/null
+++ b/media-libs/opencollada/files/opencollada-1.6.62-cmake-fixes.patch
@@ -0,0 +1,122 @@
+From c3ed65c2c60b8744163b3a57cf24469e688536dd Mon Sep 17 00:00:00 2001
+From: Jonathan Scruggs <j.scruggs@gmail.com>
+Date: Sat, 13 Jan 2018 11:54:44 +0000
+Subject: [PATCH] OpenCOLLADA/CMakeLists.txt
+
+Use CMAKE_BUILD_TYPE which can be overrided with custom distro types
+
+Adhere to GNU filesystem layout conventions. Not all distros and OSes
+have directories in the same locations and they define the
+GNUInstallDirs variables, so use those variables. Also, this enables
+multi lib installations.
+
+Define the version variables to enable SONAME versioning on the
+library files in case there is ABI changes in the future.
+---
+ CMakeLists.txt | 58 ++++++++++++++++++++++++++++++++++++----------------------
+ 1 file changed, 36 insertions(+), 22 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 95abbe21..00ad8d6a 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -37,14 +37,41 @@ cmake_policy(SET CMP0010 NEW)
+ # Input directories must have CMakeLists.txt
+ cmake_policy(SET CMP0014 NEW)
+
+-# avoid having empty buildtype
+-set(CMAKE_BUILD_TYPE_INIT "Release")
+
+-set(CMAKE_CONFIGURATION_TYPES "Debug;Release" CACHE STRING "Only do Release and Debug" FORCE )
+-mark_as_advanced(CMAKE_CONFIGURATION_TYPES)
++# Set Release type for builds where CMAKE_BUILD_TYPE is unset
++# This is usually a good default as this implictly enables
++#
++# CXXFLAGS = -O3 -DNDEBUG
++#
++if( NOT CMAKE_BUILD_TYPE )
++ set( CMAKE_BUILD_TYPE "Release" )
++endif()
+
+ SET(CMAKE_DEBUG_POSTFIX "" CACHE STRING "Add this string to as suffix to Debug libraries, e.g.: xml2_d.lib " )
+
++# Adhere to GNU filesystem layout conventions
++include( GNUInstallDirs )
++
++
++# #-----------------------------------------------------------------------------
++# Initialize project.
++
++project(OPENCOLLADA) # must be after setting cmake_configuration_types
++
++set(EXTERNAL_LIBRARIES ${OPENCOLLADA_SOURCE_DIR}/Externals) # external libraries
++set(CMAKE_MODULE_PATH "${EXTERNAL_LIBRARIES}/cmake-modules")
++
++set(OPENCOLLADA_VERSION_MAJOR 1)
++set(OPENCOLLADA_VERSION_MINOR 6)
++set(OPENCOLLADA_VERSION_PATCH 62)
++set(OPENCOLLADA_VERSION ${OPENCOLLADA_VERSION_MAJOR}.${OPENCOLLADA_VERSION_MINOR}.${OPENCOLLADA_VERSION_PATCH})
++
++if(NOT SOVERSION)
++ set(SOVERSION ${OPENCOLLADA_VERSION_MAJOR}.${OPENCOLLADA_VERSION_MINOR}
++ CACHE STRING "Set the SO version in the SO name of the output library")
++endif()
++
++
+ #-----------------------------------------------------------------------------
+ # Macro's
+
+@@ -58,7 +85,7 @@ macro(opencollada_add_lib
+
+ if (USE_STATIC)
+ add_library(${name}_static STATIC ${sources})
+- set_target_properties(${name}_static PROPERTIES OUTPUT_NAME ${name})
++ set_target_properties(${name}_static PROPERTIES OUTPUT_NAME ${name} SOVERSION ${SOVERSION})
+ foreach(target_lib ${target_libs})
+ if(TARGET ${target_lib}_static)
+ target_link_libraries(${name}_static ${target_lib}_static)
+@@ -84,7 +111,7 @@ macro(opencollada_add_lib
+ message(${name} " WARNING: Shared library support implemented for UNIX-like OS only")
+ endif ()
+ add_library(${name}_shared SHARED ${sources})
+- set_target_properties(${name}_shared PROPERTIES OUTPUT_NAME ${name})
++ set_target_properties(${name}_shared PROPERTIES OUTPUT_NAME ${name} SOVERSION ${SOVERSION})
+ foreach(target_lib ${target_libs})
+ if(TARGET ${target_lib}_shared)
+ target_link_libraries(${name}_shared ${target_lib}_shared)
+@@ -145,19 +172,6 @@ endmacro()
+ # end copy
+ # --------
+
+-#-----------------------------------------------------------------------------
+-# Initialize project.
+-
+-project(OPENCOLLADA) # must be after setting cmake_configuration_types
+-
+-set(EXTERNAL_LIBRARIES ${OPENCOLLADA_SOURCE_DIR}/Externals) # external libraries
+-set(CMAKE_MODULE_PATH "${EXTERNAL_LIBRARIES}/cmake-modules")
+-
+-set(OPENCOLLADA_VERSION_MAJOR 0)
+-set(OPENCOLLADA_VERSION_MINOR 1)
+-set(OPENCOLLADA_VERSION_PATCH 0)
+-set(OPENCOLLADA_VERSION ${OPENCOLLADA_VERSION_MAJOR}.${OPENCOLLADA_VERSION_MINOR}.${OPENCOLLADA_VERSION_PATCH})
+-
+
+ #-----------------------------------------------------------------------------
+ # Compiler warnings.
+@@ -190,9 +204,9 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CXX_WARNINGS}")
+ #-----------------------------------------------------------------------------
+ # Install vars
+
+-set(OPENCOLLADA_INST_INCLUDE ${CMAKE_INSTALL_PREFIX}/include/opencollada)
+-set(OPENCOLLADA_INST_LIBRARY ${CMAKE_INSTALL_PREFIX}/lib/opencollada)
+-set(OPENCOLLADA_INST_CMAKECONFIG ${OPENCOLLADA_INST_LIBRARY}/cmake)
++set(OPENCOLLADA_INST_INCLUDE ${CMAKE_INSTALL_FULL_INCLUDEDIR}/opencollada)
++set(OPENCOLLADA_INST_LIBRARY ${CMAKE_INSTALL_FULL_LIBDIR}/opencollada)
++set(OPENCOLLADA_INST_CMAKECONFIG ${CMAKE_INSTALL_FULL_LIBDIR}/cmake/OpenCOLLADA)
+
+
+ #-----------------------------------------------------------------------------
+--
+2.15.1
+