813a4ea107
* Add support for MKS Robin TFT display - Add support for MKS Robin TFT display and encoder for MKS Robin board. - Generic 128x64 UI with x2 upscale is used (for now). - Tested on MKS Robin TFT V2.0 with ST7789V controller.
55 lines
1.3 KiB
Python
55 lines
1.3 KiB
Python
from __future__ import print_function
|
|
import sys
|
|
|
|
#dynamic build flags for generic compile options
|
|
if __name__ == "__main__":
|
|
args = " ".join([ "-std=gnu11",
|
|
"-std=gnu++11",
|
|
"-Os",
|
|
"-mcpu=cortex-m3",
|
|
"-mthumb",
|
|
|
|
"-ffreestanding",
|
|
"-fsigned-char",
|
|
"-fno-move-loop-invariants",
|
|
"-fno-strict-aliasing",
|
|
|
|
"--specs=nano.specs",
|
|
"--specs=nosys.specs",
|
|
|
|
"-IMarlin/src/HAL/HAL_STM32F1",
|
|
|
|
"-MMD",
|
|
"-MP",
|
|
"-DTARGET_STM32F1"
|
|
])
|
|
|
|
for i in range(1, len(sys.argv)):
|
|
args += " " + sys.argv[i]
|
|
|
|
print(args)
|
|
|
|
# extra script for linker options
|
|
else:
|
|
from SCons.Script import DefaultEnvironment
|
|
env = DefaultEnvironment()
|
|
env.Append(
|
|
ARFLAGS=["rcs"],
|
|
|
|
ASFLAGS=["-x", "assembler-with-cpp"],
|
|
|
|
CXXFLAGS=[
|
|
"-fabi-version=0",
|
|
"-fno-use-cxa-atexit",
|
|
"-fno-threadsafe-statics"
|
|
],
|
|
LINKFLAGS=[
|
|
"-Os",
|
|
"-mcpu=cortex-m3",
|
|
"-ffreestanding",
|
|
"-mthumb",
|
|
"--specs=nano.specs",
|
|
"--specs=nosys.specs",
|
|
"-u_printf_float",
|
|
],
|
|
)
|