SHA256
1
0
forked from pool/tvision
tvision/Use-GNUInstallDirs.patch
Julius Enriquez 47a7819ea0 Accepting request 1175942 from home:win8linux
- Change gpm to a BuildRequires 
- Changed patch to be compatible with osc
- Use correct library paths
- Add updated tarball 
- Add patch to use GNUInstallDirs for CMake 
- Split devel into devel and devel-static, put static lib in devel-static
- Move requires and suggests to subpackages

OBS-URL: https://build.opensuse.org/request/show/1175942
OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/tvision?expand=0&rev=4
2024-05-22 19:51:18 +00:00

54 lines
1.7 KiB
Diff

diff -ruN a/CMakeLists.txt b/CMakeLists.txt
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -149,6 +149,8 @@
option(TV_BUILD_AVSCOLOR "Build AviSynth TermColor plugin" OFF)
+include(GNUInstallDirs)
+
tv_message_mp(STATUS "Install path: ${CMAKE_INSTALL_PREFIX}")
tv_message(STATUS "Build Examples: ${TV_BUILD_EXAMPLES}")
if (MAY_BUILD_USING_GPM)
diff -ruN a/examples/CMakeLists.txt b/examples/CMakeLists.txt
--- a/examples/CMakeLists.txt
+++ b/examples/CMakeLists.txt
@@ -25,7 +25,7 @@
# Until CMake 3.13, 'install' only accepts targets defined
# in the current directory. So install from this function.
if (${app} IN_LIST TVINSTALLAPPS)
- install(TARGETS ${app} RUNTIME DESTINATION bin)
+ install(TARGETS ${app} RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
endif()
endfunction()
diff -ruN a/source/CMakeLists.txt b/source/CMakeLists.txt
--- a/source/CMakeLists.txt
+++ b/source/CMakeLists.txt
@@ -153,14 +153,14 @@
#
install(TARGETS ${PROJECT_NAME}
EXPORT ${PROJECT_NAME}-config
- ARCHIVE DESTINATION lib
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
COMPONENT library
)
# package configuration
install(EXPORT ${PROJECT_NAME}-config
- DESTINATION lib/cmake/${PROJECT_NAME}
+ DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}
NAMESPACE ${PROJECT_NAME}::
FILE ${PROJECT_NAME}-config.cmake
COMPONENT library
@@ -169,7 +169,7 @@
# includes
# ./include/tvision and children copied to destination/include/tvision etc...
#
-install(DIRECTORY "${PROJECT_SOURCE_DIR}/include/tvision" DESTINATION include)
+install(DIRECTORY "${PROJECT_SOURCE_DIR}/include/tvision" DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
# Build optimization