diff options
author | V3n3RiX <venerix@koprulu.sector> | 2023-01-20 23:41:21 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2023-01-20 23:41:21 +0000 |
commit | 374561aeaff53ce5a2836af934749923b4ea3763 (patch) | |
tree | 66880cb44879bf28002f361a4c862814df616b8f /media-sound/audacity/files | |
parent | ea0515fa73da4755b498bdb18bd7fd7a13e616cf (diff) |
gentoo auto-resync : 20:01:2023 - 23:41:20
Diffstat (limited to 'media-sound/audacity/files')
5 files changed, 307 insertions, 0 deletions
diff --git a/media-sound/audacity/files/audacity-3.2.3-allow-finding-rapidjson-pkgconfig.patch b/media-sound/audacity/files/audacity-3.2.3-allow-finding-rapidjson-pkgconfig.patch new file mode 100644 index 000000000000..d36f51bc2098 --- /dev/null +++ b/media-sound/audacity/files/audacity-3.2.3-allow-finding-rapidjson-pkgconfig.patch @@ -0,0 +1,24 @@ +From 0a786020046c9d608f1e2f463575d4ca8febf909 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Arsen=20Arsenovi=C4=87?= <arsen@aarsen.me> +Date: Sun, 18 Dec 2022 13:41:06 +0100 +Subject: [PATCH 3/3] Add pkg-config fallback for RapidJSON + +--- + cmake-proxies/CMakeLists.txt | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/cmake-proxies/CMakeLists.txt b/cmake-proxies/CMakeLists.txt +index 7568bb32f..db40dcf63 100644 +--- a/cmake-proxies/CMakeLists.txt ++++ b/cmake-proxies/CMakeLists.txt +@@ -289,6 +289,7 @@ if( ${_OPT}has_sentry_reporting OR ${_OPT}has_audiocom_upload ) + RapidJSON + rapidjson/1.1.0 + REQUIRED ++ PKG_CONFIG "RapidJSON" + ) + endif() + +-- +2.39.0 + diff --git a/media-sound/audacity/files/audacity-3.2.3-allow-overriding-alsa-jack.patch b/media-sound/audacity/files/audacity-3.2.3-allow-overriding-alsa-jack.patch new file mode 100644 index 000000000000..53ac8edc33fb --- /dev/null +++ b/media-sound/audacity/files/audacity-3.2.3-allow-overriding-alsa-jack.patch @@ -0,0 +1,48 @@ +From e46dbcb9763f4367705c66009703f15ff0ff5558 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Arsen=20Arsenovi=C4=87?= <arsen@aarsen.me> +Date: Sat, 17 Dec 2022 21:13:56 +0100 +Subject: [PATCH] portmixer: Allow overriding PA_HAS_{ALSA,JACK} + +Not included for OSS as OSS is always included AFAICT. +--- + CMakeLists.txt | 3 +++ + lib-src/portmixer/CMakeLists.txt | 9 ++++++--- + 2 files changed, 9 insertions(+), 3 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 42e765691..c18a939e6 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -624,6 +624,9 @@ cmd_option( ${_OPT}use_portmixer "Build PortMixer support into Audacity" On) + if( ${_OPT}use_portmixer ) + set(USE_PORTMIXER Yes) + add_subdirectory( "lib-src/portmixer" ) ++else() ++ # Suppress bogus warnings about unused variables ++ set (unusedIgnore "${PA_HAS_ALSA}${PA_HAS_JACK}${PA_HAS_OSS}") + endif() + + cmd_option( ${_OPT}use_nyquist "Build Nyquist support into Audacity" On) +diff --git a/lib-src/portmixer/CMakeLists.txt b/lib-src/portmixer/CMakeLists.txt +index 65a384fa0..1ddc8ed50 100644 +--- a/lib-src/portmixer/CMakeLists.txt ++++ b/lib-src/portmixer/CMakeLists.txt +@@ -8,9 +8,12 @@ if (UNIX AND NOT APPLE) + include(CheckIncludeFile) + set(CMAKE_REQUIRED_LIBRARIES PortAudio::PortAudio) + +- check_include_file( "pa_jack.h" PA_HAS_JACK ) +- +- check_include_file( "pa_linux_alsa.h" PA_HAS_ALSA ) ++ if ( NOT DEFINED PA_HAS_JACK ) ++ check_include_file( "pa_jack.h" PA_HAS_JACK ) ++ endif() ++ if ( NOT DEFINED PA_HAS_ALSA ) ++ check_include_file( "pa_linux_alsa.h" PA_HAS_ALSA ) ++ endif() + if( PA_HAS_ALSA ) + find_package( ALSA REQUIRED QUIET ) + endif() +-- +2.39.0 + diff --git a/media-sound/audacity/files/audacity-3.2.3-disable-ccache.patch b/media-sound/audacity/files/audacity-3.2.3-disable-ccache.patch new file mode 100644 index 000000000000..a40847bb941c --- /dev/null +++ b/media-sound/audacity/files/audacity-3.2.3-disable-ccache.patch @@ -0,0 +1,33 @@ +From afd777fbcbaa9e9c14b80374c60ecd631eb537ea Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Arsen=20Arsenovi=C4=87?= <arsen@aarsen.me> +Date: Fri, 16 Dec 2022 23:37:36 +0100 +Subject: [PATCH] Don't force enable ccache + +--- +Analogous to the similar patches in prior versions. + +CMakeLists.txt | 8 -------- + 1 file changed, 8 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 9c1c7baf2..42e765691 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -142,14 +142,6 @@ set( CMAKE_PREFIX_PATH + set( CMAKE_CXX_STANDARD 17 ) + set( CMAKE_CXX_STANDARD_REQUIRED ON ) + +-# Use ccache if available +-find_program( CCACHE_PROGRAM ccache ) +-mark_as_advanced( FORCE CCACHE_PROGRAM ) +- +-if( CCACHE_PROGRAM ) +- set_property( GLOBAL PROPERTY RULE_LAUNCH_COMPILE "${CCACHE_PROGRAM}" ) +-endif() +- + # Define option() prefix + set( _OPT "audacity_" ) + +-- +2.39.0 + diff --git a/media-sound/audacity/files/audacity-3.2.3-fix-rpaths.patch b/media-sound/audacity/files/audacity-3.2.3-fix-rpaths.patch new file mode 100644 index 000000000000..2f1578211c9c --- /dev/null +++ b/media-sound/audacity/files/audacity-3.2.3-fix-rpaths.patch @@ -0,0 +1,144 @@ +From: Benjamin Drung <benjamin.drung@canonical.com> +Date: Thu, 22 Sep 2022 19:52:43 +0200 +Subject: Fix rpath for private libraries on Linux + +Installing audacity on Linux will produce private libraries that have +`RUNPATH` set to the build directory instead of the installation +directory. + +The root cause is that the library directory is copied to the +installation directory without touching the libraries. The cmake wiki +says in RPATH handling caveats [1]: "Since install-side RPATH tweaking +is an operation that is done by target-specific installation handling, +any target that should have its install RPATH changed (e.g. to +`CMAKE_INSTALL_RPATH`) needs to end up in the installation via an +`install(TARGETS ...)` signature and not via directory-based copying." + +So replace `install(DIRECTORY ...)` by individual `install(TARGETS ...)` +for the libraries and modules. Then cmake will replace the `RUNPATH` to +`$ORIGIN/../lib/audacity`, which is still incorrect. Therefore set +`INSTALL_RPATH` explicitly. + +Fixes: https://github.com/audacity/audacity/issues/3289 +Forwarded: https://github.com/audacity/audacity/pull/3671 +[1] https://gitlab.kitware.com/cmake/community/-/wikis/doc/cmake/RPATH-handling#caveats +Signed-off-by: Benjamin Drung <benjamin.drung@canonical.com> +--- + CMakeLists.txt | 1 + + cmake-proxies/cmake-modules/AudacityFunctions.cmake | 19 +++++++++++++++++++ + modules/CMakeLists.txt | 7 ------- + modules/mod-script-pipe/CMakeLists.txt | 1 + + src/CMakeLists.txt | 10 ---------- + 5 files changed, 21 insertions(+), 17 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 8428c8c..b9ff631 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -389,6 +389,7 @@ set( INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}" ) + set( _LIBDIR "${CMAKE_INSTALL_LIBDIR}" ) + set( _DATADIR "${CMAKE_INSTALL_DATADIR}" ) + set( _PKGLIB "${_LIBDIR}/audacity" ) ++set( _PKGMODULE "${_PKGLIB}/modules" ) + set( _PKGDATA "${_DATADIR}/audacity/" ) + set( _MANDIR "${CMAKE_INSTALL_MANDIR}" ) + set( _MODDIR "${_DEST}/modules" ) +diff --git a/cmake-proxies/cmake-modules/AudacityFunctions.cmake b/cmake-proxies/cmake-modules/AudacityFunctions.cmake +index 47682eb..a8f144f 100644 +--- a/cmake-proxies/cmake-modules/AudacityFunctions.cmake ++++ b/cmake-proxies/cmake-modules/AudacityFunctions.cmake +@@ -338,6 +338,17 @@ function( canonicalize_node_name var node ) + set( "${var}" "${node}" PARENT_SCOPE ) + endfunction() + ++# Call install(TARGETS...) only on Linux systems (i.e. exclude MacOS and Windows) ++macro( install_target_linux target destination ) ++ if( NOT "${CMAKE_GENERATOR}" MATCHES "Xcode|Visual Studio*" AND NOT CMAKE_SYSTEM_NAME MATCHES "Darwin" ) ++ install( TARGETS "${target}" DESTINATION "${destination}" ) ++ endif() ++endmacro() ++ ++macro( install_audacity_module target ) ++ install_target_linux( "${target}" "${_PKGMODULE}" ) ++endmacro() ++ + function( audacity_module_fn NAME SOURCES IMPORT_TARGETS + ADDITIONAL_DEFINES ADDITIONAL_LIBRARIES LIBTYPE ) + +@@ -382,6 +393,7 @@ function( audacity_module_fn NAME SOURCES IMPORT_TARGETS + PROPERTIES + PREFIX "" + FOLDER "modules" # for IDE organization ++ INSTALL_RPATH "$ORIGIN/.." + ) + if( CMAKE_HOST_SYSTEM_NAME MATCHES "Darwin" ) + add_custom_command( +@@ -423,6 +435,7 @@ function( audacity_module_fn NAME SOURCES IMPORT_TARGETS + PREFIX "" + FOLDER "libraries" # for IDE organization + INSTALL_NAME_DIR "" ++ INSTALL_RPATH "$ORIGIN" + BUILD_WITH_INSTALL_NAME_DIR YES + ) + endif() +@@ -525,6 +538,12 @@ function( audacity_module_fn NAME SOURCES IMPORT_TARGETS + endforeach() + set( GRAPH_EDGES "${GRAPH_EDGES}" PARENT_SCOPE ) + ++ # Note: Some modules set EXCLUDE_FROM_ALL afterwards to not be installed. ++ # Therefore only install libraries, but not modules here. ++ if( NOT REAL_LIBTYPE STREQUAL "MODULE" ) ++ install_target_linux( "${TARGET}" "${_PKGLIB}" ) ++ endif() ++ + # collect unit test targets if they are present + if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/tests") + add_subdirectory(tests) +diff --git a/modules/CMakeLists.txt b/modules/CMakeLists.txt +index d464383..15dead4 100644 +--- a/modules/CMakeLists.txt ++++ b/modules/CMakeLists.txt +@@ -16,12 +16,5 @@ foreach( MODULE ${MODULES} ) + add_subdirectory("${MODULE}") + endforeach() + +-if( NOT CMAKE_SYSTEM_NAME MATCHES "Darwin" ) +- if( NOT "${CMAKE_GENERATOR}" MATCHES "Visual Studio*") +- install( DIRECTORY "${_DEST}/modules" +- DESTINATION "${_PKGLIB}" ) +- endif() +-endif() +- + #propagate collected edges up to root CMakeLists.txt + set( GRAPH_EDGES "${GRAPH_EDGES}" PARENT_SCOPE ) +diff --git a/modules/mod-script-pipe/CMakeLists.txt b/modules/mod-script-pipe/CMakeLists.txt +index 5ee1862..ccfd50f 100644 +--- a/modules/mod-script-pipe/CMakeLists.txt ++++ b/modules/mod-script-pipe/CMakeLists.txt +@@ -15,3 +15,4 @@ set( DEFINES + ) + audacity_module( mod-script-pipe "${SOURCES}" "Audacity" + "${DEFINES}" "" ) ++install_audacity_module( mod-script-pipe ) +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index 7b90c1b..c5f30ad 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -1621,17 +1621,7 @@ else() + DESTINATION "." + RESOURCE DESTINATION "${_APPDIR}/Resources" ) + else() +- + install( TARGETS ${TARGET} RUNTIME ) +- +- install( DIRECTORY "${_DEST}/${_LIBDIR}/" +- DESTINATION "${_LIBDIR}" +- USE_SOURCE_PERMISSIONS +- FILES_MATCHING PATTERN "*.so*" ) +- +- install( CODE "set( _LIBDIR \"${_LIBDIR}\")" ) +- install( SCRIPT "${CMAKE_SOURCE_DIR}/scripts/build/linux/fix_rpath.cmake" ) +- + install( FILES "${_INTDIR}/audacity.desktop" + DESTINATION "${_DATADIR}/applications" ) + install( FILES "${topdir}/LICENSE.txt" "${topdir}/README.txt" diff --git a/media-sound/audacity/files/audacity-3.2.3-remove-conan-threadpool.patch b/media-sound/audacity/files/audacity-3.2.3-remove-conan-threadpool.patch new file mode 100644 index 000000000000..1940ec8a6d9f --- /dev/null +++ b/media-sound/audacity/files/audacity-3.2.3-remove-conan-threadpool.patch @@ -0,0 +1,58 @@ +From 7b5f56ec441fb472b61bae14e1efa353db4d7aca Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Arsen=20Arsenovi=C4=87?= <arsen@aarsen.me> +Date: Sun, 18 Dec 2022 13:37:35 +0100 +Subject: [PATCH] Allow using local dependency for threadpool + +We pull it in manually. +--- + cmake-proxies/CMakeLists.txt | 27 +++++++++++++++++++-------- + 1 file changed, 19 insertions(+), 8 deletions(-) + +diff --git a/cmake-proxies/CMakeLists.txt b/cmake-proxies/CMakeLists.txt +index 81bbf2efd..474814f07 100644 +--- a/cmake-proxies/CMakeLists.txt ++++ b/cmake-proxies/CMakeLists.txt +@@ -258,12 +258,22 @@ if( ${_OPT}has_networking ) + set ( curl_ssl "openssl" ) + endif () + +- add_conan_lib( +- ThreadPool +- threadpool/20140926 +- REQUIRED +- ALWAYS_ALLOW_CONAN_FALLBACK +- ) ++ if ( ${_OPT}has_threadpool STREQUAL "local" ) ++ # Gentoo: Hack in Portage-downloaded ThreadPool.h. ++ # This follows somewhat-like-upstream conventions, except it doesn't use ++ # the proxy library mechanism because there's no library. ++ add_library ( ThreadPool::ThreadPool INTERFACE IMPORTED GLOBAL ) ++ target_include_directories ( ThreadPool::ThreadPool INTERFACE ++ ${CMAKE_SOURCE_DIR}/lib-src/threadpool ++ ) ++ else() ++ add_conan_lib( ++ ThreadPool ++ threadpool/20140926 ++ REQUIRED ++ ALWAYS_ALLOW_CONAN_FALLBACK ++ ) ++ endif() + + add_conan_lib( + CURL +@@ -276,8 +286,9 @@ if( ${_OPT}has_networking ) + CONAN_OPTIONS + libcurl:with_ssl=${curl_ssl} + libcurl:shared=True +- ) +- ++ ) ++else() ++ set(unused "${${_OPT}has_threadpool}") + endif() + + if( NOT CMAKE_SYSTEM_NAME MATCHES "Darwin|Windows") +-- +2.39.0 + |