summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2023-04-29 06:38:49 +0100
committerSam James <sam@gentoo.org>2023-04-29 06:45:45 +0100
commit7f9196dacbbfcfbfcb3744d13f0ff41e2a9b32c1 (patch)
tree2d3c29e6efcb748286020b32f487f5232aeff4d1
parentmedia-libs/portmidi: add github upstream metadata (diff)
downloadgentoo-7f9196da.tar.gz
gentoo-7f9196da.tar.bz2
gentoo-7f9196da.zip
media-libs/portmidi: add 2.0.4
Switch to new repo on github (linked to from sourceforge). This is _not_ the Tenacity fork. Drop Java support as it's deprecated upstream. Note that this compares lower than 236 (2.0.4 < 236) but this is a newer version; 234 will be renamed to 0.234 to reflect this. Bug: https://bugs.gentoo.org/810577 Closes: https://bugs.gentoo.org/735170 Closes: https://bugs.gentoo.org/874084 Signed-off-by: Sam James <sam@gentoo.org>
-rw-r--r--media-libs/portmidi/Manifest1
-rw-r--r--media-libs/portmidi/files/portmidi-2.0.4-cmake.patch11
-rw-r--r--media-libs/portmidi/portmidi-2.0.4.ebuild82
3 files changed, 94 insertions, 0 deletions
diff --git a/media-libs/portmidi/Manifest b/media-libs/portmidi/Manifest
index 8bf9b5aa5743..a6b2822dfb2c 100644
--- a/media-libs/portmidi/Manifest
+++ b/media-libs/portmidi/Manifest
@@ -1 +1,2 @@
DIST portmedia-code-r234.zip 1342298 BLAKE2B 3c3686b79ca0c8cbfaa6c44ae8c4f294630e1c5940576709ff1ca5854bfcfba1af7b067471656f2b39ae28cecea9b6c4403f72d5a2552355760c795eff123243 SHA512 cbc332d89bc465450b38245a83cc300dfd2e1e6de7c62284edf754ff4d8a9aa3dc49a395dcee535ed9688befb019186fa87fd6d8a3698898c2acbf3e6b7a0794
+DIST portmidi-2.0.4.tar.gz 263225 BLAKE2B fd8b002880ccfcff9f233e2fa5021fe4cf9da2f91b3ceaa36fe70f96818e174578f9a14b69bdbb58fab777c9a9e4ff939b86814a403860c7ec264dddc6f26e85 SHA512 d9f22d161e1dd9a4bde1971bb2b6e5352da51545f4fe5ecad11c55e7a535f0d88efce18d1c8fd91e93b70a7926150f86a0f53972ad92370e86556a8dd72dc194
diff --git a/media-libs/portmidi/files/portmidi-2.0.4-cmake.patch b/media-libs/portmidi/files/portmidi-2.0.4-cmake.patch
new file mode 100644
index 000000000000..ff0257ec64e5
--- /dev/null
+++ b/media-libs/portmidi/files/portmidi-2.0.4-cmake.patch
@@ -0,0 +1,11 @@
+--- a/pm_test/CMakeLists.txt
++++ b/pm_test/CMakeLists.txt
+@@ -6,6 +6,8 @@ if(APPLE)
+ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR})
+ endif(APPLE)
+
++set(CMAKE_SKIP_BUILD_RPATH TRUE)
++
+ # if(WIN32)
+ # if(NOT BUILD_SHARED_LIBS)
+ # /MDd is multithread debug DLL, /MTd is multithread debug
diff --git a/media-libs/portmidi/portmidi-2.0.4.ebuild b/media-libs/portmidi/portmidi-2.0.4.ebuild
new file mode 100644
index 000000000000..215e567b9bf8
--- /dev/null
+++ b/media-libs/portmidi/portmidi-2.0.4.ebuild
@@ -0,0 +1,82 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake xdg
+
+DESCRIPTION="Library for real time MIDI input and output"
+HOMEPAGE="https://github.com/PortMidi/portmidi"
+SRC_URI="https://github.com/PortMidi/portmidi/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
+IUSE="debug doc test-programs"
+# Per pm-test/README:
+# "Because device numbers depend on the system, there is no automated
+# script to run all tests on PortMidi."
+RESTRICT="test"
+
+RDEPEND="
+ media-libs/alsa-lib
+"
+DEPEND="
+ ${DEPEND}
+"
+BDEPEND="
+ app-arch/unzip
+ doc? (
+ app-doc/doxygen
+ dev-texlive/texlive-fontsrecommended
+ dev-texlive/texlive-latexextra
+ virtual/latex-base
+ )
+"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-2.0.4-cmake.patch
+)
+
+src_configure() {
+ if use debug ; then
+ CMAKE_BUILD_TYPE=Debug
+ else
+ CMAKE_BUILD_TYPE=Release
+ fi
+
+ # Python bindings dropped b/c of bug #855077
+ local mycmakeargs=(
+ -DBUILD_PORTMIDI_TESTS=$(usex test-programs)
+ )
+
+ cmake_src_configure
+}
+
+src_compile() {
+ cmake_src_compile
+
+ if use doc ; then
+ doxygen || die "doxygen failed"
+
+ pushd latex > /dev/null || die
+ VARTEXFONTS="${T}"/fonts emake
+ popd > /dev/null || die
+ fi
+}
+
+src_install() {
+ cmake_src_install
+
+ dodoc CHANGELOG.txt README.txt pm_linux/README_LINUX.txt
+
+ use doc && dodoc latex/refman.pdf
+
+ if use test-programs ; then
+ exeinto /usr/$(get_libdir)/${PN}
+ local app
+ for app in latency midiclock midithread midithru mm qtest sysex ; do
+ doexe "${BUILD_DIR}"/pm_test/${app}
+ done
+ fi
+}