cjdns/cjdns.dyn.patch

61 lines
2.2 KiB
Diff
Raw Normal View History

2016-03-22 15:40:36 +00:00
diff -up ./node_build/make.js.dyn ./node_build/make.js
2016-10-15 02:25:36 +00:00
--- ./node_build/make.js.dyn 2016-10-11 17:39:44.000000000 -0400
+++ ./node_build/make.js 2016-10-14 22:08:23.018241766 -0400
@@ -252,44 +252,9 @@ Builder.configure({
2016-03-22 15:40:36 +00:00
}).nThen(function (waitFor) {
- builder.config.libs.push(dependencyDir + '/cnacl/jsbuild/libnacl.a');
- builder.config.includeDirs.push(dependencyDir + '/cnacl/jsbuild/include/');
-
2016-10-15 02:25:36 +00:00
- // needed for Sign.c which pulls in crypto_int32.h
- builder.config.includeDirs.push(dependencyDir + '/cnacl/jsbuild/include_internal/');
-
2016-03-22 15:40:36 +00:00
- Fs.exists(dependencyDir + '/cnacl/jsbuild/libnacl.a', waitFor(function (exists) {
- if (exists) { return; }
-
- console.log("Build NaCl");
- var cwd = process.cwd();
- process.chdir(dependencyDir + '/cnacl/');
-
- var NaCl = require(process.cwd() + '/node_build/make.js');
- NaCl.build(function (args, callback) {
- if (builder.config.systemName !== 'win32') {
- args.unshift('-fPIC');
- }
-
- args.unshift(builder.config.optimizeLevel, '-fomit-frame-pointer');
-
- if (CFLAGS) {
- [].push.apply(args, CFLAGS.split(' '));
- }
-
- if (!builder.config.crossCompiling) {
- if (NO_MARCH_FLAG.indexOf(process.arch) < -1) {
- builder.config.cflags.push('-march=native');
- }
- }
-
- builder.cc(args, callback);
- },
- builder.config,
- waitFor(function () {
- process.chdir(cwd);
- }));
- }));
2016-04-18 20:23:46 +00:00
+ builder.config.libs.push('-lnacl');
2016-03-22 15:40:36 +00:00
+ builder.config.libs.push('-lstdc++');
2016-04-18 20:23:46 +00:00
+ builder.config.includeDirs.push('/usr/include/nacl/');
2016-03-22 15:40:36 +00:00
}).nThen(function (waitFor) {
2016-10-15 02:25:36 +00:00
@@ -430,7 +395,7 @@ Builder.configure({
2016-03-22 15:40:36 +00:00
builder.buildExecutable('crypto/random/randombytes.c');
builder.lintFiles(function (fileName, file, callback) {
- if (/dependencies/.test(fileName)) {
+ if (/(dependencies|\/usr\/include)/.test(fileName)) {
callback('', false);
return;
}