2015-11-14 14:51:27 +01:00
|
|
|
# Created by: Yuri Victorovich <yuri@rawbw.com>
|
|
|
|
# $FreeBSD$
|
|
|
|
|
|
|
|
PORTNAME= RetroArch
|
2016-08-23 13:14:37 +02:00
|
|
|
PORTVERSION= 1.3.6
|
2015-11-14 14:51:27 +01:00
|
|
|
DISTVERSIONPREFIX= v
|
2019-08-06 01:06:50 +02:00
|
|
|
PORTREVISION= 17
|
2015-11-14 14:51:27 +01:00
|
|
|
CATEGORIES= games
|
|
|
|
|
2018-02-25 01:40:37 +01:00
|
|
|
MAINTAINER= yuri@FreeBSD.org
|
2015-11-14 14:51:27 +01:00
|
|
|
COMMENT= Cross-platform entertainment system based on libretro API
|
|
|
|
|
|
|
|
LICENSE= GPLv3
|
|
|
|
LICENSE_FILE= ${WRKSRC}/COPYING
|
|
|
|
|
2016-04-01 16:00:51 +02:00
|
|
|
LIB_DEPENDS= libxkbcommon.so:x11/libxkbcommon \
|
2016-07-13 20:38:47 +02:00
|
|
|
libdrm.so:graphics/libdrm \
|
|
|
|
libass.so:multimedia/libass
|
2015-11-14 14:51:27 +01:00
|
|
|
|
2017-05-22 15:17:38 +02:00
|
|
|
BROKEN_powerpc64= fails to compile: features_cpu.c: undefined reference to __mftb
|
|
|
|
|
2015-11-14 14:51:27 +01:00
|
|
|
OPTIONS_DEFINE= FFMPEG OSS JACK PULSEAUDIO ALSA SDL OPENGL OPENAL NETPLAY PYTHON V4L FREETYPE FBO
|
2018-06-15 16:18:44 +02:00
|
|
|
OPTIONS_DEFAULT=OSS PULSEAUDIO SDL OPENGL OPENAL NETPLAY PYTHON V4L FREETYPE FBO # FFMPEG
|
2015-11-14 14:51:27 +01:00
|
|
|
FFMPEG_DESC= On-the-fly recording of gameplay with libavcodec
|
|
|
|
NETPLAY_DESC= Peer-to-peer netplay
|
|
|
|
PYTHON_DESC= Script support in shaders
|
|
|
|
FBO_DESC= OpenGL render-to-texture
|
|
|
|
|
2018-05-02 17:07:27 +02:00
|
|
|
FFMPEG_BROKEN= fails to build with ffmpeg 4.0
|
2016-04-01 16:00:51 +02:00
|
|
|
FFMPEG_LIB_DEPENDS= libavcodec.so:multimedia/ffmpeg
|
2015-11-14 14:51:27 +01:00
|
|
|
FFMPEG_CONFIGURE_ENABLE=ffmpeg
|
|
|
|
OSS_CONFIGURE_ENABLE= oss
|
2016-04-01 16:00:51 +02:00
|
|
|
JACK_LIB_DEPENDS= libjack.so:audio/jack
|
2015-11-14 14:51:27 +01:00
|
|
|
JACK_CONFIGURE_ENABLE= jack
|
2016-04-01 16:00:51 +02:00
|
|
|
PULSEAUDIO_LIB_DEPENDS= libpulse.so:audio/pulseaudio
|
2015-11-14 14:51:27 +01:00
|
|
|
PULSEAUDIO_CONFIGURE_ENABLE= pulse
|
2016-04-01 16:00:51 +02:00
|
|
|
ALSA_LIB_DEPENDS= libasound.so:audio/alsa-lib
|
2015-11-14 14:51:27 +01:00
|
|
|
ALSA_CONFIGURE_ENABLE= alsa
|
|
|
|
SDL_USE= SDL=sdl2 image2
|
|
|
|
SDL_CONFIGURE_ON= --disable-sdl --enable-sdl2
|
|
|
|
SDL_CONFIGURE_OFF= --disable-sdl --disable-sdl2
|
2016-07-13 20:38:47 +02:00
|
|
|
OPENGL_USE= GL=gl,egl,gbm
|
2015-11-14 14:51:27 +01:00
|
|
|
OPENGL_CONFIGURE_ENABLE=opengl
|
|
|
|
OPENAL_USES= openal:soft
|
|
|
|
OPENAL_CONFIGURE_ENABLE=al
|
|
|
|
NETPLAY_CONFIGURE_ENABLE= netplay
|
|
|
|
PYTHON_CONFIGURE_ENABLE=python
|
2017-11-30 16:50:30 +01:00
|
|
|
PYTHON_USES= python:3.4+
|
2016-04-01 16:00:51 +02:00
|
|
|
V4L_LIB_DEPENDS= libv4l2.so:multimedia/libv4l
|
|
|
|
V4L_BUILD_DEPENDS= v4l_compat>0:multimedia/v4l_compat
|
2015-11-14 14:51:27 +01:00
|
|
|
V4L_CONFIGURE_ENABLE= v4l2
|
2016-04-01 16:00:51 +02:00
|
|
|
FREETYPE_LIB_DEPENDS= libfreetype.so:print/freetype2
|
2015-11-14 14:51:27 +01:00
|
|
|
FREETYPE_CONFIGURE_ENABLE= freetype
|
|
|
|
FBO_CONFIGURE_ENABLE= fbo
|
|
|
|
|
|
|
|
CFLAGS+= -pthread
|
|
|
|
LDFLAGS+= -pthread
|
|
|
|
CONFIGURE_ARGS+=--enable-threads
|
2016-08-23 13:14:37 +02:00
|
|
|
CONFIGURE_ENV+= MAN_DIR=${MANPREFIX}/man
|
2015-11-14 14:51:27 +01:00
|
|
|
|
2018-03-18 17:57:58 +01:00
|
|
|
USES= compiler:c++11-lib gmake pkgconfig shebangfix
|
2015-11-14 14:51:27 +01:00
|
|
|
USE_GITHUB= yes
|
|
|
|
GH_ACCOUNT= libretro
|
|
|
|
SUB_FILES= pkg-message
|
|
|
|
GNU_CONFIGURE= yes
|
|
|
|
CONFIGURE_ARGS+=--global-config-dir=${LOCALBASE}/etc
|
2016-07-13 20:38:47 +02:00
|
|
|
USE_XORG= x11 xcb xext xinerama xv xxf86vm
|
2018-04-01 09:30:42 +02:00
|
|
|
LLD_UNSAFE= yes
|
2018-03-18 17:57:58 +01:00
|
|
|
SHEBANG_FILES= libretro-common/glsym/glgen.py libretro-common/glsym/rglgen.py tools/cg2glsl.py tools/vulkan_loader_generator.py
|
2015-11-14 14:51:27 +01:00
|
|
|
|
|
|
|
post-patch:
|
|
|
|
@${REINPLACE_CMD} -e 's|<malloc.h>|<stdlib.h>|' \
|
|
|
|
${WRKSRC}/camera/drivers/video4linux2.c \
|
|
|
|
${WRKSRC}/gfx/drivers/*.c \
|
|
|
|
${WRKSRC}/libretro-common/libco/armeabi.c \
|
2016-07-13 20:38:47 +02:00
|
|
|
${WRKSRC}/memory/wii/mem2_manager.c
|
2015-11-14 14:51:27 +01:00
|
|
|
@${REINPLACE_CMD} -e 's|<asm/types.h>|<sys/types.h>|' \
|
|
|
|
${WRKSRC}/camera/drivers/video4linux2.c
|
2016-08-23 13:14:37 +02:00
|
|
|
@${REINPLACE_CMD} -e '/^add_define_make DYLIB_LIB/s|$$|;\
|
|
|
|
add_include_dirs ${LOCALBASE}/include;\
|
|
|
|
add_library_dirs ${LOCALBASE}/lib| ; \
|
|
|
|
/^check_lib OSS_LIB/d' \
|
2015-11-14 14:51:27 +01:00
|
|
|
${WRKSRC}/qb/config.libs.sh
|
|
|
|
|
2017-11-30 16:50:30 +01:00
|
|
|
post-patch-PYTHON-on:
|
|
|
|
@${REINPLACE_CMD} -e '/check_pkgconf PYTHON/s/python3/python-${PYTHON_VER}/' \
|
|
|
|
${WRKSRC}/qb/config.libs.sh
|
|
|
|
|
2015-11-14 14:51:27 +01:00
|
|
|
post-install:
|
2016-08-23 13:14:37 +02:00
|
|
|
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/retroarch
|
2015-11-14 14:51:27 +01:00
|
|
|
@${REINPLACE_CMD} -e 's|# libretro_directory =|libretro_directory = "${PREFIX}/libexec/libretro"|' \
|
|
|
|
${STAGEDIR}${PREFIX}/etc/retroarch.cfg
|
|
|
|
|
|
|
|
.include <bsd.port.mk>
|