diff options
author | Rafael Rondão <rafael.rondao@gmail.com> | 2023-06-14 10:57:39 -0300 |
---|---|---|
committer | Rafael Rondão <rafael.rondao@gmail.com> | 2023-06-14 10:58:02 -0300 |
commit | 0c4b910ebf0ed46f97ae5150d17587810c3ed246 (patch) | |
tree | 4c226fd936d9ed128c0a2b0e3d89b641e1ec23fa /games-emulation/RetroArch | |
parent | dev-util/upstream-ontologist: new package, add 0.1.35 (diff) | |
download | guru-0c4b910ebf0ed46f97ae5150d17587810c3ed246.tar.gz guru-0c4b910ebf0ed46f97ae5150d17587810c3ed246.tar.bz2 guru-0c4b910ebf0ed46f97ae5150d17587810c3ed246.zip |
games-emulation/RetroArch: new package, add 1.15.0
Signed-off-by: Rafael Rondão <rafael.rondao@gmail.com>
Diffstat (limited to 'games-emulation/RetroArch')
-rw-r--r-- | games-emulation/RetroArch/Manifest | 1 | ||||
-rw-r--r-- | games-emulation/RetroArch/RetroArch-1.15.0.ebuild | 178 | ||||
-rw-r--r-- | games-emulation/RetroArch/metadata.xml | 48 |
3 files changed, 227 insertions, 0 deletions
diff --git a/games-emulation/RetroArch/Manifest b/games-emulation/RetroArch/Manifest new file mode 100644 index 000000000..2372962b2 --- /dev/null +++ b/games-emulation/RetroArch/Manifest @@ -0,0 +1 @@ +DIST RetroArch-1.15.0.tar.gz 49206179 BLAKE2B 0361051780f72646a4cb4fc18a6a534beeff3ccdf55a85b1ae803808ff49dca0516fe5aa2ced8b3e1ad2968fc4484ba65e3f999fccf86c714a32aec122d9091d SHA512 8981bfa58a4b44befad8dd00a160c2e00ac4a023567f9c31a45707f687afa51c50ac42120685d25039ff305d31e06f9e3e40d47ba7f1800885c2619182b6ab5a diff --git a/games-emulation/RetroArch/RetroArch-1.15.0.ebuild b/games-emulation/RetroArch/RetroArch-1.15.0.ebuild new file mode 100644 index 000000000..9b75acf87 --- /dev/null +++ b/games-emulation/RetroArch/RetroArch-1.15.0.ebuild @@ -0,0 +1,178 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit flag-o-matic + +DESCRIPTION="RetroArch is a frontend for emulators, game engines and media players" +HOMEPAGE="https://www.retroarch.com" + +SRC_URI="https://github.com/libretro/RetroArch/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64" + +IUSE="7zip alsa cg cpu_flags_arm_neon cpu_flags_arm_vfp cpu_flags_x86_sse2 cheevos debug dispmanx +egl filters ffmpeg gles2 gles3 hid jack kms libass libusb materialui network openal +opengl osmesa oss +ozone +pulseaudio +rgui sdl sdl2 +truetype +threads udev v4l2 videocore vulkan wayland +X xinerama xmb xv zlib" + +REQUIRED_USE=" + || ( alsa jack openal oss pulseaudio ) + || ( opengl sdl sdl2 vulkan dispmanx ) + || ( kms X wayland videocore ) + || ( materialui ozone rgui xmb ) + alsa? ( threads ) + arm? ( gles2? ( egl ) ) + !arm? ( + egl? ( opengl ) + gles2? ( opengl ) + ) + cg? ( opengl ) + dispmanx? ( videocore arm ) + gles2? ( !cg ) + gles3? ( gles2 ) + kms? ( egl ) + libass? ( ffmpeg ) + libusb? ( hid ) + sdl? ( rgui ) + sdl2? ( rgui !sdl ) + videocore? ( arm ) + vulkan? ( amd64 ) + wayland? ( egl ) + xinerama? ( X ) + xv? ( X ) +" + +RDEPEND=" + alsa? ( media-libs/alsa-lib:0= ) + cg? ( media-gfx/nvidia-cg-toolkit:0= ) + arm? ( dispmanx? ( || ( media-libs/raspberrypi-userland:0 media-libs/raspberrypi-userland-bin:0 ) ) ) + ffmpeg? ( >=media-video/ffmpeg-2.1.3:0= ) + jack? ( virtual/jack:= ) + libass? ( media-libs/libass:0= ) + libusb? ( virtual/libusb:1= ) + openal? ( media-libs/openal:0= ) + opengl? ( media-libs/mesa:0=[gles2?] ) + osmesa? ( media-libs/mesa:0=[osmesa?] ) + pulseaudio? ( media-sound/pulseaudio:0= ) + sdl? ( >=media-libs/libsdl-1.2.10:0=[joystick] ) + sdl2? ( media-libs/libsdl2:0=[joystick] ) + truetype? ( media-libs/freetype:2= ) + udev? ( virtual/udev:0= + X? ( x11-drivers/xf86-input-evdev:0= ) + ) + amd64? ( vulkan? ( media-libs/vulkan-loader:0= ) ) + v4l2? ( media-libs/libv4l:0= ) + wayland? ( media-libs/mesa:0=[wayland?] ) + X? ( + x11-base/xorg-server:0= + >=x11-libs/libxkbcommon-0.4.0:0= + ) + xinerama? ( x11-libs/libXinerama:0= ) + xv? ( x11-libs/libXv:0= ) + zlib? ( sys-libs/zlib:0= ) +" + +DEPEND="${RDEPEND} + virtual/pkgconfig +" + +src_configure() { + if use cg; then + append-ldflags -L"${EPREFIX}/"opt/nvidia-cg-toolkit/$(get_libdir) + append-cflags -I"${EPREFIX}/"opt/nvidia-cg-toolkit/include + fi + + # Absolute path of the directory containing Retroarch shared libraries. + export RETROARCH_LIB_DIR="${EPREFIX}/usr/$(get_libdir)/retroarch" + + if use filters; then + # Replace stock defaults with Gentoo-specific defaults. + sed -i retroarch.cfg \ + -e 's:# \(video_filter_dir =\):\1 "/'${RETROARCH_LIB_DIR}'/filters/video/":' \ + -e 's:# \(audio_filter_dir =\):\1 "/'${RETROARCH_LIB_DIR}'/filters/audio/":' \ + || die '"sed" failed.' + fi + + # Note that OpenVG support is hard-disabled. (See ${RDEPEND} above.) + ./configure \ + --prefix=/usr \ + --enable-dynamic \ + --disable-vg \ + $(use_enable 7zip) \ + $(use_enable alsa) \ + $(use_enable cheevos) \ + $(use_enable cg) \ + $(use_enable cpu_flags_arm_neon neon) \ + $(use_enable cpu_flags_arm_vfp floathard) \ + $(use_enable cpu_flags_x86_sse2 sse) \ + $(use_enable dispmanx) \ + $(use_enable egl) \ + $(use_enable ffmpeg) \ + $(use_enable gles2 opengles) \ + $(use_enable gles3 opengles3) \ + $(use_enable hid) \ + $(use_enable jack) \ + $(use_enable kms) \ + $(use_enable libass ssa) \ + $(use_enable libusb) \ + $(use_enable materialui) \ + $(use_enable network networking) \ + $(use_enable openal al) \ + $(use_enable opengl) \ + $(use_enable osmesa) \ + $(use_enable oss) \ + $(use_enable ozone) \ + $(use_enable pulseaudio pulse) \ + $(use_enable rgui) \ + $(use_enable sdl) \ + $(use_enable sdl2) \ + $(use_enable threads) \ + $(use_enable truetype freetype) \ + $(use_enable udev) \ + $(use_enable v4l2) \ + $(use_enable videocore) \ + $(use_enable vulkan) \ + $(use_enable wayland) \ + $(use_enable X x11) \ + $(use_enable xinerama) \ + $(use_enable xmb) \ + $(use_enable xv xvideo) \ + $(use_enable zlib) +} + +src_compile() { + emake $(usex debug "DEBUG=1" "") + if use filters; then + emake $(usex debug "build=debug" "build=release") -C gfx/video_filters/ + emake $(usex debug "build=debug" "build=release") -C libretro-common/audio/dsp_filters/ + fi +} + +src_install() { + # Install core files and directories. + emake DESTDIR="${ED}" install + + # Install documentation. + dodoc README.md + + if use filters; then + # Install video filters. + insinto ${RETROARCH_LIB_DIR}/filters/video/ + doins "${S}"/gfx/video_filters/*.so + doins "${S}"/gfx/video_filters/*.filt + + # Install audio filters. + insinto ${RETROARCH_LIB_DIR}/filters/audio/ + doins "${S}"/libretro-common/audio/dsp_filters/*.dsp + fi +} + +pkg_postinst() { + if use oss; then + ewarn "" + ewarn "OSS support is enabled, however it is not installed as a dependency." + ewarn "Make sure you have OSS installed in your system." + ewarn "" + fi +} diff --git a/games-emulation/RetroArch/metadata.xml b/games-emulation/RetroArch/metadata.xml new file mode 100644 index 000000000..ca1afbfb2 --- /dev/null +++ b/games-emulation/RetroArch/metadata.xml @@ -0,0 +1,48 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <use> + <flag name="7zip">Compile in 7z support</flag> + <flag name="alsa">ALSA support</flag> + <flag name="cg">Cg shader support</flag> + <flag name="cheevos">Retro Achievements</flag> + <flag name="debug">Enable a debug build</flag> + <flag name="dispmanx">Dispmanx video support</flag> + <flag name="egl">EGL context support</flag> + <flag name="filters">Install audio/video filters</flag> + <flag name="ffmpeg">FFmpeg support</flag> + <flag name="gles2">Use GLESv2 instead of desktop GL</flag> + <flag name="gles3">OpenGLES3 support</flag> + <flag name="hid">Low-level HID (Human Interface Device) support</flag> + <flag name="jack">JACK support</flag> + <flag name="kms">KMS context support</flag> + <flag name="libass">SSA/ASS for FFmpeg subtitle support</flag> + <flag name="libusb">Libusb HID support</flag> + <flag name="materialui">MaterialUI menu</flag> + <flag name="network">Networking features (recommended)</flag> + <flag name="openal">OpenAL support</flag> + <flag name="opengl">OpenGL 2.0 support</flag> + <flag name="osmesa">Off-screen Mesa rendering</flag> + <flag name="oss">OSS support</flag> + <flag name="ozone">Ozone menu</flag> + <flag name="pulseaudio">PulseAudio support</flag> + <flag name="rgui">RGUI menu</flag> + <flag name="sdl">SDL support</flag> + <flag name="sdl2">SDL2 support (disables SDL 1.x)</flag> + <flag name="truetype">FreeType support</flag> + <flag name="threads">Threading support</flag> + <flag name="udev">Udev/Evdev gamepad support</flag> + <flag name="v4l2">Video4linux2 support</flag> + <flag name="videocore">Broadcom Videocore 4 support</flag> + <flag name="vulkan">Vulkan support</flag> + <flag name="wayland">Wayland support</flag> + <flag name="X">Everything X11</flag> + <flag name="xinerama">Xinerama support</flag> + <flag name="xmb">XMB menu</flag> + <flag name="xv">XVideo support</flag> + <flag name="zlib">zlib support (ZIP extract, PNG decoding/encoding)</flag> + </use> + <upstream> + <remote-id type="github">libretro/RetroArch</remote-id> + </upstream> +</pkgmetadata> |