MainBuildRules: Use $(CC) -E instead of "cpp" as the preprocessor.

"cpp" is the system C preprocessor, not the one from our cross-compiler,
and in the case of my system which does not have GCC installed at all,
it doesn't even exist.

With this, Clang-ARM builds successfully create a "haiku-arm.mmc".
I couldn't get it to output, even after blessing it with "rune",
but that may just be my fault...
This commit is contained in:
Augustin Cavalier
2018-08-17 21:54:56 -04:00
parent dd54d46895
commit 28ab14e35f
+10 -5
View File
@@ -185,15 +185,20 @@ actions AssembleNasm
fi fi
} }
rule CompileDTS rule CompileDTS target : source
{ {
MakeLocate $(<) : $(HAIKU_OUTPUT_DIR) ; CCDEFS on $(target) = [ FDefines $(TARGET_DEFINES_$(TARGET_PACKAGING_ARCH))
Depends $(<) : $(>) ; $(TARGET_DEFINES) ] ;
CC on $(target) = $(TARGET_CC_$(TARGET_PACKAGING_ARCH)) ;
MakeLocate $(target) : $(HAIKU_OUTPUT_DIR) ;
Depends $(target) : $(source) ;
CompileDTS1 $(target) : $(source) ;
} }
actions CompileDTS actions CompileDTS1
{ {
cpp -P -xassembler-with-cpp \ $(CC) -E $(CCDEFS) -P -xassembler-with-cpp \
-I$(HAIKU_TOP)/src/data/dts/arch/$(TARGET_ARCH) \ -I$(HAIKU_TOP)/src/data/dts/arch/$(TARGET_ARCH) \
-I$(HAIKU_TOP)/src/data/dts $(2) \ -I$(HAIKU_TOP)/src/data/dts $(2) \
| dtc -O dtb -o $(1) \ | dtc -O dtb -o $(1) \