2018-12-06 21:18:26 +01:00
# Default platform is rpi3 / SDL2 / Dispmanx
2015-10-14 08:09:05 +01:00
i f e q ( $( PLATFORM ) , )
2018-12-06 21:18:26 +01:00
PLATFORM = rpi3-sdl2-dispmanx
2015-10-14 08:09:05 +01:00
e n d i f
2019-09-03 23:49:39 +02:00
# Raspberry Pi 4 CPU flags
2019-08-17 11:38:36 +02:00
i f n e q ( , $( findstring rpi 4,$ ( PLATFORM ) ) )
2019-09-12 21:57:53 +02:00
CPUFLAGS = -mcpu= cortex-a72 -mfpu= neon-fp-armv8
2019-08-17 11:38:36 +02:00
e n d i f
2019-09-03 23:49:39 +02:00
# Raspberry Pi 3 CPU flags
2018-11-04 20:53:02 +01:00
i f n e q ( , $( findstring rpi 3,$ ( PLATFORM ) ) )
2019-09-12 21:57:53 +02:00
CPUFLAGS = -mcpu= cortex-a53 -mfpu= neon-fp-armv8
2018-11-04 20:53:02 +01:00
e n d i f
2019-09-03 23:49:39 +02:00
# Raspberry Pi 2 CPU flags
2018-11-04 20:53:02 +01:00
i f n e q ( , $( findstring rpi 2,$ ( PLATFORM ) ) )
2019-09-12 21:57:53 +02:00
CPUFLAGS = -mcpu= cortex-a7 -mfpu= neon-vfpv4
2018-11-04 20:53:02 +01:00
e n d i f
2019-09-03 23:49:39 +02:00
# Raspberry Pi 1 CPU flags
2018-11-04 20:53:02 +01:00
i f n e q ( , $( findstring rpi 1,$ ( PLATFORM ) ) )
2019-09-12 21:57:53 +02:00
CPUFLAGS = -mcpu= arm1176jzf-s -mfpu= vfp
2018-11-04 20:53:02 +01:00
e n d i f
2017-12-26 21:15:42 +01:00
#
2018-01-13 00:29:50 +01:00
# DispmanX Common flags for both SDL1 and SDL2 (RPI-specific)
2017-12-26 21:15:42 +01:00
#
2018-01-12 23:19:31 +01:00
DISPMANX_FLAGS = -DUSE_DISPMANX -I/opt/vc/include -I/opt/vc/include/interface/vmcs_host/linux -I/opt/vc/include/interface/vcos/pthreads
2018-12-23 15:34:53 +01:00
DISPMANX_LDFLAGS = -lbcm_host -lvchiq_arm -L/opt/vc/lib -Wl,-rpath= /opt/vc/lib
2018-12-11 21:32:46 +01:00
CPPFLAGS = -MD -MT $@ -MF $( @:%.o= %.d)
2018-01-04 21:03:10 +01:00
#DEBUG=1
#GCC_PROFILE=1
#GEN_PROFILE=1
#USE_PROFILE=1
2019-09-15 11:35:00 +02:00
#USE_LTO=1
2018-01-25 21:21:56 +01:00
#SANITIZE=1
2017-12-05 09:12:43 +01:00
#
# SDL1 targets
#
2019-09-12 21:57:53 +02:00
# Raspberry Pi 1/2/3 (SDL1, DispmanX)
i f e q ( $( PLATFORM ) , $( filter $ ( PLATFORM ) ,rpi 1 rpi 2 rpi 3) )
2019-05-04 23:51:42 +02:00
CPPFLAGS += ${ DISPMANX_FLAGS } -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_SDL1
2017-12-30 01:37:52 +01:00
LDFLAGS += ${ DISPMANX_LDFLAGS }
2019-09-12 21:57:53 +02:00
ifeq ( $( PLATFORM) ,$( filter $( PLATFORM) ,rpi2 rpi3) )
CPPFLAGS += -DUSE_ARMNEON -DARM_HAS_DIV
HAVE_NEON = 1
endif
2017-12-05 09:12:43 +01:00
2019-09-03 23:49:39 +02:00
# Android 32-bit
2017-12-04 15:49:40 +01:00
e l s e i f e q ( $( PLATFORM ) , a n d r o i d )
2019-09-12 10:01:38 +02:00
CPUFLAGS += -mfpu= vfp
2019-04-08 20:31:18 +02:00
DEFS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DANDROIDSDL -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL1
2018-01-12 23:19:31 +01:00
ANDROID = 1
2019-09-02 15:01:01 +02:00
2019-09-03 23:49:39 +02:00
# Android 64-bit
2019-09-02 15:01:01 +02:00
e l s e i f e q ( $( PLATFORM ) , a n d r o i d 6 4 )
DEFS += -DCPU_AARCH64 -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DANDROIDSDL -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL1
ANDROID = 1
AARCH64 = 1
2017-12-05 09:12:43 +01:00
#
2018-01-13 00:29:50 +01:00
# SDL2 with DispmanX targets (RPI only)
2017-12-30 01:37:52 +01:00
#
2019-09-12 21:59:10 +02:00
# Raspberry Pi 1/2/3/4 (SDL2, DispmanX)
2019-09-12 22:08:11 +02:00
e l s e i f e q ( $( PLATFORM ) , $( filter $ ( PLATFORM ) ,rpi 1-sdl 2-dispmanx rpi 2-sdl 2-dispmanx rpi 3-sdl 2-dispmanx rpi 4-sdl 2-dispmanx ) )
2019-09-12 21:57:53 +02:00
USE_SDL2 = 1
2019-05-04 23:51:42 +02:00
CPPFLAGS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_SDL2 ${ DISPMANX_FLAGS }
2018-01-13 00:29:50 +01:00
LDFLAGS += ${ DISPMANX_LDFLAGS }
2019-09-12 21:57:53 +02:00
ifeq ( $( PLATFORM) ,$( filter $( PLATFORM) ,rpi2-sdl2-dispmanx rpi3-sdl2-dispmanx rpi4-sdl2-dispmanx) )
CPPFLAGS += -DUSE_ARMNEON -DARM_HAS_DIV
HAVE_NEON = 1
endif
2018-01-13 00:29:50 +01:00
#
# SDL2 targets
2019-09-03 23:49:39 +02:00
#
2019-09-12 21:57:53 +02:00
# Raspberry Pi 1/2/3/4 (SDL2)
e l s e i f e q ( $( PLATFORM ) , $( filter $ ( PLATFORM ) ,rpi 1-sdl 2 rpi 2-sdl 2 rpi 3-sdl 2 rpi 4-sdl 2) )
USE_SDL2 = 1
2019-05-04 23:51:42 +02:00
CPPFLAGS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_SDL2
2019-09-12 21:57:53 +02:00
ifeq ( $( PLATFORM) ,$( filter $( PLATFORM) , rpi2-sdl2 rpi3-sdl2 rpi4-sdl2) )
CPPFLAGS += -DUSE_ARMNEON -DARM_HAS_DIV
HAVE_NEON = 1
endif
2017-12-05 09:12:43 +01:00
2019-09-03 23:49:39 +02:00
# OrangePi (SDL2)
2018-10-03 00:21:13 +02:00
e l s e i f e q ( $( PLATFORM ) , o r a n g e p i - p c )
2017-12-05 09:12:43 +01:00
USE_SDL2 = 1
2019-09-12 21:57:53 +02:00
CPUFLAGS = -mcpu= cortex-a7 -mfpu= neon-vfpv4
2019-09-15 16:30:46 +02:00
CPPFLAGS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL2 -DSOFTWARE_CURSOR -DUSE_RENDER_THREAD
2018-10-03 00:21:13 +02:00
HAVE_NEON = 1
ifdef DEBUG
# Otherwise we'll get compilation errors, check https://tls.mbed.org/kb/development/arm-thumb-error-r7-cannot-be-used-in-asm-here
# quote: The assembly code in bn_mul.h is optimized for the ARM platform and uses some registers, including r7 to efficiently do an operation. GCC also uses r7 as the frame pointer under ARM Thumb assembly.
MORE_CFLAGS += -fomit-frame-pointer
endif
2017-12-05 09:12:43 +01:00
2019-09-03 23:49:39 +02:00
# Odroid XU4 (SDL2)
2018-02-06 21:36:25 +01:00
e l s e i f e q ( $( PLATFORM ) , x u 4 )
2019-09-12 21:57:53 +02:00
USE_SDL2 = 1
CPUFLAGS += -mcpu= cortex-a15.cortex-a7 -mfpu= neon-vfpv4
2019-09-15 16:30:46 +02:00
CPPFLAGS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL2 -DSOFTWARE_CURSOR -DUSE_RENDER_THREAD -DFASTERCYCLES
2018-02-01 23:06:24 +01:00
HAVE_NEON = 1
2017-12-05 09:12:43 +01:00
ifdef DEBUG
# Otherwise we'll get compilation errors, check https://tls.mbed.org/kb/development/arm-thumb-error-r7-cannot-be-used-in-asm-here
# quote: The assembly code in bn_mul.h is optimized for the ARM platform and uses some registers, including r7 to efficiently do an operation. GCC also uses r7 as the frame pointer under ARM Thumb assembly.
MORE_CFLAGS += -fomit-frame-pointer
endif
2018-05-06 00:00:17 +02:00
2019-09-03 23:49:39 +02:00
# Odroid C1 (SDL2)
2018-05-06 00:00:17 +02:00
e l s e i f e q ( $( PLATFORM ) , c 1 )
2019-09-12 21:57:53 +02:00
USE_SDL2 = 1
CPUFLAGS += -mcpu= cortex-a5 -mfpu= neon-vfpv4
2019-09-15 16:30:46 +02:00
CPPFLAGS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL2 -DSOFTWARE_CURSOR -DUSE_RENDER_THREAD -DFASTERCYCLES
2018-05-06 00:00:17 +02:00
HAVE_NEON = 1
ifdef DEBUG
# Otherwise we'll get compilation errors, check https://tls.mbed.org/kb/development/arm-thumb-error-r7-cannot-be-used-in-asm-here
# quote: The assembly code in bn_mul.h is optimized for the ARM platform and uses some registers, including r7 to efficiently do an operation. GCC also uses r7 as the frame pointer under ARM Thumb assembly.
MORE_CFLAGS += -fomit-frame-pointer
endif
2019-04-08 20:31:18 +02:00
2019-09-04 23:51:27 +02:00
# Odroid N1/N2, RockPro64 (SDL2 64-bit)
2019-09-03 18:15:06 +02:00
e l s e i f e q ( $( PLATFORM ) , n 2 )
2019-04-08 20:31:18 +02:00
USE_SDL2 = 1
2019-09-12 10:01:38 +02:00
CPUFLAGS += -mcpu= cortex-a72.cortex-a53
2019-09-15 16:30:46 +02:00
CPPFLAGS += -DCPU_AARCH64 -D_FILE_OFFSET_BITS= 64 -DUSE_SDL2 -DSOFTWARE_CURSOR -DFASTERCYCLES
2019-09-03 18:15:06 +02:00
AARCH64 = 1
2019-04-08 20:31:18 +02:00
2019-09-11 21:11:54 +02:00
# Raspberry Pi 3/4 (SDL2 64-bit)
e l s e i f e q ( $( PLATFORM ) , p i 6 4 )
USE_SDL2 = 1
2019-09-12 21:57:53 +02:00
CPUFLAGS += -mcpu= cortex-a72
2019-09-11 21:11:54 +02:00
CPPFLAGS += -DCPU_AARCH64 -D_FILE_OFFSET_BITS= 64 -DUSE_SDL2
AARCH64 = 1
2019-09-03 23:49:39 +02:00
# Vero 4k (SDL2)
2018-05-06 00:00:17 +02:00
e l s e i f e q ( $( PLATFORM ) , v e r o 4 k )
2018-04-03 10:26:07 +01:00
USE_SDL2 = 1
2019-09-12 10:01:38 +02:00
CPUFLAGS = -mcpu= cortex-a7 -mfpu= neon-vfpv4 -mfloat-abi= hard
CFLAGS += -ftree-vectorize -funsafe-math-optimizations
2019-09-15 16:30:46 +02:00
CPPFLAGS += -I/opt/vero3/include -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL2 -DSOFTWARE_CURSOR -DUSE_RENDER_THREAD -DFASTERCYCLES
2018-04-03 10:26:07 +01:00
LDFLAGS += -L/opt/vero3/lib
HAVE_NEON = 1
2018-01-22 21:14:39 +01:00
2019-08-03 15:40:56 +02:00
# Amlogic S905/S905X/S912 (AMLGXBB/AMLGXL/AMLGXM) e.g. Khadas VIM1/2 / S905X2 (AMLG12A) & S922X/A311D (AMLG12B) e.g. Khadas VIM3 - 32-bit userspace
e l s e i f n e q ( , $( findstring AMLG ,$ ( PLATFORM ) ) )
USE_SDL2 = 1
2019-09-12 21:57:53 +02:00
CPUFLAGS += -mfloat-abi= hard -mfpu= neon-fp-armv8
2019-09-15 16:30:46 +02:00
CPPFLAGS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL2 -DSOFTWARE_CURSOR -DFASTERCYCLES
2019-08-03 15:40:56 +02:00
HAVE_NEON = 1
ifneq ( ,$( findstring AMLG12,$( PLATFORM) ) )
ifneq ( ,$( findstring AMLG12B,$( PLATFORM) ) )
2019-09-12 10:01:38 +02:00
CPUFLAGS += -mcpu= cortex-a73.cortex-a53
2019-08-03 15:40:56 +02:00
NAME = amiberry-AMLG12B
else
2019-09-12 10:01:38 +02:00
CPUFLAGS += -mcpu= cortex-a53
2019-08-03 15:40:56 +02:00
NAME = amiberry-AMLG12A
endif
else ifneq ( ,$( findstring AMLGX,$( PLATFORM) ) )
2019-09-12 10:01:38 +02:00
CPUFLAGS += -mcpu= cortex-a53
2019-09-01 19:27:33 +02:00
CPPFLAGS += -DUSE_RENDER_THREAD
2019-08-03 15:40:56 +02:00
endif
# Rockchip RK3288 e.g. Asus Tinker Board / RK3328 e.g. PINE64 Rock64 / RK3399 e.g. PINE64 RockPro64 - 32-bit userspace
e l s e i f n e q ( , $( findstring RK ,$ ( PLATFORM ) ) )
USE_SDL2 = 1
2019-09-15 16:30:46 +02:00
CPPFLAGS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL2 -DFASTERCYCLES -DUSE_RENDER_THREAD -DSOFTWARE_CURSOR
2019-08-03 15:40:56 +02:00
HAVE_NEON = 1
ifneq ( ,$( findstring RK33,$( PLATFORM) ) )
2019-09-12 21:57:53 +02:00
CPUFLAGS += -mfloat-abi= hard -mfpu= neon-fp-armv8
2019-08-03 15:40:56 +02:00
ifneq ( ,$( findstring RK3399,$( PLATFORM) ) )
2019-09-12 10:01:38 +02:00
CPUFLAGS += -mcpu= cortex-a72.cortex-a53
2019-08-03 15:40:56 +02:00
else ifneq ( ,$( findstring RK3328,$( PLATFORM) ) )
2019-09-12 10:01:38 +02:00
CPUFLAGS += -mcpu= cortex-a53
2019-08-03 15:40:56 +02:00
endif
else ifneq ( ,$( findstring RK3288,$( PLATFORM) ) )
2019-09-12 21:57:53 +02:00
CPUFLAGS += -mcpu= cortex-a17 -mfloat-abi= hard -mfpu= neon-vfpv4
2019-08-03 15:40:56 +02:00
endif
2019-09-10 10:12:05 +02:00
# sun8i Allwinner H2+ / H3 like Orange PI, Nano PI, Banana PI, Tritium, AlphaCore2, MPCORE-HUB
e l s e i f e q ( $( PLATFORM ) , s u n 8 i )
USE_SDL2 = 1
2019-09-12 21:57:53 +02:00
CPUFLAGS += -mcpu= cortex-a7 -mfpu= neon-vfpv4
2019-09-15 16:30:46 +02:00
CPPFLAGS += -DARMV6_ASSEMBLY -D_FILE_OFFSET_BITS= 64 -DARMV6T2 -DUSE_ARMNEON -DARM_HAS_DIV -DUSE_SDL2 -DSOFTWARE_CURSOR -DUSE_RENDER_THREAD
2019-09-10 10:12:05 +02:00
HAVE_NEON = 1
NAME = amiberry-sun8i
ifdef DEBUG
# Otherwise we'll get compilation errors, check https://tls.mbed.org/kb/development/arm-thumb-error-r7-cannot-be-used-in-asm-here
# quote: The assembly code in bn_mul.h is optimized for the ARM platform and uses some registers, including r7 to efficiently do an operation. GCC also uses r7 as the frame pointer under ARM Thumb assembly.
MORE_CFLAGS += -fomit-frame-pointer
e n d i f
2017-12-05 09:12:43 +01:00
e n d i f
2018-01-12 23:19:31 +01:00
RM = rm -f
2019-09-12 21:57:53 +02:00
AS = as
CC = gcc
CXX = g++
2018-12-23 15:34:53 +01:00
STRIP ?= strip
2019-09-12 21:57:53 +02:00
PROG = amiberry
2017-12-05 09:12:43 +01:00
#
# SDL1 options
#
i f n d e f U S E _ S D L 2
all : $( PROG )
2018-11-04 20:53:02 +01:00
SDL_CFLAGS := $( shell sdl-config --cflags)
SDL_LDFLAGS := $( shell sdl-config --libs)
2018-12-02 17:41:20 +01:00
export CPPFLAGS += $( SDL_CFLAGS)
2018-11-04 20:53:02 +01:00
LDFLAGS += $( SDL_LDFLAGS) -lSDL_image -lSDL_ttf -lguichan_sdl -lguichan
2015-10-14 07:49:34 +01:00
e n d i f
2017-12-05 09:12:43 +01:00
#
# SDL2 options
#
i f d e f U S E _ S D L 2
2017-01-27 23:23:03 +01:00
all : guisan $( PROG )
2018-12-11 21:32:46 +01:00
export SDL_CFLAGS := $( shell sdl2-config --cflags)
export SDL_LDFLAGS := $( shell sdl2-config --libs)
2017-01-27 23:23:03 +01:00
2018-12-11 21:32:46 +01:00
CPPFLAGS += $( SDL_CFLAGS) -Iguisan-dev/include
2018-11-04 20:53:02 +01:00
LDFLAGS += $( SDL_LDFLAGS) -lSDL2_image -lSDL2_ttf -lguisan -Lguisan-dev/lib
2017-12-05 09:12:43 +01:00
e n d i f
#
# Common options
#
2019-04-08 20:31:18 +02:00
DEFS = $( XML_CFLAGS) -DAMIBERRY
2018-12-11 21:32:46 +01:00
CPPFLAGS += -Isrc -Isrc/osdep -Isrc/threaddep -Isrc/include -Isrc/archivers $( DEFS)
2018-11-04 20:53:02 +01:00
XML_CFLAGS := $( shell xml2-config --cflags )
2019-09-15 11:35:00 +02:00
LDFLAGS += -Wl,-O1 -Wl,--hash-style= gnu -Wl,--as-needed
2017-12-25 00:58:03 +01:00
2015-05-13 18:47:23 +00:00
i f n d e f D E B U G
2019-09-12 21:57:53 +02:00
CFLAGS += -Ofast -frename-registers
2015-05-13 18:47:23 +00:00
e l s e
2019-08-31 17:30:51 +02:00
CFLAGS += -g -rdynamic -funwind-tables -DDEBUG -Wl,--export-dynamic
2017-12-04 15:49:40 +01:00
e n d i f
2019-09-16 22:35:00 +02:00
#LTO is supposed to reduced code size and increased execution speed. For Amiberry, it does not.
#at least not yet. In fact, the binary is somewhat bigger and almost the same speed. And the link times goes up
#a lot.
2019-09-15 11:35:00 +02:00
i f d e f U S E _ L T O
2019-09-16 22:35:00 +02:00
export CFLAGS += -flto= $( shell nproc) -march= native -fuse-ld= gold -flto-partition= 1to1
export LDFLAGS += $( CFLAGS)
comma = ,
export LDFLAGS:= $( filter-out -Wl$( comma) -O1,$( LDFLAGS) )
2019-09-15 11:35:00 +02:00
e n d i f
2018-01-04 16:13:21 +01:00
i f d e f G C C _ P R O F I L E
2018-01-12 23:19:31 +01:00
CFLAGS += -pg
2018-01-04 16:13:21 +01:00
LDFLAGS += -pg
e n d i f
2017-12-04 15:49:40 +01:00
i f d e f G E N _ P R O F I L E
2018-02-03 01:30:57 +01:00
CFLAGS += -fprofile-generate -fprofile-arcs -fvpt
LDFLAGS += -lgcov
2017-12-04 15:49:40 +01:00
e n d i f
2018-02-03 01:30:57 +01:00
2017-12-04 15:49:40 +01:00
i f d e f U S E _ P R O F I L E
2018-01-12 23:19:31 +01:00
CFLAGS += -fprofile-use -fprofile-correction -fbranch-probabilities -fvpt
2018-02-03 01:30:57 +01:00
LDFLAGS += -lgcov
2017-12-04 15:49:40 +01:00
e n d i f
2018-02-01 10:31:02 +01:00
i f d e f S A N I T I Z E
LDFLAGS += -lasan
CFLAGS += -fsanitize= leak -fsanitize-recover= address
e n d i f
2018-01-12 23:19:31 +01:00
LDFLAGS += -lpthread -lz -lpng -lrt -lxml2 -lFLAC -lmpg123 -ldl -lmpeg2convert -lmpeg2
2019-09-12 10:01:38 +02:00
export ASFLAGS = $( CPUFLAGS)
2018-01-12 23:19:31 +01:00
2019-09-12 10:01:38 +02:00
export CFLAGS := $( CPUFLAGS) $( CFLAGS) -pipe -Wno-shift-overflow -Wno-narrowing $( EXTRA_CFLAGS)
2019-08-31 17:30:51 +02:00
export CXXFLAGS += $( CFLAGS) -std= gnu++14
2018-01-12 23:19:31 +01:00
2018-11-04 20:53:02 +01:00
C_OBJS = \
src/archivers/7z/BraIA64.o \
src/archivers/7z/Delta.o \
src/archivers/7z/Sha256.o \
src/archivers/7z/XzCrc64.o \
src/archivers/7z/XzDec.o
2018-01-12 23:19:31 +01:00
2015-05-13 18:47:23 +00:00
OBJS = \
2016-07-10 13:48:11 +02:00
src/akiko.o \
2017-12-04 15:49:40 +01:00
src/ar.o \
2016-04-24 09:45:29 +00:00
src/aros.rom.o \
2015-05-13 18:47:23 +00:00
src/audio.o \
src/autoconf.o \
src/blitfunc.o \
src/blittable.o \
src/blitter.o \
2016-07-10 13:48:11 +02:00
src/blkdev.o \
src/blkdev_cdimage.o \
2016-04-24 09:45:29 +00:00
src/bsdsocket.o \
2016-08-27 20:39:53 +02:00
src/calc.o \
2017-12-04 15:49:40 +01:00
src/cd32_fmv.o \
src/cd32_fmv_genlock.o \
2016-07-10 13:48:11 +02:00
src/cdrom.o \
2015-05-13 18:47:23 +00:00
src/cfgfile.o \
src/cia.o \
src/crc32.o \
src/custom.o \
2017-12-04 15:49:40 +01:00
src/devices.o \
2015-05-13 18:47:23 +00:00
src/disk.o \
2016-04-24 09:45:29 +00:00
src/diskutil.o \
2018-02-10 00:47:18 +01:00
src/dlopen.o \
2015-05-13 18:47:23 +00:00
src/drawing.o \
2016-04-24 09:45:29 +00:00
src/events.o \
2015-05-13 18:47:23 +00:00
src/expansion.o \
2017-12-04 15:49:40 +01:00
src/fdi2raw.o \
2015-05-13 18:47:23 +00:00
src/filesys.o \
2017-12-04 15:49:40 +01:00
src/flashrom.o \
2015-05-13 18:47:23 +00:00
src/fpp.o \
src/fsdb.o \
src/fsdb_unix.o \
src/fsusage.o \
2017-12-04 15:49:40 +01:00
src/gayle.o \
2016-11-30 22:25:43 +01:00
src/gfxboard.o \
2015-05-13 18:47:23 +00:00
src/gfxutil.o \
src/hardfile.o \
2017-12-04 15:49:40 +01:00
src/hrtmon.rom.o \
src/ide.o \
2015-05-13 18:47:23 +00:00
src/inputdevice.o \
src/keybuf.o \
src/main.o \
src/memory.o \
src/native2amiga.o \
2016-04-24 09:45:29 +00:00
src/rommgr.o \
2017-12-04 15:49:40 +01:00
src/rtc.o \
2015-05-13 18:47:23 +00:00
src/savestate.o \
2017-12-04 15:49:40 +01:00
src/scsi.o \
2016-08-27 20:39:53 +02:00
src/statusline.o \
2015-05-13 18:47:23 +00:00
src/traps.o \
2015-05-17 07:52:43 +00:00
src/uaelib.o \
2015-11-16 22:32:10 +01:00
src/uaeresource.o \
2015-05-13 18:47:23 +00:00
src/zfile.o \
2015-09-09 21:49:41 +02:00
src/zfile_archive.o \
2017-03-30 23:00:20 +02:00
src/archivers/7z/7zAlloc.o \
2016-04-24 09:45:29 +00:00
src/archivers/7z/7zBuf.o \
2015-09-09 21:49:41 +02:00
src/archivers/7z/7zCrc.o \
2017-12-04 15:49:40 +01:00
src/archivers/7z/7zCrcOpt.o \
src/archivers/7z/7zDec.o \
src/archivers/7z/7zIn.o \
2016-04-24 09:45:29 +00:00
src/archivers/7z/7zStream.o \
2016-07-10 13:48:11 +02:00
src/archivers/7z/Bcj2.o \
2016-04-24 09:45:29 +00:00
src/archivers/7z/Bra.o \
src/archivers/7z/Bra86.o \
src/archivers/7z/LzmaDec.o \
2017-12-04 15:49:40 +01:00
src/archivers/7z/Lzma2Dec.o \
src/archivers/7z/Xz.o \
2015-09-09 21:49:41 +02:00
src/archivers/dms/crc_csum.o \
src/archivers/dms/getbits.o \
src/archivers/dms/maketbl.o \
src/archivers/dms/pfile.o \
src/archivers/dms/tables.o \
src/archivers/dms/u_deep.o \
src/archivers/dms/u_heavy.o \
src/archivers/dms/u_init.o \
src/archivers/dms/u_medium.o \
src/archivers/dms/u_quick.o \
src/archivers/dms/u_rle.o \
2015-10-11 14:23:51 +02:00
src/archivers/lha/crcio.o \
src/archivers/lha/dhuf.o \
src/archivers/lha/header.o \
src/archivers/lha/huf.o \
src/archivers/lha/larc.o \
src/archivers/lha/lhamaketbl.o \
src/archivers/lha/lharc.o \
src/archivers/lha/shuf.o \
src/archivers/lha/slide.o \
src/archivers/lha/uae_lha.o \
src/archivers/lha/util.o \
src/archivers/lzx/unlzx.o \
2017-12-04 15:49:40 +01:00
src/archivers/mp2/kjmp2.o \
2015-09-09 21:49:41 +02:00
src/archivers/wrp/warp.o \
src/archivers/zip/unzip.o \
2019-09-02 15:00:35 +02:00
src/caps/caps_amiberry.o \
2016-12-09 19:04:33 +01:00
src/machdep/support.o \
src/osdep/bsdsocket_host.o \
src/osdep/cda_play.o \
src/osdep/charset.o \
src/osdep/fsdb_host.o \
2017-12-04 15:49:40 +01:00
src/osdep/amiberry_hardfile.o \
src/osdep/keyboard.o \
2016-12-09 19:04:33 +01:00
src/osdep/mp3decoder.o \
2017-12-04 15:49:40 +01:00
src/osdep/picasso96.o \
2016-12-09 19:04:33 +01:00
src/osdep/writelog.o \
2017-02-27 14:29:54 +01:00
src/osdep/amiberry.o \
src/osdep/amiberry_filesys.o \
src/osdep/amiberry_input.o \
src/osdep/amiberry_gfx.o \
src/osdep/amiberry_gui.o \
src/osdep/amiberry_rp9.o \
src/osdep/amiberry_mem.o \
2018-03-11 20:09:57 +00:00
src/osdep/amiberry_whdbooter.o \
2016-12-09 19:04:33 +01:00
src/osdep/sigsegv_handler.o \
2017-12-04 15:49:40 +01:00
src/sounddep/sound.o \
2016-12-09 19:04:33 +01:00
src/osdep/gui/UaeRadioButton.o \
src/osdep/gui/UaeDropDown.o \
src/osdep/gui/UaeCheckBox.o \
src/osdep/gui/UaeListBox.o \
src/osdep/gui/InGameMessage.o \
src/osdep/gui/SelectorEntry.o \
2017-12-04 15:49:40 +01:00
src/osdep/gui/ShowHelp.o \
2016-12-09 19:04:33 +01:00
src/osdep/gui/ShowMessage.o \
src/osdep/gui/SelectFolder.o \
src/osdep/gui/SelectFile.o \
src/osdep/gui/CreateFilesysHardfile.o \
src/osdep/gui/EditFilesysVirtual.o \
src/osdep/gui/EditFilesysHardfile.o \
2017-12-26 19:15:42 +01:00
src/osdep/gui/PanelAbout.o \
2016-12-09 19:04:33 +01:00
src/osdep/gui/PanelPaths.o \
2017-12-04 15:49:40 +01:00
src/osdep/gui/PanelQuickstart.o \
2016-12-09 19:04:33 +01:00
src/osdep/gui/PanelConfig.o \
src/osdep/gui/PanelCPU.o \
src/osdep/gui/PanelChipset.o \
2017-12-04 15:49:40 +01:00
src/osdep/gui/PanelCustom.o \
2016-12-09 19:04:33 +01:00
src/osdep/gui/PanelROM.o \
src/osdep/gui/PanelRAM.o \
src/osdep/gui/PanelFloppy.o \
src/osdep/gui/PanelHD.o \
2017-12-04 15:49:40 +01:00
src/osdep/gui/PanelInput.o \
2016-12-09 19:04:33 +01:00
src/osdep/gui/PanelDisplay.o \
src/osdep/gui/PanelSound.o \
src/osdep/gui/PanelMisc.o \
src/osdep/gui/PanelSavestate.o \
src/osdep/gui/main_window.o \
src/osdep/gui/Navigation.o
2017-12-05 09:12:43 +01:00
i f n d e f U S E _ S D L 2
OBJS += src/osdep/gui/sdltruetypefont.o
e n d i f
2017-12-04 15:49:40 +01:00
i f e q ( $( ANDROID ) , 1 )
2018-12-06 21:18:26 +01:00
OBJS += src/osdep/gui/androidsdl_event.o \
src/osdep/gui/PanelOnScreen.o
2017-12-04 15:49:40 +01:00
e n d i f
2019-09-02 14:59:45 +02:00
i f d e f A A R C H 6 4
OBJS += src/osdep/aarch64_helper.o
2019-09-02 22:12:57 +02:00
src/osdep/aarch64_helper.o : src /osdep /aarch 64_helper .s
2019-09-12 10:01:38 +02:00
$( AS) $( ASFLAGS) -o src/osdep/aarch64_helper.o -c src/osdep/aarch64_helper.s
2019-09-12 22:17:38 +02:00
e l s e i f e q ( $( PLATFORM ) , $( filter $ ( PLATFORM ) ,rpi 1 rpi 1-sdl 2 rpi 1-sdl 2-dispmanx ) )
2018-01-12 23:19:31 +01:00
OBJS += src/osdep/arm_helper.o
src/osdep/arm_helper.o : src /osdep /arm_helper .s
2019-09-12 10:01:38 +02:00
$( AS) $( ASFLAGS) -o src/osdep/arm_helper.o -c src/osdep/arm_helper.s
2019-09-02 14:59:45 +02:00
e l s e
OBJS += src/osdep/neon_helper.o
src/osdep/neon_helper.o : src /osdep /neon_helper .s
2019-09-12 10:01:38 +02:00
$( AS) $( ASFLAGS) -o src/osdep/neon_helper.o -c src/osdep/neon_helper.s
2018-01-12 23:19:31 +01:00
e n d i f
2015-10-14 07:49:34 +01:00
2018-12-06 21:18:26 +01:00
OBJS += src/newcpu.o \
src/newcpu_common.o \
src/readcpu.o \
src/cpudefs.o \
src/cpustbl.o \
src/cpuemu_0.o \
src/cpuemu_4.o \
src/cpuemu_11.o \
src/cpuemu_40.o \
src/cpuemu_44.o \
src/jit/compemu.o \
src/jit/compstbl.o \
src/jit/compemu_fpp.o \
src/jit/compemu_support.o
2015-05-13 18:47:23 +00:00
2018-12-11 21:32:46 +01:00
DEPS = $( OBJS:%.o= %.d) $( C_OBJS:%.o= %.d)
2018-01-23 18:45:20 +00:00
2018-11-04 20:53:02 +01:00
$(PROG) : $( OBJS ) $( C_OBJS )
$( CXX) -o $( PROG) $( OBJS) $( C_OBJS) $( LDFLAGS)
2015-05-13 18:47:23 +00:00
i f n d e f D E B U G
2018-02-01 10:28:42 +01:00
# want to keep a copy of the binary before stripping? Then enable the below line
# cp $(PROG) $(PROG)-debug
2015-05-13 18:47:23 +00:00
$( STRIP) $( PROG)
e n d i f
clean :
2018-12-11 21:32:46 +01:00
$( RM) $( PROG) $( PROG) -debug $( C_OBJS) $( OBJS) $( ASMS) $( DEPS)
2018-02-25 16:35:36 +01:00
$( MAKE) -C guisan-dev clean
2017-12-04 15:49:40 +01:00
2018-02-03 01:30:57 +01:00
cleanprofile :
$( RM) $( OBJS:%.o= %.gcda)
2017-12-04 15:49:40 +01:00
bootrom :
od -v -t xC -w8 src/filesys | tail -n +5 | sed -e "s,^.......,," -e "s,[0123456789abcdefABCDEF][0123456789abcdefABCDEF],db(0x&);,g" > src/filesys_bootrom.cpp
touch src/filesys.cpp
2018-01-12 23:19:31 +01:00
guisan :
2018-02-25 16:35:36 +01:00
$( MAKE) -C guisan-dev
2018-12-11 21:32:46 +01:00
- i n c l u d e $( DEPS )