Permalink
Browse files

Fix: force ia32 builds on osx (for now)

  • Loading branch information...
1 parent 127c5a0 commit 435f3bdb452d10f82b66f7f88e488d11952113d6 @tmpvar committed Jul 14, 2012
Showing with 28 additions and 1 deletion.
  1. +22 −0 cli/build.js
  2. +5 −0 cli/configure.js
  3. +1 −1 package.json
View
@@ -0,0 +1,22 @@
+/**
+ * Set the title.
+ */
+
+process.title = 'appjs-build'
+
+/**
+ * Necessary modules and variables
+ */
+
+var fs = require('fs')
+ , spawn = require('child_process').spawn
+ , platform = require('os').platform()
+ , arch = require('os').arch()
+ , args = ['rebuild'];
+
+// TODO: remove me after CEF supports building under OSX as 64bit
+if (platform === 'darwin' && arch === 'x64') {
+ Array.prototype.unshift.apply(args, ['--arch', 'ia32']);
+}
+
+spawn('node-gyp', args, { detached : false, stdio : ['ignore', process.stdout, process.stderr ]});
View
@@ -16,6 +16,11 @@ var util = require('../cli/util')
, depsDir = path.join(__dirname,'../deps')
, env = process.env.NODE_ENV || 'Debug';
+// TODO: remove me after CEF supports building under OSX as 64bit
+if (platform === 'darwin' && arch === 'x64') {
+ arch='ia32'
+}
+
/**
* Starts installing CEF libraries
*/
View
@@ -48,7 +48,7 @@
"devDependencies": {},
"optionalDependencies": {},
"scripts": {
- "install": "node cli/configure.js && node-gyp rebuild"
+ "install": "node cli/configure.js && node cli/build.js"
},
"licenses": [
{

0 comments on commit 435f3bd

Please sign in to comment.