Commit da5e6fc3 authored by Hector Castro's avatar Hector Castro Committed by Sean OMeara
Browse files

[COOK-4296] - Add custom build flags when building from source


Signed-off-by: default avatarSean OMeara <someara@opscode.com>
parent a98e555e
......@@ -36,6 +36,7 @@ Attributes
"source")
* `node['erlang']['source']['url']` - URL of Erlang/OTP source tarball.
* `node['erlang']['source']['checksum']` - Checksum of the Erlang/OTP source tarball.
* `node['erlang']['source']['build_flags']` - Build flags for compiling Erlang/OTP.
* `node['erlang']['esl']['version']` - version specifier for Erlang
Solutions packages.
* `node['erlang']['esl']['lsb_codename']` - override the code name
......
......@@ -21,6 +21,7 @@ default['erlang']['install_method'] = 'package'
default['erlang']['source']['version'] = 'R15B01'
default['erlang']['source']['url'] = "http://erlang.org/download/otp_src_#{node['erlang']['source']['version']}.tar.gz"
default['erlang']['source']['checksum'] = 'f94f7de7328af3c0cdc42089c1a4ecd03bf98ec680f47eb5e6cddc50261cabde'
default['erlang']['source']['build_flags'] = ''
default['erlang']['esl']['version'] = nil
default['erlang']['esl']['lsb_codename'] = node['lsb']['codename']
......@@ -41,7 +41,7 @@ bash 'install-erlang' do
cwd Chef::Config[:file_cache_path]
code <<-EOH
tar -xzf otp_src_#{node['erlang']['source']['version']}.tar.gz
(cd otp_src_#{node['erlang']['source']['version']} && ./configure && make && make install)
(cd otp_src_#{node['erlang']['source']['version']} && ./configure #{node['erlang']['source']['build_flags']} && make && make install)
EOH
action :nothing
not_if "erl -eval 'erlang:display(erlang:system_info(otp_release)), halt().' -noshell | grep #{node['erlang']['source']['version']}"
......
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