Commit d7c14852 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

add minimal gcc in varnish software release.

that is required to compile varnish VCL in runtime.
parent be1691d5
...@@ -33,7 +33,7 @@ environment = ...@@ -33,7 +33,7 @@ environment =
[ppl] [ppl]
recipe = slapos.recipe.cmmi recipe = slapos.recipe.cmmi
# we should use version 0.10.x for gcc-4.5 # we should use version 0.10.x for gcc-4.5
url = http://www.cs.unipr.it/ppl/Download/ftp/releases/0.10.2/ppl-0.10.2.tar.bz2 url = http://bugseng.com/products/ppl/download/ftp/releases/0.10.2/ppl-0.10.2.tar.bz2
md5sum = 5667111f53150618b0fa522ffc53fc3e md5sum = 5667111f53150618b0fa522ffc53fc3e
configure-options = configure-options =
--with-libgmp-prefix=${gmp:location} --with-libgmp-prefix=${gmp:location}
...@@ -85,9 +85,6 @@ patches = ...@@ -85,9 +85,6 @@ patches =
${gcc-multiarch.patch:location}/${gcc-multiarch.patch:filename} ${gcc-multiarch.patch:location}/${gcc-multiarch.patch:filename}
patch-options = -p2 patch-options = -p2
configure-command = make clean \\; make distclean \\; ./configure configure-command = make clean \\; make distclean \\; ./configure
# GMP does not correctly detect achitecture so it have to be given
# as slapos.recipe.cmmi is using shell expansion in subproceses
# backticks are working
configure-options = configure-options =
--disable-bootstrap --disable-bootstrap
--enable-languages="c,c++" --enable-languages="c,c++"
...@@ -97,12 +94,30 @@ configure-options = ...@@ -97,12 +94,30 @@ configure-options =
--with-mpc=${mpc:location} --with-mpc=${mpc:location}
--with-ppl=${ppl:location} --with-ppl=${ppl:location}
--with-cloog=${cloog-ppl:location} --with-cloog=${cloog-ppl:location}
--with-ecj-jar=${ecj:location}/${ecj:filename}
--prefix=${buildout:parts-directory}/${:_buildout_section_name_} --prefix=${buildout:parts-directory}/${:_buildout_section_name_}
environment = environment =
LDFLAGS=-Wl,-rpath=${mpfr:location}/lib -Wl,-rpath=${gmp:location}/lib -Wl,-rpath=${mpc:location}/lib -Wl,-rpath=${ppl:location}/lib -Wl,-rpath=${cloog-ppl:location}/lib LDFLAGS=-Wl,-rpath=${mpfr:location}/lib -Wl,-rpath=${gmp:location}/lib -Wl,-rpath=${mpc:location}/lib -Wl,-rpath=${ppl:location}/lib -Wl,-rpath=${cloog-ppl:location}/lib
PATH=${zip:location}/bin:%(PATH)s # make install does not work when several core are used
make-targets = install -j1
[gcc-minimal]
recipe = slapos.recipe.cmmi
url = http://ftp.gnu.org/gnu/gcc/gcc-4.5.4/gcc-core-4.5.4.tar.bz2
md5sum = ca62e442629a9a7710f5d797bf1b521c
patches =
${gcc-multiarch.patch:location}/${gcc-multiarch.patch:filename}
patch-options = -p2
configure-options =
--disable-bootstrap
--enable-languages=c
--disable-multilib
--with-gmp=${gmp:location}
--with-mpfr=${mpfr:location}
--with-mpc=${mpc:location}
--without-ppl
--without-cloog
environment =
LDFLAGS=-Wl,-rpath=${mpfr:location}/lib -Wl,-rpath=${gmp:location}/lib -Wl,-rpath=${mpc:location}/lib
# make install does not work when several core are used # make install does not work when several core are used
make-targets = install -j1 make-targets = install -j1
......
...@@ -73,6 +73,7 @@ class Recipe(GenericSlapRecipe): ...@@ -73,6 +73,7 @@ class Recipe(GenericSlapRecipe):
varnishd_pid_file=self.options['pid-file'], varnishd_pid_file=self.options['pid-file'],
varnish_instance_name=self.options['varnish-instance-name'], varnish_instance_name=self.options['varnish-instance-name'],
varnish_data=self.options['varnish-data'], varnish_data=self.options['varnish-data'],
gcc_location=self.options['gcc-location'],
shell_path=self.options['shell-path'], shell_path=self.options['shell-path'],
vcl_file=self.options['vcl-file'], vcl_file=self.options['vcl-file'],
backend_port=backend_port, backend_port=backend_port,
......
...@@ -10,5 +10,5 @@ DAEMON_OPTS="-F \ ...@@ -10,5 +10,5 @@ DAEMON_OPTS="-F \
PIDFILE=%(varnishd_pid_file)s PIDFILE=%(varnishd_pid_file)s
# exporting PATH here so that we will pass the PATH variable to the subprocess # exporting PATH here so that we will pass the PATH variable to the subprocess
export PATH export PATH="%(gcc_location)s:$PATH"
exec %(varnishd_binary)s -P ${PIDFILE} ${DAEMON_OPTS} 2>&1 exec %(varnishd_binary)s -P ${PIDFILE} ${DAEMON_OPTS} 2>&1
...@@ -39,6 +39,7 @@ varnishd-binary = {{ parameter_dict['varnish'] }}/sbin/varnishd ...@@ -39,6 +39,7 @@ varnishd-binary = {{ parameter_dict['varnish'] }}/sbin/varnishd
varnishlog-binary = {{ parameter_dict['varnish'] }}/bin/varnishlog varnishlog-binary = {{ parameter_dict['varnish'] }}/bin/varnishlog
shell-path = {{ parameter_dict['dash'] }}/bin/dash shell-path = {{ parameter_dict['dash'] }}/bin/dash
stunnel-binary = {{ parameter_dict['stunnel'] }}/bin/stunnel stunnel-binary = {{ parameter_dict['stunnel'] }}/bin/stunnel
gcc-location = {{ parameter_dict['gcc'] }}/bin
# Configuration by VCL # Configuration by VCL
vcl-file = ${rootdirectory:etc}/default.vcl vcl-file = ${rootdirectory:etc}/default.vcl
pid-file = ${basedirectory:run}/varnishd.pid pid-file = ${basedirectory:run}/varnishd.pid
......
...@@ -27,6 +27,7 @@ context = ...@@ -27,6 +27,7 @@ context =
[dynamic-template-varnish-parameters] [dynamic-template-varnish-parameters]
dash = {{ dash_location }} dash = {{ dash_location }}
dcron = {{ dcron_location }} dcron = {{ dcron_location }}
gcc = {{ gcc_location }}
gzip = {{ gzip_location }} gzip = {{ gzip_location }}
logrotate = {{ logrotate_location }} logrotate = {{ logrotate_location }}
stunnel = {{ stunnel_location }} stunnel = {{ stunnel_location }}
......
...@@ -29,6 +29,7 @@ extends = ...@@ -29,6 +29,7 @@ extends =
parts = parts =
dash dash
dcron dcron
gcc-minimal
slapos-toolbox slapos-toolbox
stunnel stunnel
varnish-3.0 varnish-3.0
...@@ -70,11 +71,12 @@ context = ...@@ -70,11 +71,12 @@ context =
# XXX: "template.cfg" is hardcoded in instanciation recipe # XXX: "template.cfg" is hardcoded in instanciation recipe
filename = template.cfg filename = template.cfg
template = ${:_profile_base_location_}/instance.cfg.in template = ${:_profile_base_location_}/instance.cfg.in
md5sum = c3a41505e9e082df9b032e17f0f6ad56 md5sum = c380d2101bfb26b90f84a624809254a0
extra-context = extra-context =
key buildout_bin_directory buildout:bin-directory key buildout_bin_directory buildout:bin-directory
key dash_location dash:location key dash_location dash:location
key dcron_location dcron:location key dcron_location dcron:location
key gcc_location gcc-minimal:location
key gzip_location gzip:location key gzip_location gzip:location
key logrotate_location logrotate:location key logrotate_location logrotate:location
key stunnel_location stunnel:location key stunnel_location stunnel:location
...@@ -85,7 +87,7 @@ extra-context = ...@@ -85,7 +87,7 @@ extra-context =
[template-varnish] [template-varnish]
recipe = slapos.recipe.build:download recipe = slapos.recipe.build:download
url = ${:_profile_base_location_}/instance-varnish.cfg.in url = ${:_profile_base_location_}/instance-varnish.cfg.in
md5sum = 1004bcfc30838911ca1c7776cad9510e md5sum = 6b6d748bf089038234f864417a6182cc
mode = 640 mode = 640
[eggs] [eggs]
......
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