BuildPlatformMain now uses the original DEFINES. Otherwise we e.g. get __HAIKU__ although compiling under R5.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13420 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -27,6 +27,8 @@ if ! $(INVOCATION_SUBDIR_SET) {
|
|||||||
|
|
||||||
} # vanilla Jam compatibility
|
} # vanilla Jam compatibility
|
||||||
|
|
||||||
|
BUILD_PLATFORM_DEFINES = $(DEFINES) ;
|
||||||
|
|
||||||
# The directory for build system specific files
|
# The directory for build system specific files
|
||||||
OBOS_BUILD_DIR = [ FDirName $(OBOS_TOP) build ] ;
|
OBOS_BUILD_DIR = [ FDirName $(OBOS_TOP) build ] ;
|
||||||
|
|
||||||
@@ -2031,11 +2033,14 @@ rule BuildPlatformMain
|
|||||||
SetupDefaultIncludes ;
|
SetupDefaultIncludes ;
|
||||||
}
|
}
|
||||||
|
|
||||||
# Remove `-nostdinc' from CCFLAGS and C++FLAGS.
|
# Remove `-nostdinc' from CCFLAGS and C++FLAGS. Set DEFINES back to what
|
||||||
|
# was originally defined for the build platform.
|
||||||
local oldCCFLAGS = $(CCFLAGS) ;
|
local oldCCFLAGS = $(CCFLAGS) ;
|
||||||
local oldC++FLAGS = $(C++FLAGS) ;
|
local oldC++FLAGS = $(C++FLAGS) ;
|
||||||
|
local oldDefines = $(DEFINES) ;
|
||||||
CCFLAGS = [ Filter $(CCFLAGS) : -nostdinc ] ;
|
CCFLAGS = [ Filter $(CCFLAGS) : -nostdinc ] ;
|
||||||
C++FLAGS = [ Filter $(C++FLAGS) : -nostdinc ] ;
|
C++FLAGS = [ Filter $(C++FLAGS) : -nostdinc ] ;
|
||||||
|
DEFINES = $(BUILD_PLATFORM_DEFINES) ;
|
||||||
|
|
||||||
Main $(1) : $(2) ;
|
Main $(1) : $(2) ;
|
||||||
|
|
||||||
@@ -2045,6 +2050,7 @@ rule BuildPlatformMain
|
|||||||
# Reset CCFLAGS and C++FLAGS to original values.
|
# Reset CCFLAGS and C++FLAGS to original values.
|
||||||
CCFLAGS = $(oldCCFLAGS) ;
|
CCFLAGS = $(oldCCFLAGS) ;
|
||||||
C++FLAGS = $(oldC++FLAGS) ;
|
C++FLAGS = $(oldC++FLAGS) ;
|
||||||
|
DEFINES = $(oldDefines) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
rule BuildPlatformTest
|
rule BuildPlatformTest
|
||||||
|
|||||||
Reference in New Issue
Block a user