golang-1.4.3.recipe revision bbb51803
1SUMMARY="The Go Programming Language"
2DESCRIPTION="The Go Programming Language is an open source project to make \
3programmers more productive.
4
5Go is expressive, concise, clean, and efficient. Its concurrency \
6mechanisms make it easy to write programs that get the most out of multicore \
7and networked machines, while its novel type system enables flexible and \
8modular program construction. Go compiles quickly to machine code yet has the \
9convenience of garbage collection and the power of run-time reflection. It's a \
10fast, statically typed, compiled language that feels like a dynamically typed, \
11interpreted language."
12HOMEPAGE="https://golang.org/go"
13COPYRIGHT="2009-2018 The Go Authors"
14LICENSE="BSD (3-clause)"
15REVISION="2"
16SOURCE_URI="https://dl.google.com/go/go$portVersion.src.tar.gz"
17CHECKSUM_SHA256="9947fc705b0b841b5938c48b22dc33e9647ec0752bae66e50278df4f23f64959"
18SOURCE_DIR="go"
19PATCHES="golang-$portVersion.patchset"
20
21ARCHITECTURES="!x86_gcc2 !x86 ?x86_64"
22SECONDARY_ARCHITECTURES="!x86"
23
24GLOBAL_WRITABLE_FILES="
25	non-packaged/lib/go directory keep-old
26	"
27
28PROVIDES="
29	golang$secondaryArchSuffix = $portVersion
30	cmd:go$secondaryArchSuffix = $portVersion
31	cmd:gofmt$secondaryArchSuffix = $portVersion
32	cmd:godoc$secondaryArchSuffix = $portVersion
33	"
34if [ -n "$secondaryArchSuffix" ]; then
35PROVIDES="$PROVIDES
36	cmd:go = $portVersion
37	cmd:gofmt = $portVersion
38	cmd:godoc = $portVersion
39	"
40fi
41
42REQUIRES="
43	haiku$secondaryArchSuffix
44	"
45BUILD_REQUIRES="
46	haiku${secondaryArchSuffix}_devel
47	"
48
49BUILD_PREREQUIRES="
50	cmd:gcc$secondaryArchSuffix
51	cmd:git
52	"
53
54BUILD()
55{
56	echo "$portVersion" > VERSION
57	export GOROOT_FINAL=$prefix/non-packaged/lib/go/
58	cd src
59	DISABLE_ASLR=1 ./make.bash
60	cd ..
61	export GOPATH=/tmp
62	export GOROOT="$sourceDir"
63}
64
65INSTALL()
66{
67	mkdir -p $prefix/non-packaged/lib/go/
68	cp -r src pkg doc $prefix/non-packaged/lib/go/
69	mkdir -p $binDir
70	cp bin/* $binDir
71}
72
73TEST()
74{
75	cd src
76	DISABLE_ASLR=1 ./all.bash
77}
78