4132e8ca |
1 | #!/bin/sh |
2 | # some elements originated from qemu configure |
3 | set -e |
4 | |
5 | TMPC="/tmp/pcsx-conf-${RANDOM}-$$-${RANDOM}.c" |
6 | TMPO="/tmp/pcsx-conf-${RANDOM}-$$-${RANDOM}.o" |
07c13dfd |
7 | TMPB="/tmp/pcsx-conf-${RANDOM}-$$-${RANDOM}" |
8 | trap "rm -f $TMPC $TMPO $TMPB" EXIT INT QUIT TERM |
4132e8ca |
9 | rm -f config.log |
10 | |
11 | compile_object() |
12 | { |
07c13dfd |
13 | c="$CC $CFLAGS -c $TMPC -o $TMPO $@" |
14 | echo $c >> config.log |
15 | $c >> config.log 2>&1 |
16 | } |
17 | |
18 | compile_binary() |
19 | { |
20 | c="$CC $CFLAGS $TMPC -o $TMPB $LDFLAGS $MAIN_LDLIBS $@" |
4132e8ca |
21 | echo $c >> config.log |
22 | $c >> config.log 2>&1 |
23 | } |
24 | |
25 | check_define() |
26 | { |
00a212aa |
27 | $CC -E -dD $CFLAGS include/arm_features.h | grep -q $1 || return 1 |
4132e8ca |
28 | return 0 |
29 | } |
30 | |
31 | # setting options to "yes" or "no" will make that choice default, |
32 | # "" means "autodetect". |
33 | |
38c2028e |
34 | platform_list="generic pandora maemo caanoo libretro" |
4132e8ca |
35 | platform="generic" |
61bc6d40 |
36 | builtin_gpu_list="peops unai neon" |
37 | builtin_gpu="" |
b68bf5c2 |
38 | sound_driver_list="oss alsa pulseaudio sdl libretro" |
07c13dfd |
39 | sound_drivers="" |
dd4d5a35 |
40 | plugins="plugins/spunull/spunull.so \ |
41 | plugins/dfxvideo/gpu_peops.so plugins/gpu_unai/gpu_unai.so" |
4132e8ca |
42 | ram_fixed="no" |
43 | drc_cache_base="no" |
00a212aa |
44 | have_armv5="" |
4132e8ca |
45 | have_armv6="" |
46 | have_armv7="" |
47 | have_arm_neon="" |
48 | have_tslib="" |
5b9aa749 |
49 | have_gles="" |
4132e8ca |
50 | enable_dynarec="yes" |
f89fa2d9 |
51 | need_sdl="no" |
955f9af0 |
52 | need_xlib="no" |
cc56203b |
53 | need_libpicofe="yes" |
54 | need_warm="no" |
5b9aa749 |
55 | CFLAGS_GLES="" |
56 | LDLIBS_GLES="" |
4132e8ca |
57 | # these are for known platforms |
58 | optimize_cortexa8="no" |
59 | optimize_arm926ej="no" |
60 | |
61 | # hardcoded stuff |
62 | CC="${CC-${CROSS_COMPILE}gcc}" |
ac6575cd |
63 | CXX="${CXX-${CROSS_COMPILE}g++}" |
4132e8ca |
64 | AS="${AS-${CROSS_COMPILE}as}" |
65 | AR="${AS-${CROSS_COMPILE}ar}" |
f89fa2d9 |
66 | MAIN_LDLIBS="$LDLIBS -ldl -lm" |
4132e8ca |
67 | config_mak="config.mak" |
68 | |
07c13dfd |
69 | fail() |
70 | { |
71 | echo "$@" |
72 | exit 1 |
73 | } |
74 | |
4132e8ca |
75 | # call during arg parsing, so that cmd line can override platform defaults |
76 | set_platform() |
77 | { |
78 | platform=$1 |
79 | case "$platform" in |
80 | generic) |
81 | ;; |
82 | pandora) |
07c13dfd |
83 | sound_drivers="oss alsa" |
4132e8ca |
84 | ram_fixed="yes" |
85 | drc_cache_base="yes" |
86 | optimize_cortexa8="yes" |
87 | have_arm_neon="yes" |
955f9af0 |
88 | need_xlib="yes" |
4132e8ca |
89 | ;; |
90 | maemo) |
91 | ram_fixed="yes" |
92 | drc_cache_base="yes" |
93 | optimize_cortexa8="yes" |
94 | have_arm_neon="yes" |
95 | ;; |
96 | caanoo) |
07c13dfd |
97 | sound_drivers="oss" |
4132e8ca |
98 | ram_fixed="yes" |
99 | drc_cache_base="yes" |
100 | optimize_arm926ej="yes" |
cc56203b |
101 | need_warm="yes" |
4132e8ca |
102 | ;; |
38c2028e |
103 | libretro) |
07c13dfd |
104 | sound_drivers="libretro" |
cc56203b |
105 | need_libpicofe="no" |
38c2028e |
106 | ;; |
4132e8ca |
107 | *) |
07c13dfd |
108 | fail "unsupported platform: $platform" |
4132e8ca |
109 | ;; |
110 | esac |
111 | } |
112 | |
113 | for opt do |
114 | optarg=`expr "x$opt" : 'x[^=]*=\(.*\)'` || true |
115 | case "$opt" in |
116 | --help|-h) show_help="yes" |
117 | ;; |
118 | --platform=*) set_platform "$optarg" |
119 | ;; |
61bc6d40 |
120 | --gpu=*) builtin_gpu="$optarg" |
121 | ;; |
07c13dfd |
122 | --sound-drivers=*) sound_drivers="$optarg" |
4132e8ca |
123 | ;; |
124 | --enable-neon) have_arm_neon="yes" |
125 | ;; |
126 | --disable-neon) have_arm_neon="no" |
127 | ;; |
128 | --disable-dynarec) enable_dynarec="no" |
129 | ;; |
130 | *) echo "ERROR: unknown option $opt"; show_help="yes" |
131 | ;; |
132 | esac |
133 | done |
134 | |
135 | if [ "$show_help" = "yes" ]; then |
136 | echo "options:" |
137 | echo " --help print this message" |
138 | echo " --platform=NAME target platform [$platform]" |
139 | echo " available: $platform_list" |
61bc6d40 |
140 | echo " --gpu=NAME builtin gpu plugin [guessed]" |
141 | echo " available: $builtin_gpu_list" |
07c13dfd |
142 | echo " --sound-drivers=LIST sound output drivers [guessed]" |
4132e8ca |
143 | echo " available: $sound_driver_list" |
144 | echo " --enable-neon" |
145 | echo " --disable-neon enable/disable ARM NEON optimizations [guessed]" |
146 | echo " --disable-dynarec disable dynamic recompiler" |
147 | echo " (dynarec is only available and enabled on ARM)" |
148 | echo "influential environment variables:" |
ac6575cd |
149 | echo " CROSS_COMPILE CC CXX AS AR CFLAGS ASFLAGS LDFLAGS LDLIBS" |
4132e8ca |
150 | exit 1 |
151 | fi |
152 | |
07c13dfd |
153 | # validate selections |
61bc6d40 |
154 | if [ "x$builtin_gpu" != "x" ]; then |
07c13dfd |
155 | if ! echo $builtin_gpu_list | grep -q "\<$builtin_gpu\>"; then |
156 | fail "unsupported builtin gpu plugin: $builtin_gpu" |
157 | fi |
61bc6d40 |
158 | fi |
159 | |
07c13dfd |
160 | if [ "x$sound_drivers" != "x" ]; then |
161 | for d in $sound_drivers; do |
162 | if ! echo $sound_driver_list | grep -q "\<$d\>"; then |
163 | fail "unsupported sound driver: $sound_driver" |
164 | fi |
165 | done |
166 | fi |
4132e8ca |
167 | |
cc56203b |
168 | if [ "$need_libpicofe" = "yes" ]; then |
169 | if ! test -f "frontend/libpicofe/README"; then |
170 | fail "libpicofe is missing, please run 'git submodule init && git submodule update'" |
171 | fi |
172 | fi |
173 | |
174 | if [ "$need_warm" = "yes" ]; then |
175 | if ! test -f "frontend/warm/README"; then |
176 | fail "wARM is missing, please run 'git submodule init && git submodule update'" |
177 | fi |
178 | fi |
179 | |
00a212aa |
180 | # basic compiler test |
181 | cat > $TMPC <<EOF |
182 | #include <zlib.h> |
183 | int main(void) { return 0; } |
184 | EOF |
185 | if ! compile_binary; then |
0dc1b4a9 |
186 | fail "compiler test failed, please check config.log" |
00a212aa |
187 | fi |
188 | |
4132e8ca |
189 | if [ -z "$ARCH" ]; then |
0dc1b4a9 |
190 | ARCH=`$CC -dumpmachine | awk -F '-' '{print $1}'` |
4132e8ca |
191 | fi |
192 | |
0dc1b4a9 |
193 | case "$ARCH" in |
194 | arm*) |
195 | # ARM stuff |
196 | ARCH="arm" |
197 | |
4132e8ca |
198 | if [ "$optimize_cortexa8" = "yes" ]; then |
4132e8ca |
199 | CFLAGS="$CFLAGS -mcpu=cortex-a8 -mtune=cortex-a8" |
200 | ASFLAGS="$ASFLAGS -mcpu=cortex-a8" |
201 | fi |
202 | if [ "$optimize_arm926ej" = "yes" ]; then |
203 | CFLAGS="$CFLAGS -mcpu=arm926ej-s -mtune=arm926ej-s" |
204 | ASFLAGS="$ASFLAGS -mcpu=arm926ej-s -mfloat-abi=softfp" |
205 | fi |
206 | |
207 | if [ "x$have_arm_neon" = "x" ]; then |
208 | # detect NEON from user-supplied cflags to enable asm code |
209 | have_arm_neon=`check_define __ARM_NEON__ && echo yes` || true |
210 | fi |
4132e8ca |
211 | if [ "x$have_armv7" = "x" ]; then |
00a212aa |
212 | if check_define HAVE_ARMV7; then |
4132e8ca |
213 | have_armv7="yes" |
00a212aa |
214 | have_armv6="yes" |
215 | have_armv5="yes" |
4132e8ca |
216 | fi |
217 | fi |
00a212aa |
218 | if [ "x$have_armv6" = "x" ]; then |
219 | if check_define HAVE_ARMV6; then |
220 | have_armv6="yes" |
221 | have_armv5="yes" |
222 | fi |
223 | fi |
224 | if [ "x$have_armv5" = "x" ]; then |
225 | have_armv5=`check_define HAVE_ARMV5 && echo yes` || true |
226 | fi |
4132e8ca |
227 | |
61bc6d40 |
228 | if [ "x$builtin_gpu" = "x" ]; then |
229 | if [ "$have_arm_neon" = "yes" ]; then |
230 | builtin_gpu="neon" |
231 | elif [ "$have_armv7" != "yes" ]; then |
232 | # pre-ARMv7 hardware is usually not fast enough for peops |
233 | builtin_gpu="unai" |
234 | else |
235 | builtin_gpu="peops" |
236 | fi |
237 | fi |
238 | |
e795af9e |
239 | # automatically set mfpu and mfloat-abi if they are not set |
4132e8ca |
240 | if [ "$have_arm_neon" = "yes" ]; then |
40cf6975 |
241 | fpu="neon" |
4132e8ca |
242 | elif [ "$have_armv6" = "yes" ]; then |
40cf6975 |
243 | fpu="vfp" |
4132e8ca |
244 | fi |
40cf6975 |
245 | if [ "x$fpu" != "x" ]; then |
246 | echo "$CFLAGS" | grep -q -- '-mfpu=' || CFLAGS="$CFLAGS -mfpu=$fpu" |
247 | echo "$ASFLAGS" | grep -q -- '-mfpu=' || ASFLAGS="$ASFLAGS -mfpu=$fpu" |
248 | floatabi_set_by_gcc=`$CC -v 2>&1 | grep -q -- --with-float= && echo yes` || true |
249 | if [ "$floatabi_set_by_gcc" != "yes" ]; then |
250 | echo "$CFLAGS" | grep -q -- '-mfloat-abi=' || CFLAGS="$CFLAGS -mfloat-abi=softfp" |
251 | echo "$ASFLAGS" | grep -q -- '-mfloat-abi=' || ASFLAGS="$ASFLAGS -mfloat-abi=softfp" |
252 | fi |
4132e8ca |
253 | fi |
254 | |
9f704290 |
255 | # must disable thumb as recompiler can't handle it |
96751f36 |
256 | if check_define __thumb__; then |
9f704290 |
257 | CFLAGS="$CFLAGS -marm" |
96751f36 |
258 | fi |
00a212aa |
259 | |
260 | # warn about common mistakes |
261 | if [ "$have_armv5" != "yes" ]; then |
262 | if ! echo "$CFLAGS" | grep -q -- '-mcpu=\|-march='; then |
263 | echo "Warning: compiling for ARMv4, is that really what you want?" |
264 | echo "You probably should specify -mcpu= or -march= like this:" |
265 | echo " CFLAGS=-march=armv6 ./configure ..." |
266 | fi |
267 | fi |
268 | if [ "$have_arm_neon" = "yes" -a "$have_armv7" != "yes" ]; then |
269 | echo "Warning: compiling for NEON, but not ARMv7?" |
270 | echo "You probably want to specify -mcpu= or -march= like this:" |
271 | echo " CFLAGS=-march=armv7-a ./configure ..." |
272 | fi |
0dc1b4a9 |
273 | ;; |
274 | *) |
4132e8ca |
275 | # dynarec only available on ARM |
276 | enable_dynarec="no" |
0dc1b4a9 |
277 | ;; |
278 | esac |
4132e8ca |
279 | |
61bc6d40 |
280 | if [ "x$builtin_gpu" = "x" ]; then |
281 | builtin_gpu="peops" |
282 | fi |
283 | |
4132e8ca |
284 | # supposedly we can avoid -fPIC on armv5 for slightly better performace? |
285 | if [ "$ARCH" != "arm" -o "$have_armv6" = "yes" ]; then |
286 | PLUGIN_CFLAGS="$PLUGIN_CFLAGS -fPIC" |
287 | fi |
288 | |
289 | if [ "$ram_fixed" = "yes" ]; then |
290 | CFLAGS="$CFLAGS -DRAM_FIXED" |
291 | fi |
292 | |
38c2028e |
293 | case "$platform" in |
294 | generic) |
f89fa2d9 |
295 | need_sdl="yes" |
38c2028e |
296 | ;; |
297 | maemo) |
4132e8ca |
298 | maemo_cflags=`pkg-config --cflags hildon-1` |
299 | maemo_ldlibs=`pkg-config --libs hildon-1` |
300 | CFLAGS="$CFLAGS -DMAEMO -DMAEMO_CHANGES $maemo_cflags" |
07c13dfd |
301 | MAIN_LDLIBS="$MAIN_LDLIBS $maemo_ldlibs" |
38c2028e |
302 | ;; |
303 | libretro) |
304 | CFLAGS="$CFLAGS -fPIC" |
22fa3f2b |
305 | MAIN_LDFLAGS="$MAIN_LDFLAGS -shared -Wl,--no-undefined" |
38c2028e |
306 | ;; |
307 | esac |
4132e8ca |
308 | |
07c13dfd |
309 | # header/library presence tests |
310 | check_zlib() |
311 | { |
312 | cat > $TMPC <<EOF |
313 | #include <zlib.h> |
791f6e3e |
314 | int main(void) { uncompress(0, 0, 0, 0); } |
07c13dfd |
315 | EOF |
316 | compile_binary |
317 | } |
318 | |
07c13dfd |
319 | check_libpng() |
320 | { |
321 | cat > $TMPC <<EOF |
322 | #include <png.h> |
323 | void main() { png_init_io(0, 0); } |
324 | EOF |
325 | compile_binary |
326 | } |
327 | |
328 | check_oss() |
329 | { |
330 | cat > $TMPC <<EOF |
331 | #include <sys/soundcard.h> |
332 | #include <sys/ioctl.h> |
333 | void main() { int a=0; ioctl(0, SNDCTL_DSP_SETFMT, &a); } |
334 | EOF |
335 | compile_binary |
336 | } |
337 | |
338 | check_alsa() |
339 | { |
340 | cat > $TMPC <<EOF |
341 | #include <alsa/asoundlib.h> |
342 | void main() { snd_pcm_open(0, 0, 0, 0); } |
343 | EOF |
344 | compile_binary "$@" |
345 | } |
346 | |
b68bf5c2 |
347 | check_pulseaudio() |
348 | { |
349 | cat > $TMPC <<EOF |
350 | #include <pulse/pulseaudio.h> |
351 | void main() { pa_threaded_mainloop_new(); } |
352 | EOF |
353 | compile_binary "$@" |
354 | } |
355 | |
07c13dfd |
356 | check_sdl() |
357 | { |
358 | cat > $TMPC <<EOF |
359 | #include <SDL.h> |
360 | void main() { SDL_OpenAudio(0, 0); } |
361 | EOF |
362 | compile_binary "$@" |
363 | } |
364 | |
955f9af0 |
365 | check_xlib_headers() |
366 | { |
367 | cat > $TMPC <<EOF |
368 | #include <X11/Xlib.h> |
369 | void *f() { return XOpenDisplay(0); } |
370 | EOF |
371 | compile_object "$@" |
372 | } |
373 | |
f89fa2d9 |
374 | MAIN_LDLIBS="$MAIN_LDLIBS -lz" |
9f704290 |
375 | check_zlib || fail "please install zlib (libz-dev)" |
f89fa2d9 |
376 | |
f89fa2d9 |
377 | MAIN_LDLIBS="-lpng $MAIN_LDLIBS" |
9f704290 |
378 | check_libpng || fail "please install libpng (libpng-dev)" |
07c13dfd |
379 | |
380 | # find what audio support we can compile |
381 | if [ "x$sound_drivers" = "x" ]; then |
382 | if check_oss; then sound_drivers="$sound_drivers oss"; fi |
f89fa2d9 |
383 | if check_alsa -lasound; then |
384 | sound_drivers="$sound_drivers alsa" |
385 | MAIN_LDLIBS="-lasound $MAIN_LDLIBS" |
386 | fi |
b68bf5c2 |
387 | if check_pulseaudio -lpulse; then |
388 | sound_drivers="$sound_drivers pulseaudio" |
389 | MAIN_LDLIBS="-lpulse $MAIN_LDLIBS" |
390 | fi |
9f704290 |
391 | if [ "$need_sdl" = "yes" ] || check_sdl `sdl-config --cflags --libs`; then |
f89fa2d9 |
392 | sound_drivers="$sound_drivers sdl" |
393 | need_sdl="yes" |
394 | fi |
395 | else |
396 | if echo $sound_drivers | grep -q "\<oss\>"; then |
397 | check_oss || fail "oss support is missing" |
398 | fi |
399 | if echo $sound_drivers | grep -q "\<alsa\>"; then |
400 | MAIN_LDLIBS="-lasound $MAIN_LDLIBS" |
401 | check_alsa || fail "please install libasound2-dev" |
402 | fi |
b68bf5c2 |
403 | if echo $sound_drivers | grep -q "\<pulseaudio\>"; then |
404 | MAIN_LDLIBS="-lpulse $MAIN_LDLIBS" |
405 | check_pulseaudio || fail "pulseaudio support is missing" |
406 | fi |
07c13dfd |
407 | fi |
408 | |
9f704290 |
409 | if [ "$need_sdl" = "yes" ]; then |
410 | which sdl-config > /dev/null || \ |
411 | fail "sdl-config is missing; please install libsdl (libsdl1.2-dev)" |
f89fa2d9 |
412 | CFLAGS="$CFLAGS `sdl-config --cflags`" |
413 | MAIN_LDLIBS="`sdl-config --libs` $MAIN_LDLIBS" |
9f704290 |
414 | check_sdl || fail "please install libsdl (libsdl1.2-dev)" |
07c13dfd |
415 | fi |
416 | |
4132e8ca |
417 | # check for tslib (only headers needed) |
418 | if [ "x$have_tslib" = "x" ]; then |
419 | cat > $TMPC <<EOF |
420 | #include <tslib.h> |
421 | void test(struct ts_sample sample) {} |
422 | EOF |
423 | if compile_object; then |
424 | have_tslib="yes" |
425 | else |
426 | have_tslib="no" |
427 | fi |
428 | fi |
429 | |
5b9aa749 |
430 | # check for VideoCore stuff for Raspberry Pi |
431 | if [ -d /opt/vc/include -a -d /opt/vc/lib ]; then |
432 | CFLAGS_GLES="$CFLAGS_GLES -I/opt/vc/include -I/opt/vc/include/interface/vcos/pthreads" |
433 | LDLIBS_GLES="$LDLIBS_GLES -L/opt/vc/lib" |
955f9af0 |
434 | need_xlib="yes" |
5b9aa749 |
435 | fi |
436 | |
dd4d5a35 |
437 | # check for GLES headers |
438 | cat > $TMPC <<EOF |
439 | #include <GLES/gl.h> |
dd4d5a35 |
440 | #include <EGL/egl.h> |
5b9aa749 |
441 | int main(void) { |
442 | return (int)eglGetDisplay( (EGLNativeDisplayType)0 ); |
dd4d5a35 |
443 | } |
444 | EOF |
5b9aa749 |
445 | if compile_binary $CFLAGS_GLES -lEGL -lGLES_CM $LDLIBS_GLES; then |
446 | have_gles="yes" |
447 | LDLIBS_GLES="-lEGL -lGLES_CM $LDLIBS_GLES" |
448 | elif compile_binary $CFLAGS_GLES -lEGL -lGLESv1_CM $LDLIBS_GLES; then |
449 | have_gles="yes" |
450 | LDLIBS_GLES="-lEGL -lGLESv1_CM $LDLIBS_GLES" |
dd4d5a35 |
451 | fi |
452 | |
5b9aa749 |
453 | if [ "$have_gles" = "yes" ]; then |
454 | plugins="$plugins plugins/gpu-gles/gpu_gles.so" |
455 | fi |
61bc6d40 |
456 | if [ "$have_arm_neon" = "yes" -a "$builtin_gpu" != "neon" ]; then |
457 | plugins="$plugins plugins/gpu_neon/gpu_neon.so" |
458 | fi |
459 | |
955f9af0 |
460 | # check for xlib (only headers needed) |
461 | if [ "x$need_xlib" = "xyes" ]; then |
462 | check_xlib_headers || fail "please install libx11-dev" |
463 | fi |
464 | |
9f704290 |
465 | cat > $TMPC <<EOF |
466 | void test(void *f, void *d) { fread(d, 1, 1, f); } |
467 | EOF |
468 | if compile_object -Wno-unused-result; then |
469 | CFLAGS="$CFLAGS -Wno-unused-result" |
470 | fi |
471 | |
dd4d5a35 |
472 | # short plugin list for display |
473 | for p in $plugins; do |
474 | p1=`basename $p` |
475 | plugins_short="$p1 $plugins_short" |
476 | done |
477 | |
4132e8ca |
478 | # set things that failed to autodetect to "no" |
479 | test "x$have_armv6" != "x" || have_armv6="no" |
480 | test "x$have_armv7" != "x" || have_armv7="no" |
481 | test "x$have_arm_neon" != "x" || have_arm_neon="no" |
00a212aa |
482 | test "x$have_gles" != "x" || have_gles="no" |
4132e8ca |
483 | |
484 | echo "architecture $ARCH" |
485 | echo "platform $platform" |
61bc6d40 |
486 | echo "built-in GPU $builtin_gpu" |
07c13dfd |
487 | echo "sound drivers $sound_drivers" |
dd4d5a35 |
488 | echo "plugins $plugins_short" |
4132e8ca |
489 | echo "C compiler $CC" |
490 | echo "C compiler flags $CFLAGS" |
07c13dfd |
491 | echo "libraries $MAIN_LDLIBS" |
22fa3f2b |
492 | echo "linker flags $LDFLAGS$MAIN_LDFLAGS" |
4132e8ca |
493 | echo "enable dynarec $enable_dynarec" |
494 | echo "ARMv7 optimizations $have_armv7" |
495 | echo "enable ARM NEON $have_arm_neon" |
496 | echo "tslib support $have_tslib" |
2c616080 |
497 | if [ "$platform" = "generic" ]; then |
498 | echo "OpenGL ES output $have_gles" |
499 | fi |
4132e8ca |
500 | |
501 | echo "# Automatically generated by configure" > $config_mak |
502 | printf "# Configured with:" >> $config_mak |
503 | printf " '%s'" "$0" "$@" >> $config_mak |
504 | echo >> $config_mak |
505 | |
506 | echo "CC = $CC" >> $config_mak |
ac6575cd |
507 | echo "CXX = $CXX" >> $config_mak |
4132e8ca |
508 | echo "AS = $AS" >> $config_mak |
509 | echo "CFLAGS += $CFLAGS" >> $config_mak |
510 | echo "ASFLAGS += $ASFLAGS" >> $config_mak |
511 | echo "LDFLAGS += $LDFLAGS" >> $config_mak |
22fa3f2b |
512 | echo "MAIN_LDFLAGS += $MAIN_LDFLAGS" >> $config_mak |
07c13dfd |
513 | echo "MAIN_LDLIBS += $MAIN_LDLIBS" >> $config_mak |
4132e8ca |
514 | echo "PLUGIN_CFLAGS += $PLUGIN_CFLAGS" >> $config_mak |
515 | echo >> $config_mak |
516 | |
38c2028e |
517 | if [ "$platform" = "libretro" ]; then |
518 | echo "TARGET = libretro.so" >> $config_mak |
519 | fi |
4132e8ca |
520 | echo "ARCH = $ARCH" >> $config_mak |
521 | echo "PLATFORM = $platform" >> $config_mak |
61bc6d40 |
522 | echo "BUILTIN_GPU = $builtin_gpu" >> $config_mak |
07c13dfd |
523 | echo "SOUND_DRIVERS = $sound_drivers" >> $config_mak |
ddd99692 |
524 | echo "PLUGINS = $plugins" >> $config_mak |
4132e8ca |
525 | if [ "$have_arm_neon" = "yes" ]; then |
526 | echo "HAVE_NEON = 1" >> $config_mak |
527 | fi |
528 | if [ "$have_tslib" = "yes" ]; then |
529 | echo "HAVE_TSLIB = 1" >> $config_mak |
530 | fi |
5b9aa749 |
531 | if [ "$have_gles" = "yes" ]; then |
532 | echo "HAVE_GLES = 1" >> $config_mak |
533 | echo "CFLAGS_GLES = $CFLAGS_GLES" >> $config_mak |
534 | echo "LDLIBS_GLES = $LDLIBS_GLES" >> $config_mak |
535 | fi |
4132e8ca |
536 | if [ "$enable_dynarec" = "yes" ]; then |
537 | echo "USE_DYNAREC = 1" >> $config_mak |
538 | fi |
539 | if [ "$drc_cache_base" = "yes" ]; then |
540 | echo "DRC_CACHE_BASE = 1" >> $config_mak |
541 | fi |
542 | |
2e6189bc |
543 | # use pandora's skin (for now) |
544 | test -e skin || ln -s frontend/pandora/skin skin |
545 | |
4132e8ca |
546 | # vim:shiftwidth=2:expandtab |