agregore-mobile
                                
                                 agregore-mobile copied to clipboard
                                
                                    agregore-mobile copied to clipboard
                            
                            
                            
                        Mobile version of the Agregore browser for Android, based on Chromium and Bromite
agregore-mobile
Mobile version of the Agregore browser for Android, based on Chromium and Bromite
WORK IN PROGRESS
Development
This codebase is based on Chromium Android and Bromite.
How it works:
- You'll need about 70 GB of space on your machine since chromium and it's history is so huge.
- Run ./setup.pyto do the initial folder setup.- The build scripts use Python 3, so you'll need to have it installed on your system.
- Chromium build tools are set up in ./depot_tools
- A Chromium source tree is set up in ./chromium(this takes huge amounts of space)
- A Bromitesource tree is set up in./bromite(this doesn't take much space)
 
- Chromium build tools are set up in 
 
- The build scripts use Python 3, so you'll need to have it installed on your system.
- Run ./checkout_bromite_tag.pyto checkout the correct version of bromite to base the browser on- Run this when the bromite version gets updated, you must then re-apply the bromite patches, it will auto-run at setup
- bromite_tag.txtis where you can update the bromite version to build on top of
 
- Run ./apply_bromite_patches.pyto checkout the correct version of Chromium and to apply the bromite patches to it- Run this whenever bromite gets updated, it will auto-run at setup
- You will need to re-apply agregore patches next since the git state will be reset
 
- Run ./apply_agregore_patches.pyto apply Agregore patches to the Chromium tree- Run this whenever there are new Agregore patches to apply. It will auto-run at setup
 
- Run ./download_ipfs_daemon.pyto download the latest version of the Agregore IPFS Daemon- Run this whenever a new version is available to update. It will auto-run at setup
- The version of the daemon that we're using can be found inside daemon_tag.txt, update this with new versions
- Note: you can instead place an AAR of the daemon into chromium/src/third_party/agregore-ipfs-daemon/agregore-ipfs-daemon.aar
 
- Run ./prebuild.pyto sync dependencies needed to perform a build.- This can be skipped if you're just adding changes, dependenices can take an extra 60 GB of space
 
- Run ./build.pyto trigger a new build of the browser- You'll need to be running Ubuntu 18 in order to do a successful build. Automated builds via a build server are a work in progress.
 
- The patchesfolder contains Agregore-specific patches on top of Chromium
- Run ./generate_patch.pyTo generate a new patch based on the latest Commit insideChromium/src- You can specify --nfor the number of commits to include in the patch if you want something other than the latest one.
- Generally, if you did several commits as part of your change, you'll want to squash them with git rebase -i HEAD~<n>wherenis the number of commits you want to squash.
- Then you'll want to commit the patches and use apply_agregore_patches.pyto apply them on the build server
 
- You can specify 
Flow for making patches
- Checkout a new branch for your patch
- Make changes in chromium/src
- git add -Ato track newly added files
- git commit -am "some message"to commit your changes- For the message, try to start with AGsince this will be the patch name
 
- For the message, try to start with 
- cd ../../back to the root of agregore-mobile
- ./generate_patch.pyto generate a new patch
- git add -Ato track the new patch
- git commit -am "Added patch for bla bla bla"to commit your patch to the main repo
- git push
Adding changes to an existing patch
- Make your changes in chromium/src
- (If you have new or deleted files) git add -Ato track the new files or remove deleted ones.
- git commit -am "some message"to commit your changes- Note the message doesn't matter because we'll be deleting it in favor of the message in the patch
 
- git rebase HEAD~2to start rebasing the commit history (with the goal of sqashing your previous commit into your patch commit)- Note 2means "the latest commit, and the one before that", if you have more commits that you want to squash, increase this number
 
- Note 
- When your editor opens, Squash all the commits other than the one for the patch (which should be left as "pick")
- Then once it prompts you to edit the new commit message, delete the squashed commit messages and just keep the original message
- Now your history should have the latest commit
- cd ../../to go back to the agregore-mobile directory
- ./generate_patch.pyto re-generate the patch content
- git commit -am "the actual commit message for you change"to commit changes to your patch
- git pushto push the latest version of your patch out
Applying new versions of a patch
- git pullto get the latest chnages
- ./undo_last_patch.pyto undo the latest version of the patch
- ./apply_agregore_patches.pyto re-apply the latest versions of the patches.
Flow for building with the build server
- Checkout a new branch to start
- Make changes inside chromium/src and commit
- Run ./generate_patch.pyto generate a pach
- Commit your changes to your branch
- Push them to github
- Checkout the branch on the build server ssh [email protected]
- Apply the patches using ./apply_agregore_patches.py
- Run ./build.py