How to build setup.exe or setup.dmg (for mac) of chromium browser? I tried to read the build documentation but there is only information about how to build chromium and run it but not to build setup.exe
Asked
Active
Viewed 1,549 times
2
-
1You can run this command: `ninja -C folder_to_output setup` – Asesh Jan 04 '20 at 13:58
-
@Asesh thank you very much! It's very helpful! :) Do you know the best way to add packed (crx) extension as the default browser extension so that it will be automatically added and turned on by default after setup? I found three different [ways to do it](https://www.chromium.org/administrators/pre-installed-extensions) Which one is the best in your taste? And maybe you know some code example or tutorial to do this? – Mano Jan 07 '20 at 08:53
-
1I have posted that answer here: https://stackoverflow.com/questions/50125821/standard-way-to-build-a-chrome-extension-into-chromium/50305105#50305105 also, I will post that answer as a solution to this question, so that it will be helpful to others – Asesh Jan 07 '20 at 09:48
1 Answers
2
Setup is an executable file and you can create that file by running the following command:
ninja -C folder_to_output setup

Asesh
- 3,186
- 2
- 21
- 31
-
I tried to build setup for Windows and run this configuration. It successfully finished but when I run setup.exe nothing happends :( (neigher from terminal nor from file manager) Exit code is 0. What can be wrong? – Mano Jan 11 '20 at 16:09
-
1That means the installation succeeded: https://source.chromium.org/chromium/chromium/src/+/master:chrome/installer/util/util_constants.h;drc=59473884eebcb1a5c6a220609eef939f12123975;l=29?originalUrl=https:%2F%2Fcs.chromium.org%2F Also if this answer solved your question then please mark it as an answer too – Asesh Jan 12 '20 at 03:10
-
But where can I see result of setup? It happends very quickly. I want to have executable file that will download necesaary components from somewhere (for example from my server like chrome doing). Executable setup.exe running ~1-2 secounds and don't show me any dialog window or something. It just doing something and close. I'm not sure that it can do something useful in this time – Mano Jan 12 '20 at 05:25
-
1Setup or mini installer won't show any interface. Google uses Omaha client to show that downloading interface: https://github.com/google/omaha It's also responsible for handling updates/upgrades. To use Omaha client you will need to customize both omaha client and omaha server from Crystalnix. – Asesh Jan 12 '20 at 12:13
-
Where can I find chrome.exe after setup.exe finished? Where it install chrome by default and why so quickly? – Mano Jan 13 '20 at 05:33
-
1If you have not made any changes to branding then it will install inside Chromium folder which should be here `%userprofile%/Local` (not the full path). Use the shortcut link to find the full path. I am on macOS, so can't check it right now :) – Asesh Jan 13 '20 at 06:54
-
Why mini_installer is so big (~1Gb)? Can I somehow reduce the size? Maybe it contains some debug information and there is possibility to choose something like "release build" option but I can't find something like instruction how to build mini_installer and any options this configuration have. Also my chromium for some reasons works quite slow (much more slower then chrome) can it be also related to my build is debug build? – Mano Feb 07 '20 at 02:59
-
Yep, default GN build is debug and I should to set is_debug = false. Is there some other "parameters for release" that can also reduce the size and increase performance of mini installer? – Mano Feb 07 '20 at 03:13
-
1@Mano You are building debug version. Checkout my answer here: https://stackoverflow.com/questions/57868837/chromium-mini-installer-size-reaches-1-19gb/57888057#57888057 – Asesh Feb 07 '20 at 03:21
-
Yep, it's helpful, thanks) Also there is a bit different question about how can I share some data from chromium C++ code to extension js code. Is there some message passing protocol or something to do this? I just want to init some variable in chromium and pass this value to extension any possible solution will be good :) – Mano Mar 19 '20 at 03:35
-
1
-
Thank you very much :) Maybe you know also some easiest way how to send simple get or post request from random place in chromium code? – Mano Mar 22 '20 at 05:21