fix(linux): 32bit linux builds #21

This commit is contained in:
Alexey Kasyanchuk
2018-03-29 23:38:03 +03:00
parent d5789714a6
commit 7952c283ef
2 changed files with 33 additions and 3 deletions

View File

@ -59,9 +59,27 @@
"linux": {
"category": "Network",
"target": [
"AppImage",
"rpm",
"deb"
{
"target": "AppImage",
"arch": [
"x64",
"ia32"
]
},
{
"target": "rpm",
"arch": [
"x64",
"ia32"
]
},
{
"target": "deb",
"arch": [
"x64",
"ia32"
]
}
],
"extraFiles": [
{

View File

@ -26,10 +26,18 @@ export default (app) => {
return fs.realpathSync(__dirname) + `/${app}`
}
if (fs.existsSync(fs.realpathSync(__dirname) + `/${process.arch}/${app}`)) {
return fs.realpathSync(__dirname) + `/${process.arch}/${app}`
}
if (fs.existsSync(fs.realpathSync(path.join(__dirname, '/../../..')) + `/${app}`)) {
return fs.realpathSync(path.join(__dirname, '/../../..')) + `/${app}`
}
if (fs.existsSync(fs.realpathSync(path.join(__dirname, '/../../..')) + `/${process.arch}/${app}`)) {
return fs.realpathSync(path.join(__dirname, '/../../..')) + `/${process.arch}/${app}`
}
try {
if (process.platform === 'darwin' && fs.existsSync(fs.realpathSync(path.join(__dirname, '/../../../MacOS')) + `/${app}`)) {
return fs.realpathSync(path.join(__dirname, '/../../../MacOS')) + `/${app}`
@ -48,6 +56,10 @@ export default (app) => {
return `imports/linux/${app}`
}
if (process.platform === 'linux' && fs.existsSync(`imports/linux/${process.arch}/${app}`)) {
return `imports/linux/${process.arch}/${app}`
}
if (process.platform === 'darwin' && fs.existsSync(`imports/darwin/${app}`)) {
return `imports/darwin/${app}`
}