aboutsummaryrefslogtreecommitdiff
path: root/src/make.bash
diff options
context:
space:
mode:
authorElias Naur <elias.naur@gmail.com>2013-02-01 08:35:33 -0800
committerRuss Cox <rsc@golang.org>2013-02-01 08:35:33 -0800
commitfe14ee52ccf89fa02366a06fe892a7fcf135e214 (patch)
tree92d863667572fa6f34f5e1bd8e871bde9f3fbfcd /src/make.bash
parentb0a29f393b5672c37355eb7a5f126cc0e1537834 (diff)
downloadgo-fe14ee52ccf89fa02366a06fe892a7fcf135e214.tar.gz
go-fe14ee52ccf89fa02366a06fe892a7fcf135e214.zip
cmd/6c, cmd/6g: add flag to support large-model code generation
Added the -pic flag to 6c and 6g to avoid assembler instructions that cannot use RIP-relative adressing. This is needed to support the -shared mode in 6l. See also: https://golang.org/cl/6926049 https://golang.org/cl/6822078 R=golang-dev, rsc CC=golang-dev https://golang.org/cl/7064048
Diffstat (limited to 'src/make.bash')
-rwxr-xr-xsrc/make.bash7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/make.bash b/src/make.bash
index 1190b93ffa..6c78f93ce6 100755
--- a/src/make.bash
+++ b/src/make.bash
@@ -23,6 +23,9 @@
# GO_LDFLAGS: Additional 5l/6l/8l arguments to use when
# building the commands.
#
+# GO_CCFLAGS: Additional 5c/6c/8c arguments to use when
+# building.
+#
# CGO_ENABLED: Controls cgo usage during the build. Set it to 1
# to include all cgo related files, .c and .go file with "cgo"
# build directive, in the build. Set it to 0 to ignore them.
@@ -129,12 +132,12 @@ echo
if [ "$GOHOSTARCH" != "$GOARCH" -o "$GOHOSTOS" != "$GOOS" ]; then
echo "# Building packages and commands for host, $GOHOSTOS/$GOHOSTARCH."
GOOS=$GOHOSTOS GOARCH=$GOHOSTARCH \
- "$GOTOOLDIR"/go_bootstrap install -gcflags "$GO_GCFLAGS" -ldflags "$GO_LDFLAGS" -v std
+ "$GOTOOLDIR"/go_bootstrap install -ccflags "$GO_CCFLAGS" -gcflags "$GO_GCFLAGS" -ldflags "$GO_LDFLAGS" -v std
echo
fi
echo "# Building packages and commands for $GOOS/$GOARCH."
-"$GOTOOLDIR"/go_bootstrap install -gcflags "$GO_GCFLAGS" -ldflags "$GO_LDFLAGS" -v std
+"$GOTOOLDIR"/go_bootstrap install $GO_FLAGS -ccflags "$GO_CCFLAGS" -gcflags "$GO_GCFLAGS" -ldflags "$GO_LDFLAGS" -v std
echo
rm -f "$GOTOOLDIR"/go_bootstrap