-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
request from niclas helpdesk Go Update 08.11.17
- Loading branch information
Showing
1 changed file
with
66 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
#!/usr/bin/env beesh | ||
|
||
# BEE_VERSION go-1.9.2-0 | ||
|
||
SRCURL[0]="https://redirector.gvt1.com/edgedl/go/go${PKGVERSION}.src.tar.gz" | ||
|
||
# PATCHURL+=() | ||
|
||
# EXCLUDE+=() | ||
|
||
INCLUDE=src | ||
|
||
build_in_sourcedir | ||
|
||
sourcesubdir_append src | ||
|
||
|
||
#mee_extract() { | ||
# bee_extract "${@}" | ||
#} | ||
|
||
#mee_patch() { | ||
# bee_patch "${@}" | ||
#} | ||
|
||
#mee_configure() { | ||
# bee_configure | ||
#} | ||
|
||
mee_build() { | ||
export GOROOT_BOOTSTRAP=${PREFIX} \ | ||
GOROOT_FINAL=${LIBDIR}/go-${PKGVERSION} | ||
start_cmd ${S}/make.bash #${BEE_MAKEFLAGS} | ||
exit | ||
} | ||
|
||
mee_install() { | ||
# Install Binaries | ||
start_cmd mkdir -p ${D}${BINDIR} | ||
start_cmd mkdir -p ${D}${LIBDIR}/go-${PKGVERSION} | ||
start_cmd cp -r ${S}/../bin ${D}${LIBDIR}/go-${PKGVERSION} | ||
cd ${D}${BINDIR} | ||
start_cmd ln -s ../lib/go-${PKGVERSION}/bin/go go | ||
start_cmd ln -s ../lib/go-${PKGVERSION}/bin/gofmt gofmt | ||
|
||
# Install standardlibs https://golang.org/pkg/#stdlib | ||
LIBS="archive bufio builtin bytes compress container context crypto database \ | ||
debug encoding errors expvar flag fmt go hash html image index internal io \ | ||
log math mime net os path plugin reflect regexp runtime sort strconv strings \ | ||
sync syscall testing text time unicode unsafe" | ||
|
||
start_cmd ${S}/../bin/go install -buildmode=shared std | ||
|
||
start_cmd mkdir -p ${D}${LIBDIR}/go-${PKGVERSION}/src | ||
for i in $LIBS; do | ||
start_cmd cp -r ${S}/${i} ${D}${LIBDIR}/go-${PKGVERSION}/src | ||
done | ||
|
||
#Install tools for go | ||
start_cmd mkdir -p ${D}${LIBDIR}/go-${PKGVERSION}/pkg | ||
start_cmd cp -r ${S}/../pkg/tool ${D}${LIBDIR}/go-${PKGVERSION}/pkg | ||
start_cmd cp -r ${S}/../pkg/include ${D}${LIBDIR}/go-${PKGVERSION}/pkg | ||
start_cmd cp -r ${S}/../pkg/linux_amd64 ${D}${LIBDIR}/go-${PKGVERSION}/pkg | ||
start_cmd cp -r ${S}/../pkg/linux_amd64_dynlink ${D}${LIBDIR}/go-${PKGVERSION}/pkg | ||
} | ||
## by default this may be 'make install DESTDIR="${D}"' |