The configure script now sets the variable GCC_RAW_VERSION which is
parsed in Jamrules into a list (`.' and `-' are considered delimiters) written into GCC_VERSION. E.g. for the GeekGadgets compiler expect GCC_VERSION to be set to `2 9 beos 000224'. So, GCC_VERSION[1] should contain the major version, GCC_VERSION[2] the middle one. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@4997 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -46,6 +46,27 @@ LOCATE on $(HCACHEFILE) $(JCACHEFILE) = $(OBOS_BUILD_DIR) ;
|
||||
include BuildConfig ;
|
||||
}
|
||||
|
||||
# analyze GCC version
|
||||
if ! $(GCC_RAW_VERSION) {
|
||||
ECHO "Variable GCC_RAW_VERSION not set. Please run ./configure or" ;
|
||||
EXIT "specify it manually." ;
|
||||
}
|
||||
GCC_VERSION = ;
|
||||
{
|
||||
# split the raw version string at `.' and `-' characters
|
||||
local version = $(GCC_RAW_VERSION) ;
|
||||
while $(version) {
|
||||
local split = [ Match "([^.-]*)[.-](.*)" : $(version) ] ;
|
||||
if $(split) {
|
||||
GCC_VERSION += $(split[1]) ;
|
||||
version = $(split[2]) ;
|
||||
} else {
|
||||
GCC_VERSION += $(version) ;
|
||||
version = ;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
# Save the platform default headers.
|
||||
PLATFORM_DEFAULT_HEADERS = $(HDRS) ;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user