diff options
author | Nick Sarnie <sarnex@gentoo.org> | 2019-09-30 21:17:07 -0400 |
---|---|---|
committer | Nick Sarnie <sarnex@gentoo.org> | 2019-09-30 21:17:07 -0400 |
commit | 4463b7911974031618fab4157504436a2b64cc15 (patch) | |
tree | ef4189c99510d658ac7bcb0d6f4200309ff627c8 /app-emulation/faudio | |
parent | x11-misc/xmobar: drop underscores from IUSE, bug #695144 (diff) | |
download | gentoo-4463b7911974031618fab4157504436a2b64cc15.tar.gz gentoo-4463b7911974031618fab4157504436a2b64cc15.tar.bz2 gentoo-4463b7911974031618fab4157504436a2b64cc15.zip |
app-emulation/faudio: Sync with ::wine
Package-Manager: Portage-2.3.76, Repoman-2.3.17
Signed-off-by: Nick Sarnie <sarnex@gentoo.org>
Diffstat (limited to 'app-emulation/faudio')
-rw-r--r-- | app-emulation/faudio/Manifest | 1 | ||||
-rw-r--r-- | app-emulation/faudio/faudio-19.09.ebuild | 95 |
2 files changed, 96 insertions, 0 deletions
diff --git a/app-emulation/faudio/Manifest b/app-emulation/faudio/Manifest index 7fc3823eb2b7..443bc87e55e8 100644 --- a/app-emulation/faudio/Manifest +++ b/app-emulation/faudio/Manifest @@ -1 +1,2 @@ DIST FAudio-19.06.tar.gz 899089 BLAKE2B a59ad9613bcfa71e1fc8be1f2d389f56b8f96430c354b7c7148d1e1e084102b6d8559cd258f3ab6969a4ac93e55ea2397b18dc417857e9ee0f022ea0dae65c0e SHA512 ba3ee18b47d8d85dc39e777c420522349f9873cf1528dd6c266f7254fe27cdb5bb6ab5bcbeab870938b509bfd006590d2380908b7d1e3fd679d2a434ce82eca6 +DIST FAudio-19.09.tar.gz 901659 BLAKE2B 8bb99c67b6da2660e71c7a8a70f83130738a07e7f4ddd2001fb857c81a593935506a8c1fe6d24bfd064537ea4a5a603973c32d839228d7b3f45c9c300ba15147 SHA512 127f975c68e2b449fa7cadae0723925f35ca7a2841ea3fd85037febe964331de4b2e3031ab09c292ee5f40d90902dcf78c75cc3fe7fbe4d6f37a822b4d9eb966 diff --git a/app-emulation/faudio/faudio-19.09.ebuild b/app-emulation/faudio/faudio-19.09.ebuild new file mode 100644 index 000000000000..a8490f1cf230 --- /dev/null +++ b/app-emulation/faudio/faudio-19.09.ebuild @@ -0,0 +1,95 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# shellcheck disable=SC2034 +EAPI=7 + +CMAKE_MAKEFILE_GENERATOR="emake" + +inherit cmake-multilib virtualx + +FAUDIO_PN="FAudio" +FAUDIO_PV="${PV}" +FAUDIO_P="${FAUDIO_PN}-${FAUDIO_PV}" + +if [[ "${PV}" == "9999" ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/FNA-XNA/${FAUDIO_PN}.git" +else + SRC_URI="https://github.com/FNA-XNA/${FAUDIO_PN}/archive/${FAUDIO_PV}.tar.gz -> ${FAUDIO_P}.tar.gz" + KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd" + S="${WORKDIR}/${FAUDIO_P}" +fi + +DESCRIPTION="FAudio - Accuracy-focused XAudio reimplementation for open platforms" +HOMEPAGE="https://fna-xna.github.io/" +LICENSE="ZLIB" +SLOT="0" + +IUSE="+abi_x86_32 +abi_x86_64 debug ffmpeg xnasong test utils" +REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 )" + +COMMON_DEPEND=" + >=media-libs/libsdl2-2.0.9[sound,${MULTILIB_USEDEP}] + ffmpeg? ( media-video/ffmpeg:=[${MULTILIB_USEDEP}] ) +" +RDEPEND="${COMMON_DEPEND} +" +DEPEND="${COMMON_DEPEND} +" + +multilib_src_configure() { + local mycmakeargs=( + "-DCMAKE_INSTALL_BINDIR=bin" + "-DCMAKE_INSTALL_INCLUDEDIR=include/${FAUDIO_PN}" + "-DCMAKE_INSTALL_LIBDIR=$(get_libdir)" + "-DCMAKE_INSTALL_PREFIX=${EPREFIX%/}/usr" + "-DCMAKE_BUILD_TYPE=$(usex debug Debug Release)" + "-DFORCE_ENABLE_DEBUGCONFIGURATION=$(usex debug ON OFF)" + "-DBUILD_TESTS=$(usex test ON OFF)" + "-DBUILD_UTILS=$(usex utils ON OFF)" + "-DFFMPEG=$(usex ffmpeg ON OFF)" + "-DXNASONG=$(usex xnasong ON OFF)" + ) + if use ffmpeg; then + mycmakeargs+=( "-DFFmpeg_LIBRARY_DIRS=${EPREFIX%/}/usr/$(get_libdir)" ) + fi + cmake-utils_src_configure +} + +src_configure() { + cmake-multilib_src_configure +} + +multilib_src_compile() { + cmake-utils_src_make + emake -C "${BUILD_DIR}" all +} + +multilib_src_install() { + # FIXME: do we want to install the FAudio tools? + cmake-utils_src_install + + sed -e "s@%LIB%@$(get_libdir)@g" -e "s@%PREFIX%@${EPREFIX}/usr@g" \ + "${FILESDIR}/faudio.pc" > "${T}/faudio.pc" \ + || die "sed failed" + insinto "/usr/$(get_libdir)/pkgconfig" + doins "${T}/faudio.pc" + + if use test; then + mkdir -p "${T}/$(get_libdir)" + cp "${BUILD_DIR}/faudio_tests" "${T}/$(get_libdir)/" || die "cp failed" + fi +} + +faudio_test() { + XDG_RUNTIME_DIR="/run/user/0" virtx "${T}/$(get_libdir)/faudio_tests" +} + +pkg_postinst() { + use test || return + + # FIXME: FAudio tests are broken and also don't appear to work + # in the Portage sandbox. + multilib_foreach_abi faudio_test +} |