@ -32,10 +32,6 @@ PKG_BUILD_DIR:=$(BUILD_DIR)/go-$(PKG_VERSION)
PKG_BUILD_PARALLEL := 1
PKG_BUILD_PARALLEL := 1
PKG_USE_MIPS16 := 0
PKG_USE_MIPS16 := 0
PKG_GO_WORK_DIR := $( PKG_BUILD_DIR) /.go_work
PKG_GO_HOST_CACHE_DIR := $( PKG_GO_WORK_DIR) /host_cache
PKG_GO_TARGET_CACHE_DIR := $( PKG_GO_WORK_DIR) /target_cache
PKG_GO_PREFIX := /usr
PKG_GO_PREFIX := /usr
PKG_GO_VERSION_ID := $( GO_VERSION_MAJOR_MINOR)
PKG_GO_VERSION_ID := $( GO_VERSION_MAJOR_MINOR)
PKG_GO_ROOT := $( PKG_GO_PREFIX) /lib/go-$( PKG_GO_VERSION_ID)
PKG_GO_ROOT := $( PKG_GO_PREFIX) /lib/go-$( PKG_GO_VERSION_ID)
@ -43,9 +39,6 @@ PKG_GO_ROOT:=$(PKG_GO_PREFIX)/lib/go-$(PKG_GO_VERSION_ID)
HOST_BUILD_DIR := $( BUILD_DIR_HOST) /go-$( PKG_VERSION)
HOST_BUILD_DIR := $( BUILD_DIR_HOST) /go-$( PKG_VERSION)
HOST_BUILD_PARALLEL := 1
HOST_BUILD_PARALLEL := 1
HOST_GO_WORK_DIR := $( HOST_BUILD_DIR) /.go_work
HOST_GO_CACHE_DIR := $( HOST_GO_WORK_DIR) /cache
HOST_GO_PREFIX := $( STAGING_DIR_HOSTPKG)
HOST_GO_PREFIX := $( STAGING_DIR_HOSTPKG)
HOST_GO_VERSION_ID := cross
HOST_GO_VERSION_ID := cross
HOST_GO_ROOT := $( HOST_GO_PREFIX) /lib/go-$( HOST_GO_VERSION_ID)
HOST_GO_ROOT := $( HOST_GO_PREFIX) /lib/go-$( HOST_GO_VERSION_ID)
@ -78,8 +71,6 @@ BOOTSTRAP_SOURCE_URL:=$(GO_SOURCE_URLS)
BOOTSTRAP_HASH := f4ff5b5eb3a3cae1c993723f3eab519c5bae18866b5e5f96fe1102f0cb5c3e52
BOOTSTRAP_HASH := f4ff5b5eb3a3cae1c993723f3eab519c5bae18866b5e5f96fe1102f0cb5c3e52
BOOTSTRAP_BUILD_DIR := $( HOST_BUILD_DIR) /.go_bootstrap
BOOTSTRAP_BUILD_DIR := $( HOST_BUILD_DIR) /.go_bootstrap
BOOTSTRAP_WORK_DIR := $( BOOTSTRAP_BUILD_DIR) /.go_work
BOOTSTRAP_CACHE_DIR := $( BOOTSTRAP_WORK_DIR) /cache
BOOTSTRAP_GO_VALID_OS_ARCH := \
BOOTSTRAP_GO_VALID_OS_ARCH := \
darwin_386 darwin_amd64 \
darwin_386 darwin_amd64 \
@ -236,19 +227,16 @@ define Host/Compile
$( call GoCompiler/Bootstrap/CheckHost,$( BOOTSTRAP_GO_VALID_OS_ARCH) )
$( call GoCompiler/Bootstrap/CheckHost,$( BOOTSTRAP_GO_VALID_OS_ARCH) )
$( call GoCompiler/Host/CheckHost,$( HOST_GO_VALID_OS_ARCH) )
$( call GoCompiler/Host/CheckHost,$( HOST_GO_VALID_OS_ARCH) )
mkdir -p \
$( BOOTSTRAP_CACHE_DIR) \
$( HOST_GO_CACHE_DIR)
mkdir -p $( GO_BUILD_CACHE_DIR)
$( call GoCompiler/Bootstrap/Make, \
$( call GoCompiler/Bootstrap/Make, \
GOCACHE = $( BOOTSTRAP_CACHE_DIR) \
CC = $( HOSTCC_NOCACHE) \
CC = $( HOSTCC_NOCACHE) \
CXX = $( HOSTCXX_NOCACHE) \
CXX = $( HOSTCXX_NOCACHE) \
)
)
$( call GoCompiler/Host/Make, \
$( call GoCompiler/Host/Make, \
GOROOT_BOOTSTRAP = $( if $( USE_DEFAULT_BOOTSTRAP) ,$( BOOTSTRAP_BUILD_DIR) ,$( EXTERNAL_BOOTSTRAP_DIR) ) \
GOROOT_BOOTSTRAP = $( if $( USE_DEFAULT_BOOTSTRAP) ,$( BOOTSTRAP_BUILD_DIR) ,$( EXTERNAL_BOOTSTRAP_DIR) ) \
GOCACHE = $( HOST_GO _CACHE_DIR) \
GOCACHE = $( GO_BUILD _CACHE_DIR) \
CC = $( HOSTCC_NOCACHE) \
CC = $( HOSTCC_NOCACHE) \
CXX = $( HOSTCXX_NOCACHE) \
CXX = $( HOSTCXX_NOCACHE) \
)
)
@ -259,7 +247,7 @@ define Host/Compile
( \
( \
cd $( HOST_BUILD_DIR) /bin ; \
cd $( HOST_BUILD_DIR) /bin ; \
$( CP) go go-nopie ; \
$( CP) go go-nopie ; \
GOCACHE = $( HOST_GO _CACHE_DIR) \
GOCACHE = $( GO_BUILD _CACHE_DIR) \
GOENV = off \
GOENV = off \
CC = $( HOSTCC_NOCACHE) \
CC = $( HOSTCC_NOCACHE) \
CXX = $( HOSTCXX_NOCACHE) \
CXX = $( HOSTCXX_NOCACHE) \
@ -299,15 +287,13 @@ define Host/Uninstall
e n d e f
e n d e f
d e f i n e B u i l d / C o m p i l e
d e f i n e B u i l d / C o m p i l e
mkdir -p \
$( PKG_GO_HOST_CACHE_DIR) \
$( PKG_GO_TARGET_CACHE_DIR)
mkdir -p $( GO_BUILD_CACHE_DIR)
@echo "Building target Go first stage"
@echo "Building target Go first stage"
$( call GoCompiler/Package/Make, \
$( call GoCompiler/Package/Make, \
GOROOT_BOOTSTRAP = $( HOST_GO_ROOT) \
GOROOT_BOOTSTRAP = $( HOST_GO_ROOT) \
GOCACHE = $( PKG_GO_HOST _CACHE_DIR) \
GOCACHE = $( GO_BUILD _CACHE_DIR) \
GO_GCC_HELPER_CC = " $( HOSTCC) " \
GO_GCC_HELPER_CC = " $( HOSTCC) " \
GO_GCC_HELPER_CXX = " $( HOSTCXX) " \
GO_GCC_HELPER_CXX = " $( HOSTCXX) " \
GO_GCC_HELPER_PATH = $$ $$ PATH \
GO_GCC_HELPER_PATH = $$ $$ PATH \
@ -327,7 +313,7 @@ define Build/Compile
export $( GO_PKG_TARGET_VARS) ; \
export $( GO_PKG_TARGET_VARS) ; \
$( CP) go go-host ; \
$( CP) go go-host ; \
GOROOT_FINAL = $( PKG_GO_ROOT) \
GOROOT_FINAL = $( PKG_GO_ROOT) \
GOCACHE = $( PKG_GO_TARGET _CACHE_DIR) \
GOCACHE = $( GO_BUILD _CACHE_DIR) \
GOENV = off \
GOENV = off \
GO_GCC_HELPER_CC = " $( TARGET_CC) " \
GO_GCC_HELPER_CC = " $( TARGET_CC) " \
GO_GCC_HELPER_CXX = " $( TARGET_CXX) " \
GO_GCC_HELPER_CXX = " $( TARGET_CXX) " \