Skip to content

Commit

Permalink
[major] Move binary dependencies to optionalDependencies to preven bu…
Browse files Browse the repository at this point in the history
…ild failures
  • Loading branch information
3rd-Eden committed Jan 29, 2015
1 parent 602748a commit c84c880
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 304 deletions.
16 changes: 0 additions & 16 deletions binding.gyp

This file was deleted.

13 changes: 5 additions & 8 deletions lib/BufferUtil.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
'use strict';

/*!
* ws: a node.js websocket client
* Copyright(c) 2011 Einar Otto Stangvik <[email protected]>
* MIT Licensed
*/

try {
module.exports = require('../build/Release/bufferutil');
} catch (e) { try {
module.exports = require('../build/default/bufferutil');
} catch (e) { try {
module.exports = require('./BufferUtil.fallback');
module.exports = require('bufferutil');
} catch (e) {
console.error('bufferutil.node seems to not have been built. Run npm install.');
throw e;
}}}
module.exports = require('./BufferUtil.fallback');
}
13 changes: 5 additions & 8 deletions lib/Validation.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
'use strict';

/*!
* ws: a node.js websocket client
* Copyright(c) 2011 Einar Otto Stangvik <[email protected]>
* MIT Licensed
*/

try {
module.exports = require('../build/Release/validation');
} catch (e) { try {
module.exports = require('../build/default/validation');
} catch (e) { try {
module.exports = require('./Validation.fallback');
module.exports = require('utf-8-validation');
} catch (e) {
console.error('validation.node seems to not have been built. Run npm install.');
throw e;
}}}
module.exports = require('./Validation.fallback');
}
8 changes: 5 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,16 @@
"url": "git://github.com/websockets/ws.git"
},
"scripts": {
"test": "make test",
"install": "(node-gyp rebuild 2> builderror.log) || (exit 0)"
"test": "make test"
},
"dependencies": {
"nan": "1.5.x",
"options": ">=0.0.5",
"ultron": "1.0.x"
},
"optionalDependencies": {
"bufferutil": "1.0.x",
"utf-8-validate": "1.0.x"
},
"devDependencies": {
"ansi": "0.3.x",
"benchmark": "0.3.x",
Expand Down
121 changes: 0 additions & 121 deletions src/bufferutil.cc

This file was deleted.

148 changes: 0 additions & 148 deletions src/validation.cc

This file was deleted.

0 comments on commit c84c880

Please sign in to comment.