From: Alexis Laferrière Date: Tue, 14 Mar 2017 00:20:57 +0000 (-0400) Subject: nitc: clean up makefile header generation X-Git-Url: http://nitlanguage.org nitc: clean up makefile header generation Signed-off-by: Alexis Laferrière --- diff --git a/src/compiler/abstract_compiler.nit b/src/compiler/abstract_compiler.nit index 5a0b684..224de8b 100644 --- a/src/compiler/abstract_compiler.nit +++ b/src/compiler/abstract_compiler.nit @@ -349,7 +349,14 @@ class MakefileToolchain end var debug = toolcontext.opt_debug.value - makefile.write("CC = ccache cc\nCXX = ccache c++\nCFLAGS = -g{ if not debug then " -O2 " else " "}-Wno-unused-value -Wno-switch -Wno-attributes -Wno-trigraphs\nCINCL =\nLDFLAGS ?= \nLDLIBS ?= -lm {linker_options.join(" ")}\n\n") + makefile.write """ +CC = ccache cc +CXX = ccache c++ +CFLAGS = -g {{{if not debug then "-O2" else ""}}} -Wno-unused-value -Wno-switch -Wno-attributes -Wno-trigraphs +CINCL = +LDFLAGS ?= +LDLIBS ?= -lm {{{linker_options.join(" ")}}} +\n""" makefile.write "\n# SPECIAL CONFIGURATION FLAGS\n" if platform.supports_libunwind then