Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

add support for configure_flags, sensible defaults #85

Closed
wants to merge 1 commit into from

2 participants

@cantremember
  • add support for node['nodejs']['configure_flags']
  • default to derived --prefix value from node['nodejs']['dir']
@mdxp
Owner

The development of the nodejs cookbook has been move here: https://github.com/redguide/nodejs
Your PR functionality might have been already included in the new repo. If not, please resubmit it there. Thanks!

@mdxp mdxp closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 3, 2014
This page is out of date. Refresh to see the latest.
View
2  README.md
@@ -32,6 +32,8 @@ ATTRIBUTES
* nodejs['npm'] - version of npm to install
* nodejs['npm_src_url'] - download location for npm source tarball
* nodejs['check_sha'] - test for valid sha_sum, default: true
+* nodejs['configure_flags'] - flags passed to the configure script,
+ default: "--prefix=nodejs['dir']"
USAGE
=====
View
3  attributes/default.rb
@@ -34,6 +34,9 @@
default['nodejs']['src_url'] = "http://nodejs.org/dist"
default['nodejs']['make_threads'] = node['cpu'] ? node['cpu']['total'].to_i : 2
default['nodejs']['check_sha'] = true
+default['nodejs']['configure_flags'] = %W(
+ --prefix=#{node['nodejs']['dir']}
+)
# Set this to true to install the legacy packages (0.8.x) from ubuntu/debian repositories; default is false (using the latest stable 0.10.x)
default['nodejs']['legacy_packages'] = false
View
2  recipes/install_from_source.rb
@@ -54,7 +54,7 @@
cwd "/usr/local/src/node-v#{node['nodejs']['version']}"
code <<-EOH
PATH="/usr/local/bin:$PATH"
- ./configure --prefix=#{node['nodejs']['dir']} && \
+ ./configure #{node['nodejs']['configure_flags'].join(' ')} && \
make -j #{node['nodejs']['make_threads']}
EOH
creates "/usr/local/src/node-v#{node['nodejs']['version']}/node"
Something went wrong with that request. Please try again.