File index.js changed (mode: 100755) (index 74872c9..37c2bc2) |
2 |
2 |
|
|
3 |
3 |
const fs = require('fs'), |
const fs = require('fs'), |
4 |
4 |
path = require('path'), |
path = require('path'), |
|
5 |
|
tmp = require('tmp'), |
|
6 |
|
shell = require( 'shelljs' ), |
5 |
7 |
argv = require('minimist')(process.argv.slice(2)), |
argv = require('minimist')(process.argv.slice(2)), |
6 |
8 |
defPath = argv.p ? argv.p : argv.project; |
defPath = argv.p ? argv.p : argv.project; |
7 |
9 |
|
|
|
... |
... |
readDef(defPath) |
11 |
13 |
.then(obj2 => { |
.then(obj2 => { |
12 |
14 |
let result = [obj, obj2].join(' '); |
let result = [obj, obj2].join(' '); |
13 |
15 |
if (argv.common || argv.c) { |
if (argv.common || argv.c) { |
14 |
|
result += ' -DTARGET_TEST=1 -pthread'; |
|
|
16 |
|
result += ' -pthread'; |
|
17 |
|
} |
|
18 |
|
if (argv.test || argv.t) { |
|
19 |
|
let compiler = argv.clang || argv.llvm ? "clang++" : "g++"; |
|
20 |
|
tmp.dir((err, path) => { |
|
21 |
|
if (err) throw err; |
|
22 |
|
console.log( 'test directory:', path ); |
|
23 |
|
|
|
24 |
|
result = `${compiler} ${result} -DTARGET_TEST=1 -o ${path}/test`; |
|
25 |
|
console.log(result); |
|
26 |
|
shell.exec(result); |
|
27 |
|
}); |
15 |
28 |
} |
} |
16 |
|
console.log(result); |
|
17 |
29 |
}); |
}); |
18 |
30 |
}); |
}); |
19 |
31 |
|
|
File package-lock.json changed (mode: 100644) (index bca8b84..d6cec31) |
4 |
4 |
"lockfileVersion": 1, |
"lockfileVersion": 1, |
5 |
5 |
"requires": true, |
"requires": true, |
6 |
6 |
"dependencies": { |
"dependencies": { |
|
7 |
|
"balanced-match": { |
|
8 |
|
"version": "1.0.0", |
|
9 |
|
"resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", |
|
10 |
|
"integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" |
|
11 |
|
}, |
|
12 |
|
"brace-expansion": { |
|
13 |
|
"version": "1.1.11", |
|
14 |
|
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", |
|
15 |
|
"integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", |
|
16 |
|
"requires": { |
|
17 |
|
"balanced-match": "^1.0.0", |
|
18 |
|
"concat-map": "0.0.1" |
|
19 |
|
} |
|
20 |
|
}, |
|
21 |
|
"concat-map": { |
|
22 |
|
"version": "0.0.1", |
|
23 |
|
"resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", |
|
24 |
|
"integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" |
|
25 |
|
}, |
|
26 |
|
"fs.realpath": { |
|
27 |
|
"version": "1.0.0", |
|
28 |
|
"resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", |
|
29 |
|
"integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" |
|
30 |
|
}, |
|
31 |
|
"glob": { |
|
32 |
|
"version": "7.1.6", |
|
33 |
|
"resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", |
|
34 |
|
"integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", |
|
35 |
|
"requires": { |
|
36 |
|
"fs.realpath": "^1.0.0", |
|
37 |
|
"inflight": "^1.0.4", |
|
38 |
|
"inherits": "2", |
|
39 |
|
"minimatch": "^3.0.4", |
|
40 |
|
"once": "^1.3.0", |
|
41 |
|
"path-is-absolute": "^1.0.0" |
|
42 |
|
} |
|
43 |
|
}, |
|
44 |
|
"inflight": { |
|
45 |
|
"version": "1.0.6", |
|
46 |
|
"resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", |
|
47 |
|
"integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", |
|
48 |
|
"requires": { |
|
49 |
|
"once": "^1.3.0", |
|
50 |
|
"wrappy": "1" |
|
51 |
|
} |
|
52 |
|
}, |
|
53 |
|
"inherits": { |
|
54 |
|
"version": "2.0.4", |
|
55 |
|
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", |
|
56 |
|
"integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" |
|
57 |
|
}, |
|
58 |
|
"interpret": { |
|
59 |
|
"version": "1.2.0", |
|
60 |
|
"resolved": "https://registry.npmjs.org/interpret/-/interpret-1.2.0.tgz", |
|
61 |
|
"integrity": "sha512-mT34yGKMNceBQUoVn7iCDKDntA7SC6gycMAWzGx1z/CMCTV7b2AAtXlo3nRyHZ1FelRkQbQjprHSYGwzLtkVbw==" |
|
62 |
|
}, |
|
63 |
|
"minimatch": { |
|
64 |
|
"version": "3.0.4", |
|
65 |
|
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", |
|
66 |
|
"integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", |
|
67 |
|
"requires": { |
|
68 |
|
"brace-expansion": "^1.1.7" |
|
69 |
|
} |
|
70 |
|
}, |
7 |
71 |
"minimist": { |
"minimist": { |
8 |
72 |
"version": "1.2.5", |
"version": "1.2.5", |
9 |
73 |
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", |
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", |
10 |
74 |
"integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==" |
"integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==" |
|
75 |
|
}, |
|
76 |
|
"once": { |
|
77 |
|
"version": "1.4.0", |
|
78 |
|
"resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", |
|
79 |
|
"integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", |
|
80 |
|
"requires": { |
|
81 |
|
"wrappy": "1" |
|
82 |
|
} |
|
83 |
|
}, |
|
84 |
|
"path-is-absolute": { |
|
85 |
|
"version": "1.0.1", |
|
86 |
|
"resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", |
|
87 |
|
"integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" |
|
88 |
|
}, |
|
89 |
|
"path-parse": { |
|
90 |
|
"version": "1.0.6", |
|
91 |
|
"resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", |
|
92 |
|
"integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==" |
|
93 |
|
}, |
|
94 |
|
"rechoir": { |
|
95 |
|
"version": "0.6.2", |
|
96 |
|
"resolved": "https://registry.npmjs.org/rechoir/-/rechoir-0.6.2.tgz", |
|
97 |
|
"integrity": "sha1-hSBLVNuoLVdC4oyWdW70OvUOM4Q=", |
|
98 |
|
"requires": { |
|
99 |
|
"resolve": "^1.1.6" |
|
100 |
|
} |
|
101 |
|
}, |
|
102 |
|
"resolve": { |
|
103 |
|
"version": "1.15.1", |
|
104 |
|
"resolved": "https://registry.npmjs.org/resolve/-/resolve-1.15.1.tgz", |
|
105 |
|
"integrity": "sha512-84oo6ZTtoTUpjgNEr5SJyzQhzL72gaRodsSfyxC/AXRvwu0Yse9H8eF9IpGo7b8YetZhlI6v7ZQ6bKBFV/6S7w==", |
|
106 |
|
"requires": { |
|
107 |
|
"path-parse": "^1.0.6" |
|
108 |
|
} |
|
109 |
|
}, |
|
110 |
|
"rimraf": { |
|
111 |
|
"version": "2.7.1", |
|
112 |
|
"resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", |
|
113 |
|
"integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", |
|
114 |
|
"requires": { |
|
115 |
|
"glob": "^7.1.3" |
|
116 |
|
} |
|
117 |
|
}, |
|
118 |
|
"shelljs": { |
|
119 |
|
"version": "0.8.3", |
|
120 |
|
"resolved": "https://registry.npmjs.org/shelljs/-/shelljs-0.8.3.tgz", |
|
121 |
|
"integrity": "sha512-fc0BKlAWiLpwZljmOvAOTE/gXawtCoNrP5oaY7KIaQbbyHeQVg01pSEuEGvGh3HEdBU4baCD7wQBwADmM/7f7A==", |
|
122 |
|
"requires": { |
|
123 |
|
"glob": "^7.0.0", |
|
124 |
|
"interpret": "^1.0.0", |
|
125 |
|
"rechoir": "^0.6.2" |
|
126 |
|
} |
|
127 |
|
}, |
|
128 |
|
"tmp": { |
|
129 |
|
"version": "0.1.0", |
|
130 |
|
"resolved": "https://registry.npmjs.org/tmp/-/tmp-0.1.0.tgz", |
|
131 |
|
"integrity": "sha512-J7Z2K08jbGcdA1kkQpJSqLF6T0tdQqpR2pnSUXsIchbPdTI9v3e85cLW0d6WDhwuAleOV71j2xWs8qMPfK7nKw==", |
|
132 |
|
"requires": { |
|
133 |
|
"rimraf": "^2.6.3" |
|
134 |
|
} |
|
135 |
|
}, |
|
136 |
|
"wrappy": { |
|
137 |
|
"version": "1.0.2", |
|
138 |
|
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", |
|
139 |
|
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" |
11 |
140 |
} |
} |
12 |
141 |
} |
} |
13 |
142 |
} |
} |