Commit ea931195 authored by Jérome Perrin's avatar Jérome Perrin

component/golang: build with latest slapos gcc

Golang needs a recent enough version of ld (>2.2) and of gcc ( > 5.5 )

This also introduces multiple gcc versions in gcc component, to have finer control over which component uses which version of gcc.

/reviewed-on nexedi/slapos!436
parents 62d92eae 3e3b3e00
# GNU C Compiler # GNU C Compiler
# Mostly required to support languages different than C or C++ # Required to use a "known good version" of the compiler or to support languages different than C or C++
[buildout] [buildout]
extends = extends =
../gettext/buildout.cfg ../gettext/buildout.cfg
...@@ -50,3 +50,23 @@ configure-options = ...@@ -50,3 +50,23 @@ configure-options =
environment = environment =
LDFLAGS=-Wl,-rpath=${gmp:location}/lib -Wl,-rpath=${mpc:location}/lib -Wl,-rpath=${mpfr:location}/lib LDFLAGS=-Wl,-rpath=${gmp:location}/lib -Wl,-rpath=${mpc:location}/lib -Wl,-rpath=${mpfr:location}/lib
PATH=${perl:location}/bin:${tar:location}/bin:%(PATH)s PATH=${perl:location}/bin:${tar:location}/bin:%(PATH)s
[gcc-8.2]
recipe = slapos.recipe.cmmi
shared = true
url = https://ftp.gnu.org/gnu/gcc/gcc-8.2.0/gcc-8.2.0.tar.gz
md5sum = ee04f0c22a941f5f17d93809387f2729
configure-options =
--disable-bootstrap
--disable-multilib
--with-gmp=${gmp:location}
--with-mpfr=${mpfr:location}
--with-mpc=${mpc:location}
--enable-languages="c,c++,fortran"
--with-isl=${isl:location}
--with-ld=${binutils:location}/bin/ld
--with-as=${binutils:location}/bin/as
environment =
LDFLAGS=-Wl,-rpath=${gmp:location}/lib -Wl,-rpath=${isl:location}/lib -Wl,-rpath=${mpc:location}/lib -Wl,-rpath=${mpfr:location}/lib
PATH=${binutils:location}/bin:${gettext:location}/bin:${perl:location}/bin:${tar:location}/bin:%(PATH)s
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
[buildout] [buildout]
extends = extends =
../findutils/buildout.cfg ../findutils/buildout.cfg
../gcc/buildout.cfg
../git/buildout.cfg ../git/buildout.cfg
../pkgconfig/buildout.cfg ../pkgconfig/buildout.cfg
...@@ -18,6 +19,7 @@ make-targets= cd src && ./all.bash && cp -alf .. ${:location} ...@@ -18,6 +19,7 @@ make-targets= cd src && ./all.bash && cp -alf .. ${:location}
# some testdata files have an issue with slapos.extension.strip. # some testdata files have an issue with slapos.extension.strip.
post-install = ${findutils:location}/bin/find ${:location}/src -type d -name testdata -exec rm -rf {} \; || true post-install = ${findutils:location}/bin/find ${:location}/src -type d -name testdata -exec rm -rf {} \; || true
environment = environment =
PATH=${gcc-8.2:location}/bin:%(PATH)s
GOROOT_FINAL=${:location} GOROOT_FINAL=${:location}
${:environment-extra} ${:environment-extra}
......
...@@ -29,3 +29,4 @@ environment = ...@@ -29,3 +29,4 @@ environment =
LD_LIBRARY_PATH=${gcc:location}/lib:${gcc:location}/lib64 LD_LIBRARY_PATH=${gcc:location}/lib:${gcc:location}/lib64
LDFLAGS=-Wl,-rpath=${gcc:location}/lib -Wl,-rpath=${gcc:location}/lib64 -L${zlib:location}/lib -L${openssl:location}/lib -Wl,-rpath=${tokyocabinet:location}/lib -Wl,-rpath=${messagepack:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${openssl:location}/lib LDFLAGS=-Wl,-rpath=${gcc:location}/lib -Wl,-rpath=${gcc:location}/lib64 -L${zlib:location}/lib -L${openssl:location}/lib -Wl,-rpath=${tokyocabinet:location}/lib -Wl,-rpath=${messagepack:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${openssl:location}/lib
PATH=${gcc:location}/bin:${patch:location}/bin:%(PATH)s PATH=${gcc:location}/bin:${patch:location}/bin:%(PATH)s
# KumoFS is known not to build with gcc>6, so we use our own gcc which is 5.5
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment