1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-07-05 12:04:54 +02:00

build libs appropriately

This commit is contained in:
Kyle Spearrin 2019-09-27 21:23:50 -04:00
parent 2585e9e4c6
commit d7a1ee8a5e

View File

@ -197,19 +197,28 @@ function distSafariApp(cb, subBuildPath, devId) {
}).then(() => {
const libs = fs.readdirSync(builtAppexFrameworkPath).filter((p) => p.endsWith('.dylib'))
.map((p) => builtAppexFrameworkPath + p);
const allItems = [].concat([builtAppexPath]);
const allItems = libs.concat([builtAppexPath]);
const promises = [];
allItems.forEach ((i) => {
const proc = child.spawn('codesign', [
allItems.forEach((i) => {
const args1 = [
'--verbose',
'--force',
'--force'];
const argsHardRuntime = [
'-o',
'runtime',
'runtime'];
const args2 = [
'--sign',
devId,
'--entitlements',
entitlementsPath,
i]);
i];
let args = [];
if (subBuildPath == 'mas') {
args = [...args1, ...args2];
} else {
args = [...args1, ...argsHardRuntime, ...args2];
}
const proc = child.spawn('codesign', args);
stdOutProc(proc);
promises.push(new Promise((resolve) => proc.on('close', resolve)));
});