I happened to notice in jdk/make/common/shared/Sanity.gmk:
sane-gcc-compiler:
ifeq ($(PLATFORM), solaris)
ifndef OPENJDK
@if [ -r $(GCC_COMPILER_PATH) ]; then \
....
fi
endif
ifeq ($(PLATFORM), linux)
Looks to me like there's a misplaced endif there.
David