mirror of
https://github.com/G42makes/mp-s7.git
synced 2025-02-20 04:28:58 +00:00
added some more infrastructure, and ignore some test code folders
This commit is contained in:
parent
227c510f86
commit
47c2090c8e
2
.gitignore
vendored
2
.gitignore
vendored
@ -197,3 +197,5 @@ dmypy.json
|
||||
.pyre/
|
||||
|
||||
# End of https://www.gitignore.io/api/c,c++,cmake,python
|
||||
|
||||
testcode/
|
||||
|
30
CMakeLists.txt
Normal file
30
CMakeLists.txt
Normal file
@ -0,0 +1,30 @@
|
||||
#Initial version referenced from: https://github.com/macosten/PetProject-m68k/blob/master/CMakeLists.txt
|
||||
|
||||
# To use this example as a standalone project using CMake:
|
||||
# mkdir build
|
||||
# cd build
|
||||
# cmake .. -DCMAKE_TOOLCHAIN_FILE=path/to/Retro68-build/toolchain/m68k-apple-macos/cmake/retro68.toolchain.cmake
|
||||
# make
|
||||
|
||||
cmake_minimum_required(VERSION 2.8)
|
||||
|
||||
add_application(MicroPython
|
||||
main.c
|
||||
uart_core.c
|
||||
#lib/utils/printf.c
|
||||
#lib/utils/stdout_helpers.c
|
||||
#lib/utils/pyexec.c
|
||||
#lib/libc/string0.c
|
||||
#lib/mp-readline/readline.c
|
||||
#$(BUILD)/_frozen_mpy.c
|
||||
)
|
||||
|
||||
# Enable -ffunction-sections and -gc-sections to make the app as small as possible
|
||||
# On 68K, also enable --mac-single to build it as a single-segment app (so that this code path doesn't rot)
|
||||
set_target_properties(MicroPython PROPERTIES COMPILE_OPTIONS -ffunction-sections)
|
||||
if(CMAKE_SYSTEM_NAME MATCHES Retro68)
|
||||
set_target_properties(MicroPython PROPERTIES LINK_FLAGS "-Wl,-gc-sections -Wl,--mac-single")
|
||||
|
||||
else()
|
||||
set_target_properties(MicroPython PROPERTIES LINK_FLAGS "-Wl,-gc-sections")
|
||||
endif()
|
Loading…
x
Reference in New Issue
Block a user