bundle lbryum files

This commit is contained in:
jobevers 2017-01-26 12:30:02 -06:00
parent 71efa32edd
commit 6bd93e0b8d
8 changed files with 125 additions and 6 deletions

3
.gitmodules vendored
View file

@ -4,3 +4,6 @@
[submodule "lbry"]
path = lbry
url = https://github.com/lbryio/lbry.git
[submodule "lbryum"]
path = lbryum
url = https://github.com/lbryio/lbryum.git

View file

@ -40,7 +40,7 @@ fi
(
cd "$ROOT/lbrynet"
pyinstaller lbry.py -y --windowed --onefile --icon="${ICON}"
pyinstaller lbry.onefile.spec -y --windowed --onefile
)
(
@ -48,12 +48,13 @@ fi
npm install
node_modules/.bin/node-sass --output dist/css --sourcemap=none scss/
node_modules/.bin/webpack
rm -rf "$ROOT/electron/dist"
cp -r dist "$ROOT/electron/dist"
)
cp -R "$ROOT/lbry-web-ui/dist" "$ROOT/electron/"
mv "$ROOT/lbrynet/dist/lbry" "$ROOT/electron/dist"
if [ -n "${TEAMCITY_VERSION:-}" ]; then
electron-packager --electron-version=1.4.14 --overwrite "$ROOT/electron" LBRY --icon="${ICON}"
# TODO: sign the app

View file

@ -43,7 +43,7 @@ function lauchDaemon() {
app.quit();
} else {
win.loadURL(`file://${__dirname}/dist/warning.html`);
setTimeout(5000, app.quit)
setTimeout(app.quit, 5000)
}
});
console.log('lbrynet daemon has launched')

2
lbry

@ -1 +1 @@
Subproject commit 3e37765c1bdd7007c5c66c97fe9857104d595396
Subproject commit cd239c5925d5ff60addf14123db7cb2d17d14a93

@ -1 +1 @@
Subproject commit 114d7868ac28b3c7e9ca9798aab129624b0c8a48
Subproject commit 2f4245b202ca4dcdff57dff2bfe144fd7a8646d8

53
lbrynet/lbry.onefile.spec Normal file
View file

@ -0,0 +1,53 @@
# -*- mode: python -*-
import lbryum
block_cipher = None
languages = (
'chinese_simplified.txt', 'japanese.txt', 'spanish.txt',
'english.txt', 'portuguese.txt'
)
a = Analysis(
['lbry.py'],
pathex=['/Users/jobevers/projects/lbryio/lbry-electron/lbrynet'],
binaries=None,
datas=[
(
os.path.join(os.path.dirname(lbryum.__file__), 'wordlist', language),
'lbryum/wordlist'
)
for language in languages
],
hiddenimports=[],
hookspath=[],
runtime_hooks=[],
excludes=[],
win_no_prefer_redirects=False,
win_private_assemblies=False,
cipher=block_cipher
)
pyz = PYZ(
a.pure, a.zipped_data,
cipher=block_cipher
)
exe = EXE(
pyz,
a.scripts,
a.binaries,
a.zipfiles,
a.datas,
name='lbry',
debug=False,
strip=False,
upx=True,
console=False , icon='/Users/jobevers/projects/lbryio/lbry-electron/package/osx/app.icns'
)
app = BUNDLE(
exe,
name='lbry.app',
icon='/Users/jobevers/projects/lbryio/lbry-electron/package/osx/app.icns',
bundle_identifier=None
)

61
lbrynet/lbry.spec Normal file
View file

@ -0,0 +1,61 @@
# -*- mode: python -*-
import lbryum
block_cipher = None
languages = (
'chinese_simplified.txt', 'japanese.txt', 'spanish.txt',
'english.txt', 'portuguese.txt'
)
a = Analysis(
['lbry.py'],
pathex=['/Users/jobevers/projects/lbryio/lbry-electron/lbrynet'],
binaries=None,
# Not sure why these files are not already include as they are
# listed in package_data and the MANIFEST.in, but they don't seem
# to make it in unless we explicitly add them here
datas=[
(
os.path.join(os.path.dirname(lbryum.__file__), 'wordlist', language),
'lbryum/wordlist'
)
for language in languages
],
hiddenimports=[],
hookspath=[],
runtime_hooks=[],
excludes=['win32com'],
win_no_prefer_redirects=False,
win_private_assemblies=False,
cipher=block_cipher
)
pyz = PYZ(
a.pure, a.zipped_data,
cipher=block_cipher
)
exe = EXE(
pyz,
a.scripts,
exclude_binaries=True,
name='lbry',
debug=False,
strip=False,
upx=True,
console=True,
)
coll = COLLECT(
exe,
a.binaries,
a.zipfiles,
a.datas,
strip=False,
upx=True,
name='lbry'
)
app = BUNDLE(
coll,
name='lbry.app',
icon=None,
bundle_identifier=None
)

1
lbryum Submodule

@ -0,0 +1 @@
Subproject commit baf2e342174fc1f363a3e2f9e7e0e938dd9a2df3