tholian-network / stealth

:rocket: Stealth - Secure, Peer-to-Peer, Private and Automateable Web Browser/Scraper/Proxy
GNU General Public License v3.0
1.04k stars 301 forks source link

Makefiles: Packaging #59

Closed cookiengineer closed 2 years ago

cookiengineer commented 3 years ago

In order to get Stealth to work on the Pinephone, it's best to start with a PKGBUILD file for Stealth that can be used for Arch Linux users.

cookiengineer commented 2 years ago

There's be two different packages:

tholian-stealth package:

tholian-browser package:

cookiengineer commented 2 years ago

As of https://github.com/tholian-network/stealth/commit/80d47b099e543679942d4161364cc2cd78494b3f this has been implemented.

The electron workflow for final app.asar package files is broken, though, as it requires a complete custom Filesystem implementation. Prefixed paths like file://, /app.asar/ etc won't work for anything that uses the native filesystem in the end (e.g. lstatSync() and others). Additionally, the app.asar file is temporarily mounted in completely different mechanisms on all platforms.

So, as of now, everything is packaged in an app.asar file, but the asarUnpack array in the electron builder config basically unpacks everything again - as it would be stupid to use webpack or another bundler just for the sake of embedding all assets inside the javascript runtime code.