Skip to content

Commit

Permalink
feat(win): win 32bit build
Browse files Browse the repository at this point in the history
Fix #18
  • Loading branch information
DEgITx committed Mar 25, 2018
1 parent 40419aa commit 80f56aa
Show file tree
Hide file tree
Showing 20 changed files with 21 additions and 0 deletions.
Binary file added imports/win/ia32/iconv.dll
Binary file not shown.
Binary file added imports/win/ia32/indexer.exe
Binary file not shown.
Binary file added imports/win/ia32/indextool.exe
Binary file not shown.
Binary file added imports/win/ia32/libexpat.dll
Binary file not shown.
Binary file added imports/win/ia32/libmysql.dll
Binary file not shown.
Binary file added imports/win/ia32/plink.exe
Binary file not shown.
Binary file added imports/win/ia32/searchd.exe
Binary file not shown.
Binary file added imports/win/ia32/spelldump.exe
Binary file not shown.
Binary file added imports/win/ia32/wordbreaker.exe
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
9 changes: 9 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,15 @@
"from": "./imports/win",
"to": "."
}
],
"target": [
{
"target": "nsis",
"arch": [
"x64",
"ia32"
]
}
]
},
"linux": {
Expand Down
12 changes: 12 additions & 0 deletions src/background/electronAppPath.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,18 @@ export default (app) => {
return `./${app}.exe`
}

if (/^win/.test(process.platform) && fs.existsSync(`./${process.arch}/${app}.exe`)) {
return `./${process.arch}/${app}.exe`
}

if(/^win/.test(process.platform) && fs.existsSync(path.dirname(process.execPath) + `/${app}.exe`)) {
return path.dirname(process.execPath) + `/${app}.exe`
}

if(/^win/.test(process.platform) && fs.existsSync(path.dirname(process.execPath) + `/${process.arch}/${app}.exe`)) {
return path.dirname(process.execPath) + `/${process.arch}/${app}.exe`
}

if (fs.existsSync(fs.realpathSync(__dirname) + `/${app}`)) {
return fs.realpathSync(__dirname) + `/${app}`
}
Expand All @@ -32,6 +40,10 @@ export default (app) => {
return `imports/win/${app}.exe`
}

if (/^win/.test(process.platform) && fs.existsSync(`imports/win/${process.arch}/${app}.exe`)) {
return `imports/win/${process.arch}/${app}.exe`
}

if (process.platform === 'linux' && fs.existsSync(`imports/linux/${app}`)) {
return `imports/linux/${app}`
}
Expand Down

0 comments on commit 80f56aa

Please sign in to comment.