Added
Link Here
|
1 |
PORTNAME= ares |
2 |
DISTVERSION= 139.20240809 |
3 |
CATEGORIES= emulators |
4 |
|
5 |
MAINTAINER= bsdcode@disroot.org |
6 |
COMMENT= Multi-system emulator |
7 |
WWW= https://github.com/ares-emulator/ares |
8 |
|
9 |
LICENSE= ISCL |
10 |
LICENSE_FILE= ${WRKSRC}/LICENSE |
11 |
|
12 |
LIB_DEPENDS= librashader.so:devel/librashader |
13 |
|
14 |
FLAVORS= gtk3 qt5 |
15 |
FLAVOR?= ${FLAVORS:[1]} |
16 |
|
17 |
gtk3_LIB_DEPENDS= libcanberra-gtk3.so:audio/libcanberra-gtk3 |
18 |
qt5_PKGNAMESUFFIX= -qt5 |
19 |
|
20 |
USES= compiler:c++17-lang gmake pkgconfig xorg |
21 |
USE_GITHUB= yes |
22 |
GH_ACCOUNT= ares-emulator |
23 |
GH_TAGNAME= a76847d |
24 |
.if ${FLAVOR:U} == gtk3 |
25 |
USES+= gnome |
26 |
USE_GNOME= gtksourceview3 |
27 |
.elif ${FLAVOR:U} == qt5 |
28 |
USES+= qt:5 |
29 |
USE_QT= core gui widgets buildtools:build |
30 |
.endif |
31 |
USE_XORG= x11 xext xrandr |
32 |
|
33 |
MAKEFILE= GNUmakefile |
34 |
MAKE_ARGS= compiler=${CC} \ |
35 |
cores= \ |
36 |
librashader=true \ |
37 |
local=false \ |
38 |
lto=false \ |
39 |
prefix=${PREFIX} \ |
40 |
ruby=video.none \ |
41 |
sdl2=false \ |
42 |
symbols=false \ |
43 |
threaded=true |
44 |
.if ${FLAVOR:U} == gtk3 |
45 |
MAKE_ARGS+= hiro=gtk3-se |
46 |
.elif ${FLAVOR:U} == qt5 |
47 |
MAKE_ARGS+= hiro=qt5 |
48 |
.endif |
49 |
|
50 |
CFLAGS+= -DLIBRA_RUNTIME_OPENGL |
51 |
|
52 |
# https://github.com/ares-emulator/ares/issues/1572 |
53 |
.if ${FLAVOR:U} == qt5 |
54 |
LTO_UNSAFE= yes |
55 |
.endif |
56 |
|
57 |
CONFLICTS_INSTALL= ares ares-qt5 |
58 |
|
59 |
OPTIONS_DEFINE= DEBUG DOCS NVIDIA OPENMP SHADER |
60 |
OPTIONS_DEFAULT= A26 ALSA AO CV FC GB GBA GLX MD MS MSX MYVISION N64 NG \ |
61 |
NGP OPENAL OPENMP OSS PCE PERFORMANCE PS1 SDLAUDIO \ |
62 |
SDLINPUT SFC SG SHADER SPEC UDEV UHID WS XLIB XVIDEO |
63 |
OPTIONS_GROUP= AUDIO CORES INPUT VIDEO |
64 |
OPTIONS_GROUP_AUDIO= ALSA AO OPENAL OSS PULSEAUDIO SDLAUDIO |
65 |
OPTIONS_GROUP_CORES= A26 CV FC GB GBA MD MS MSX MYVISION N64 NG NGP PCE PS1 \ |
66 |
SFC SG SPEC WS |
67 |
OPTIONS_GROUP_INPUT= SDLINPUT UDEV UHID XLIB |
68 |
OPTIONS_GROUP_VIDEO= GLX XVIDEO |
69 |
OPTIONS_SINGLE= PROFILE |
70 |
OPTIONS_SINGLE_PROFILE= ACCURACY PERFORMANCE |
71 |
|
72 |
A26_DESC= Atari 2600 |
73 |
ACCURACY_DESC= Slower but more accurate |
74 |
CV_DESC= ColecoVision |
75 |
FC_DESC= NES / Famicom |
76 |
GBA_DESC= Game Boy Advance |
77 |
GB_DESC= Game Boy |
78 |
MD_DESC= Mega Drive / Genesis |
79 |
MSX_DESC= MSX |
80 |
MS_DESC= Master System / Mark III |
81 |
MYVISION_DESC= My Vision |
82 |
N64_DESC= Nintendo 64 |
83 |
NGP_DESC= Neo Geo Pocket |
84 |
NG_DESC= Neo Geo (AES/MVS) |
85 |
NVIDIA_DESC= Apply shader cache workaround (implies ${NVIDIA_IMPLIES}) |
86 |
PCE_DESC= PC-Engine / TurboGrafx |
87 |
PERFORMANCE_DESC= Faster but less accurate |
88 |
PROFILE_DESC= |
89 |
PS1_DESC= PlayStation |
90 |
SDLAUDIO_DESC= ${SDL_DESC} |
91 |
SDLINPUT_DESC= ${SDL_DESC} |
92 |
SFC_DESC= SNES / Super Famicom |
93 |
SG_DESC= SG-1000 |
94 |
SHADER_DESC= Build with shader support |
95 |
SPEC_DESC= ZX Spectrum |
96 |
UDEV_DESC= UDEV input support |
97 |
UHID_DESC= UHID input support |
98 |
VIDEO_DESC= |
99 |
WS_DESC= WonderSwan |
100 |
XLIB_DESC= XLIB input support |
101 |
|
102 |
A26_MAKE_ARGS= cores+=a26 |
103 |
|
104 |
ACCURACY_MAKE_ARGS= profile=accuracy |
105 |
|
106 |
ALSA_LIB_DEPENDS= libasound.so:audio/alsa-lib |
107 |
ALSA_MAKE_ARGS= ruby+=audio.alsa |
108 |
|
109 |
AO_LIB_DEPENDS= libao.so:audio/libao |
110 |
AO_MAKE_ARGS= ruby+=audio.ao |
111 |
|
112 |
CV_MAKE_ARGS= cores+=cv |
113 |
|
114 |
DEBUG_MAKE_ARGS= build=debug |
115 |
DEBUG_MAKE_ARGS_OFF= build=release |
116 |
|
117 |
FC_MAKE_ARGS= cores+=fc |
118 |
|
119 |
GBA_MAKE_ARGS= cores+=gba |
120 |
|
121 |
GB_MAKE_ARGS= cores+=gb |
122 |
|
123 |
GLX_USES= gl |
124 |
GLX_USE= GL=egl |
125 |
GLX_MAKE_ARGS= ruby+=video.glx |
126 |
|
127 |
MD_MAKE_ARGS= cores+=md |
128 |
|
129 |
MSX_MAKE_ARGS= cores+=msx |
130 |
|
131 |
MS_MAKE_ARGS= cores+=ms |
132 |
|
133 |
MYVISION_MAKE_ARGS= cores+=myvision |
134 |
|
135 |
N64_RUN_DEPENDS= ${LOCALBASE}/lib/libvulkan.so:graphics/vulkan-loader |
136 |
N64_MAKE_ARGS= cores+=n64 \ |
137 |
vulkan=true |
138 |
N64_MAKE_ARGS_OFF= vulkan=false |
139 |
N64_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-ares_n64_vulkan_parallel-rdp_util_timer.cpp |
140 |
|
141 |
NGP_MAKE_ARGS= cores+=ngp |
142 |
|
143 |
NG_MAKE_ARGS= cores+=ng |
144 |
|
145 |
NVIDIA_IMPLIES= N64 |
146 |
NVIDIA_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-ares_n64_vulkan_parallel-rdp_vulkan_device.cpp |
147 |
|
148 |
OPENAL_USES= openal |
149 |
OPENAL_MAKE_ARGS= ruby+=audio.openal |
150 |
|
151 |
OPENMP_MAKE_ARGS= openmp=true |
152 |
OPENMP_MAKE_ARGS_OFF= openmp=false |
153 |
|
154 |
OSS_MAKE_ARGS= ruby+=audio.oss |
155 |
|
156 |
PCE_MAKE_ARGS= cores+=pce |
157 |
|
158 |
PERFORMANCE_MAKE_ARGS= profile=performance |
159 |
|
160 |
PS1_MAKE_ARGS= cores+=ps1 |
161 |
|
162 |
PULSEAUDIO_LIB_DEPENDS= libpulse-simple.so:audio/pulseaudio \ |
163 |
libpulse.so:audio/pulseaudio |
164 |
PULSEAUDIO_MAKE_ARGS= ruby+=audio.pulseaudio \ |
165 |
ruby+=audio.pulseaudiosimple |
166 |
|
167 |
SDLAUDIO_USES= sdl |
168 |
SDLAUDIO_USE= SDL=sdl2 |
169 |
SDLAUDIO_MAKE_ARGS= ruby+=audio.sdl \ |
170 |
sdl2=true |
171 |
|
172 |
SDLINPUT_USES= sdl |
173 |
SDLINPUT_USE= SDL=sdl2 |
174 |
SDLINPUT_MAKE_ARGS= ruby+=input.sdl \ |
175 |
sdl2=true |
176 |
|
177 |
SFC_MAKE_ARGS= cores+=sfc |
178 |
|
179 |
SG_MAKE_ARGS= cores+=sg |
180 |
|
181 |
SHADER_RUN_DEPENDS= ${LOCALBASE}/${_SHADERS}/bilinear.slangp:games/libretro-shaders-slang |
182 |
SHADER_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-desktop-ui_desktop-ui.cpp |
183 |
|
184 |
SPEC_MAKE_ARGS= cores+=spec |
185 |
|
186 |
UDEV_LIB_DEPENDS= libudev.so:devel/libudev-devd |
187 |
UDEV_MAKE_ARGS= ruby+=input.udev |
188 |
|
189 |
UHID_MAKE_ARGS= ruby+=input.uhid |
190 |
|
191 |
WS_MAKE_ARGS= cores+=ws |
192 |
|
193 |
XLIB_MAKE_ARGS= ruby+=input.xlib |
194 |
|
195 |
XVIDEO_USE= XORG=xv |
196 |
XVIDEO_MAKE_ARGS= ruby+=video.xvideo |
197 |
|
198 |
_SHADERS= share/libretro/shaders/shaders_slang |
199 |
|
200 |
post-patch-SHADER-on: |
201 |
${REINPLACE_CMD} 's|@@SHADERS@@|${PREFIX}/${_SHADERS}/|g' \ |
202 |
${WRKSRC}/desktop-ui/desktop-ui.cpp |
203 |
|
204 |
do-install: |
205 |
${INSTALL_PROGRAM} ${WRKSRC}/desktop-ui/out/ares \ |
206 |
${STAGEDIR}${PREFIX}/bin |
207 |
${INSTALL_DATA} ${WRKSRC}/desktop-ui/resource/ares.desktop \ |
208 |
${STAGEDIR}${PREFIX}/share/applications |
209 |
${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/hicolor/256x256/apps |
210 |
${INSTALL_DATA} ${WRKSRC}/desktop-ui/resource/ares.png \ |
211 |
${STAGEDIR}${PREFIX}/share/icons/hicolor/256x256/apps |
212 |
${MKDIR} ${STAGEDIR}${DATADIR}/Database |
213 |
(cd ${WRKSRC}/mia/Database && \ |
214 |
${COPYTREE_SHARE} . ${STAGEDIR}${DATADIR}/Database) |
215 |
|
216 |
post-install-DOCS-on: |
217 |
${MKDIR} ${STAGEDIR}${DOCSDIR} |
218 |
${INSTALL_DATA} ${WRKSRC}/README.md \ |
219 |
${STAGEDIR}${DOCSDIR} |
220 |
|
221 |
.include <bsd.port.mk> |