From f21a67c861d4898f1e3ebb131b16347b43bec39c Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 21 Jan 2023 03:04:52 +0000 Subject: media-libs/portsmf : import from gentoo, fix src_uri (pr submitted : https://github.com/gentoo/gentoo/pull/29196) --- media-libs/portsmf/portsmf-239-r1.ebuild | 41 ++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 media-libs/portsmf/portsmf-239-r1.ebuild (limited to 'media-libs/portsmf/portsmf-239-r1.ebuild') diff --git a/media-libs/portsmf/portsmf-239-r1.ebuild b/media-libs/portsmf/portsmf-239-r1.ebuild new file mode 100644 index 00000000..6cfd0c75 --- /dev/null +++ b/media-libs/portsmf/portsmf-239-r1.ebuild @@ -0,0 +1,41 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake + +DESCRIPTION="The Tenacity fork of PortSMF, a Standard MIDI File library" +HOMEPAGE="https://codeberg.org/tenacityteam/portsmf" +SRC_URI=" + https://codeberg.org/tenacityteam/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz +" +LICENSE="MIT" +SLOT="0/1" # SOVERSION in CMakeLists.txt / SONAME suffix +KEYWORDS="~amd64" +IUSE="test" +RESTRICT="!test? ( test )" + +S="${WORKDIR}/${PN}" + +PATCHES=( + "${FILESDIR}/${PN}"-239-revert-extern-to-static-change.patch + "${FILESDIR}/${PN}"-239-set-correct-cmake-project-ver.patch + "${FILESDIR}/${PN}"-239-set-correct-pkg-config-ver.patch +) + +src_configure() { + local mycmakeargs=( + -DBUILD_TESTING=$(usex test on off) + ## This is "Build example applications" according to upstream + #-DBUILD_APPS=$(usex examples on off) + # The above requires a non-existent PortMidiConfig.cmake. + ) + cmake_src_configure +} + +src_test() { + # Remove this function when bumping. Upstream HEAD has CTest. + cd "${BUILD_DIR}"/test || die + ./test