-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
50 lines (40 loc) · 847 Bytes
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
cmake_minimum_required(VERSION 3.0)
# for clangd (LSP)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
# target name "noborunoca.rom"
project(noborunoca.rom C ASM)
enable_language(ASM)
# for debug
# set(CMAKE_VERBOSE_MAKEFILE 1)
include(./cmake/macros.cmake)
add_source_files(
./src/c/noborunoca.c
./src/asm/psgdriver.asm
./src/asm/define_music.asm
./src/asm/define_graphic.asm
)
add_compile_flags(C
+msx
-O3
-I$ENV{Z88DK_HOME}/include
-Isrc/c
-vn
-llib3d
-lm
-lndos
-lmsxbios
-m
# -debug
# https://github.com/z88dk/z88dk/wiki/Classic-allocation#automatic-heap-configuration
-DAMALLOC
)
add_compile_flags(ASM
+msx
--list
)
add_compile_flags(LD
-create-app
-subtype=rom
)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ../dist)
add_executable(${PROJECT_NAME} ${SOURCE_FILES})