From 4f92e73ec45c295ecabf3f64dea3f99475258bd9 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Wed, 3 Feb 2021 23:53:06 +0100 Subject: [PATCH 01/29] changes --- README2.md | 53 +++++ build.sh | 190 ++++++++++++++++++ .../stubinstaller/bgstub.jpg | Bin 0 -> 1228 bytes .../stubinstaller/installing_page.css | 61 ++++++ .../stubinstaller/profile_cleanup_page.css | 42 ++++ 5 files changed, 346 insertions(+) create mode 100644 README2.md create mode 100644 build.sh create mode 100644 missing_branding_files/stubinstaller/bgstub.jpg create mode 100644 missing_branding_files/stubinstaller/installing_page.css create mode 100644 missing_branding_files/stubinstaller/profile_cleanup_page.css diff --git a/README2.md b/README2.md new file mode 100644 index 0000000..2f1e02b --- /dev/null +++ b/README2.md @@ -0,0 +1,53 @@ +Just some notes +--------------- + +To build, one should use the following: + +$ time bash build.sh fetch prepare build package + + +the final .zip is in: + C:\mozilla-source\firefox-85.0\obj-x86_64-pc-mingw32\dist + + +* problem with old sed. does not recognize -z. using the one from Git might be a work around. + + +BRANDING: resource files +======================== + +* build fail on missing stubinstaller (might be a FF bug as it should just take missing +stuff from the nightly branding folder?) + +$ mkdir stubinstaller +$ cp bgstub.jpg stubinstaller +$ pwd +/c/mozilla-source/firefox-85.0/browser/branding/librewolf +$ + +* checking all the different files in nightly and librewolf + +$ cd nightly +$ find . | sort > /c/mozilla-source/branding-nightly.txt +$ cd ../librewolf/ +$ find . | sort > /c/mozilla-source/branding-librewolf.txt + + +$ diff branding-nightly.txt branding-librewolf.txt +4a5,6 +> ./bgstub.jpg +> ./bgstub_2x.jpg +7a10 +> ./content/about-background.png +9,10d11 +< ./content/about-logo.svg +< ./content/about-logo@2x.png +14,15d14 +< ./content/aboutlogins.svg +< ./content/firefox-wordmark.svg +22,24d20 +< ./default22.png +< ./default24.png +< ./default256.png +$ + diff --git a/build.sh b/build.sh new file mode 100644 index 0000000..7171839 --- /dev/null +++ b/build.sh @@ -0,0 +1,190 @@ +# build.sh - build librewolf on windows +# derived from https://gitlab.com/librewolf-community/browser/linux/-/blob/master/PKGBUILD + +pkgname=librewolf +_pkgname=LibreWolf + +pkgver=85.0 +#srcdir=/c/mozilla-source + + + +fetch() { + rm -f firefox-$pkgver.source.tar.xz + wget https://archive.mozilla.org/pub/firefox/releases/$pkgver/source/firefox-$pkgver.source.tar.xz + + rm -rf settings commmon + git clone https://gitlab.com/$pkgname-community/browser/common.git + git clone https://gitlab.com/$pkgname-community/settings.git + + rm -f megabar.patch remove_addons.patch unity-menubar.patch + wget https://gitlab.com/librewolf-community/browser/linux/-/raw/master/megabar.patch + wget https://gitlab.com/librewolf-community/browser/linux/-/raw/master/remove_addons.patch + wget https://gitlab.com/librewolf-community/browser/linux/-/raw/master/unity-menubar.patch +} + + + + + +prepare() { + rm -rf firefox-$pkgver + tar xf firefox-$pkgver.source.tar.xz + + cd firefox-$pkgver + + cat >../mozconfig < Date: Thu, 4 Feb 2021 00:03:46 +0100 Subject: [PATCH 02/29] changes --- README2.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/README2.md b/README2.md index 2f1e02b..f756ee8 100644 --- a/README2.md +++ b/README2.md @@ -1,13 +1,19 @@ Just some notes --------------- -To build, one should use the following: +Once you have built the entire mozilla-unified with all the mach bootstrap stuff (which will +install the needed binaries in $HOME/.mozbuild), don't forget to copy the entire +C:\Program Files\Git folder to /c/mozilla-source to get a sed.exe that understands the -z option, +and to get sha256sum.exe. + + +To build, one should use the following command in the checked out windows repo: $ time bash build.sh fetch prepare build package the final .zip is in: - C:\mozilla-source\firefox-85.0\obj-x86_64-pc-mingw32\dist + C:\mozilla-source\windows\firefox-85.0\obj-x86_64-pc-mingw32\dist * problem with old sed. does not recognize -z. using the one from Git might be a work around. From 79e7e2b21b3830909e439d202cd0b889b04f2e8e Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 00:10:16 +0100 Subject: [PATCH 03/29] changes --- .gitignore | 4 ++++ .gitmodules | 3 +++ 2 files changed, 7 insertions(+) create mode 100644 .gitignore create mode 100644 .gitmodules diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b870e9f --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +firefox-*.tar.xz +megabar.patch +remove_addons.patch +unity-menubar.patch diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..2869fea --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "settings"] + path = settings + url = https://gitlab.com/librewolf-community/settings.git From c542e80b8af8ae026448f12f6169bc46a76a8775 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 00:12:21 +0100 Subject: [PATCH 04/29] changes --- .gitmodules | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitmodules b/.gitmodules index 2869fea..68523b2 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,4 @@ [submodule "settings"] path = settings url = https://gitlab.com/librewolf-community/settings.git + From 22914f232c9dae9986b56e206f270b04562b63ff Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 00:28:21 +0100 Subject: [PATCH 05/29] changes --- .gitmodules | 4 ---- 1 file changed, 4 deletions(-) delete mode 100644 .gitmodules diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index 68523b2..0000000 --- a/.gitmodules +++ /dev/null @@ -1,4 +0,0 @@ -[submodule "settings"] - path = settings - url = https://gitlab.com/librewolf-community/settings.git - From 0586f8ecd63140d511f0a962dd1999cfe1cf5730 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 00:33:12 +0100 Subject: [PATCH 06/29] addes settings submodule --- .gitmodules | 3 +++ settings | 1 + 2 files changed, 4 insertions(+) create mode 100644 .gitmodules create mode 160000 settings diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..1d63467 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "settings"] + path = settings + url = https://gitlab.com/librewolf-community/settings.git diff --git a/settings b/settings new file mode 160000 index 0000000..640b375 --- /dev/null +++ b/settings @@ -0,0 +1 @@ +Subproject commit 640b375dc02c5b089f678ed16b0232d1c0cc0721 From fd668d8a74450dd2d05b5c9dcaf62e3de2f0b6f3 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 00:44:17 +0100 Subject: [PATCH 07/29] changes --- .gitignore | 3 ++- .gitmodules | 3 +++ build.sh | 4 +--- common | 1 + 4 files changed, 7 insertions(+), 4 deletions(-) create mode 160000 common diff --git a/.gitignore b/.gitignore index b870e9f..322c7c4 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ -firefox-*.tar.xz +firefox-* megabar.patch remove_addons.patch unity-menubar.patch +mozconfig diff --git a/.gitmodules b/.gitmodules index 1d63467..9e19064 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,6 @@ [submodule "settings"] path = settings url = https://gitlab.com/librewolf-community/settings.git +[submodule "common"] + path = common + url = https://gitlab.com/librewolf-community/browser/common.git diff --git a/build.sh b/build.sh index 7171839..81fd5ab 100644 --- a/build.sh +++ b/build.sh @@ -13,9 +13,7 @@ fetch() { rm -f firefox-$pkgver.source.tar.xz wget https://archive.mozilla.org/pub/firefox/releases/$pkgver/source/firefox-$pkgver.source.tar.xz - rm -rf settings commmon - git clone https://gitlab.com/$pkgname-community/browser/common.git - git clone https://gitlab.com/$pkgname-community/settings.git + # the settings and common submodules should be checked out to allow the build rm -f megabar.patch remove_addons.patch unity-menubar.patch wget https://gitlab.com/librewolf-community/browser/linux/-/raw/master/megabar.patch diff --git a/common b/common new file mode 160000 index 0000000..9995c8b --- /dev/null +++ b/common @@ -0,0 +1 @@ +Subproject commit 9995c8b275e2a06db3e0b24974b302a63791fc24 From 85f138650feed3c8ccad64a02b5957bff39bd051 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 00:55:03 +0100 Subject: [PATCH 08/29] updates --- build.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build.sh b/build.sh index 81fd5ab..9d8e2ef 100644 --- a/build.sh +++ b/build.sh @@ -108,8 +108,11 @@ END - rm -f ../common/source_files/mozconfig cp -r ../common/source_files/* ./ + # FIXME: this 'mozconfig' file in the 'common' submodule should be removed + # this submodule is purely for the branding. I imagine that we want the + # missing_branding_files into the 'common' submodule. + rm -f mozconfig # FIX: on windows: the stubinstaller folder is missing from the librewolf branding folder. cp -r ../missing_branding_files/stubinstaller browser/branding/librewolf From 2375039d41bb16276f501a03175742b081943bfa Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 02:21:09 +0100 Subject: [PATCH 09/29] updates --- .gitignore | 1 + build.sh | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 322c7c4..1929584 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ firefox-* +librewolf-* megabar.patch remove_addons.patch unity-menubar.patch diff --git a/build.sh b/build.sh index 9d8e2ef..8129294 100644 --- a/build.sh +++ b/build.sh @@ -147,8 +147,10 @@ package() { cp -rv ../settings/* obj-x86_64-pc-mingw32/dist/librewolf # recreate the zip file.. cd obj-x86_64-pc-mingw32/dist - rm -f librewolf-85.0.en-US.win64.txt librewolf-85.0.en-US.win64.zip - zip -r9 librewolf-85.0.en-US.win64.zip librewolf + rm -f librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip + zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf + /c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum + cp librewolf-$pkgver.en-US.win64.zip* ../../.. cd ../.. cd .. From b665c22c594f753e82b12e26fd5b1951274561fa Mon Sep 17 00:00:00 2001 From: Stanzabird Date: Thu, 4 Feb 2021 01:26:07 +0000 Subject: [PATCH 10/29] Update README2.md --- README2.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README2.md b/README2.md index f756ee8..5dde730 100644 --- a/README2.md +++ b/README2.md @@ -13,7 +13,7 @@ $ time bash build.sh fetch prepare build package the final .zip is in: - C:\mozilla-source\windows\firefox-85.0\obj-x86_64-pc-mingw32\dist + C:\mozilla-source\windows * problem with old sed. does not recognize -z. using the one from Git might be a work around. From 07cd4fabf39d3619463d9a8df07518ab95be79c3 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 02:51:19 +0100 Subject: [PATCH 11/29] new version of the readme.md --- README.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/README.md b/README.md index a47e71e..612923d 100644 --- a/README.md +++ b/README.md @@ -1 +1,12 @@ This repository is still a work in progress + + +This build does require you to: + +* First build the mozilla-unified as explained in the mozilla docs, using all the ./mach bootstrap stuff +* You can delete this mozilla-unified thing to save some space (try ./mach run on it just for fun) +* Then clone the windows repo +* cd into it, and build with: time bash build.sh fetch prepare build package +* you can perform each of the build steps individually and the overall script structure follows PKGBULD as used on Archlinux +* This will produce a librewolf-85.0.en-US.win64.zip in this windows folder. + From 8d88df02fe52e67d353f67d457d4401d1a516935 Mon Sep 17 00:00:00 2001 From: Stanzabird Date: Thu, 4 Feb 2021 01:53:34 +0000 Subject: [PATCH 12/29] Update the text formatting --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 612923d..46ba00a 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ This build does require you to: * First build the mozilla-unified as explained in the mozilla docs, using all the ./mach bootstrap stuff * You can delete this mozilla-unified thing to save some space (try ./mach run on it just for fun) * Then clone the windows repo -* cd into it, and build with: time bash build.sh fetch prepare build package +* cd into it, and build with: **time bash build.sh fetch prepare build package** * you can perform each of the build steps individually and the overall script structure follows PKGBULD as used on Archlinux -* This will produce a librewolf-85.0.en-US.win64.zip in this windows folder. +* This will produce a **librewolf-85.0.en-US.win64.zip** in this windows folder. From 200dc9863316236f1fa39d80856fac0e097c462e Mon Sep 17 00:00:00 2001 From: Stanzabird Date: Thu, 4 Feb 2021 02:36:03 +0000 Subject: [PATCH 13/29] Update README2.md --- README2.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README2.md b/README2.md index 5dde730..6edb326 100644 --- a/README2.md +++ b/README2.md @@ -24,7 +24,7 @@ BRANDING: resource files * build fail on missing stubinstaller (might be a FF bug as it should just take missing stuff from the nightly branding folder?) - +`` $ mkdir stubinstaller $ cp bgstub.jpg stubinstaller $ pwd @@ -56,4 +56,4 @@ $ diff branding-nightly.txt branding-librewolf.txt < ./default24.png < ./default256.png $ - +`` From 24b84c0cbdb090e75671b733edbbdaef8d609b3b Mon Sep 17 00:00:00 2001 From: Stanzabird Date: Thu, 4 Feb 2021 02:37:28 +0000 Subject: [PATCH 14/29] Update README2.md --- README2.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README2.md b/README2.md index 6edb326..792bf47 100644 --- a/README2.md +++ b/README2.md @@ -24,7 +24,8 @@ BRANDING: resource files * build fail on missing stubinstaller (might be a FF bug as it should just take missing stuff from the nightly branding folder?) -`` + +``` $ mkdir stubinstaller $ cp bgstub.jpg stubinstaller $ pwd @@ -56,4 +57,5 @@ $ diff branding-nightly.txt branding-librewolf.txt < ./default24.png < ./default256.png $ -`` +``` + From c998b1538751bba53cb562047f70ae5b1cc219b6 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 09:12:46 +0100 Subject: [PATCH 15/29] changes --- build.sh | 81 ++++++++++++++++++++++++++++++++++++-------------------- 1 file changed, 53 insertions(+), 28 deletions(-) diff --git a/build.sh b/build.sh index 8129294..6d926fe 100644 --- a/build.sh +++ b/build.sh @@ -5,7 +5,6 @@ pkgname=librewolf _pkgname=LibreWolf pkgver=85.0 -#srcdir=/c/mozilla-source @@ -23,8 +22,6 @@ fetch() { - - prepare() { rm -rf firefox-$pkgver tar xf firefox-$pkgver.source.tar.xz @@ -69,31 +66,39 @@ mk_add_options MOZ_TELEMETRY_REPORTING=0 END + patch -p1 -i ../remove_addons.patch patch -p1 -i ../megabar.patch patch -p1 -i ../unity-menubar.patch - + # Disabling Pocket sed -i "s/'pocket'/#'pocket'/g" browser/components/moz.build # this one only to remove an annoying error message: sed -i 's#SaveToPocket.init();#// SaveToPocket.init();#g' browser/components/BrowserGlue.jsm - + # Remove Internal Plugin Certificates _cert_sed='s#if (aCert.organizationalUnit == "Mozilla [[:alpha:]]\+") {\n' _cert_sed+='[[:blank:]]\+return AddonManager\.SIGNEDSTATE_[[:upper:]]\+;\n' _cert_sed+='[[:blank:]]\+}#' _cert_sed+='// NOTE: removed#g' - - # FIXME: on windows: the sed.exe in MozBuild is too old, no -z, using the one from Git instead. - mysed='/c/mozilla-source/Git/usr/bin/sed.exe' + # on windows: the sed.exe in MozBuild is too old, no -z, using the one from Git instead. + if [ -f '/c/mozilla-build/start-shell.bat' ]; then + mysed='/c/mozilla-source/Git/usr/bin/sed.exe' + if [ ! -f $mysed ]; then + echo 'build.sh: For the build to work, copy "c:\program files\Git" folder into "c:\mozilla-source".' + exit + fi + else + $mysed='sed' + fi $mysed -z "$_cert_sed" -i toolkit/mozapps/extensions/internal/XPIInstall.jsm - + # allow SearchEngines option in non-ESR builds sed -i 's#"enterprise_only": true,#"enterprise_only": false,#g' browser/components/enterprisepolicies/schemas/policies-schema.json @@ -107,28 +112,25 @@ END - cp -r ../common/source_files/* ./ + # FIXME: this 'mozconfig' file in the 'common' submodule should be removed - # this submodule is purely for the branding. I imagine that we want the - # missing_branding_files into the 'common' submodule. + # this submodule is purely for the branding. rm -f mozconfig - # FIX: on windows: the stubinstaller folder is missing from the librewolf branding folder. + # FIXME: on windows: the stubinstaller folder is missing from the librewolf branding folder. + # this might be a bug in FF however as it seems to take missing branding resources from + # the nightly branding. We probably want this stuff merged into the 'common' submodule. cp -r ../missing_branding_files/stubinstaller browser/branding/librewolf # just a straight copy for now.. cp ../mozconfig .mozconfig - + cd .. } - - - - build() { cd firefox-$pkgver @@ -138,13 +140,21 @@ build() { } + package() { cd firefox-$pkgver ./mach package + cd .. +} + +installer_win() { + cd firefox-$pkgver + # apply the LibreWolf settings cp -rv ../settings/* obj-x86_64-pc-mingw32/dist/librewolf + # recreate the zip file.. cd obj-x86_64-pc-mingw32/dist rm -f librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip @@ -152,19 +162,26 @@ package() { /c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum cp librewolf-$pkgver.en-US.win64.zip* ../../.. cd ../.. - + + cd .. +} + +installer_macos() { + cd firefox-$pkgver + + # TODO: we want to apply the librewolf settings and make the .dmg file here. + echo 'build.sh: installer_macos() Not implemented yet.' cd .. } - - - # windows: change $PATH to find all the build tools in .mozbuild -# this might do the trick on macos aswell -export TPATH=$HOME/.mozbuild/clang/bin:$HOME/.mozbuild/cbindgen:$HOME/.mozbuild/node:$HOME/.mozbuild/nasm -export PATH=$TPATH:$PATH +# this might do the trick on macos aswell? +if [ -f '/c/mozilla-build/start-shell.bat' ]; then + export TPATH=$HOME/.mozbuild/clang/bin:$HOME/.mozbuild/cbindgen:$HOME/.mozbuild/node:$HOME/.mozbuild/nasm + export PATH=$TPATH:$PATH +fi @@ -186,8 +203,16 @@ if [[ "$*" == *package* ]]; then package done_something=1 fi - -if (( done_something == 0 )); then - echo "Usage: $0 fetch | prepare | build | package" +if [[ "$*" == *installer_win* ]]; then + installer_win + done_something=1 +fi +if [[ "$*" == *installer_macos* ]]; then + installer_macos + done_something=1 fi +if (( done_something == 0 )); then + echo "Usage: $0 fetch | prepare | build | package | installer_win | installer_mac" + exit +fi From 312be4b89b4908e6a829742d278b1ed489d5d0e3 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 09:15:01 +0100 Subject: [PATCH 16/29] changes --- build.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/build.sh b/build.sh index 6d926fe..50f3511 100644 --- a/build.sh +++ b/build.sh @@ -160,6 +160,7 @@ installer_win() { rm -f librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf /c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum + rm -f ../../../librewolf-$pkgver.en-US.win64.zip* cp librewolf-$pkgver.en-US.win64.zip* ../../.. cd ../.. From e8bc848ec8431ca2b38ee462dfb3152a2a610fa3 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 10:50:56 +0100 Subject: [PATCH 17/29] Removed install_script.txt because the profile folder requested here is checked to be Ok. --- install_script.txt | 1 - 1 file changed, 1 deletion(-) delete mode 100644 install_script.txt diff --git a/install_script.txt b/install_script.txt deleted file mode 100644 index 081cb68..0000000 --- a/install_script.txt +++ /dev/null @@ -1 +0,0 @@ -#C:\Users\\AppData\Roaming\LibreWolf\Profiles\xxxxxxxx.default \ No newline at end of file From 605e073162e4deebdce4438044264aca01d39ea3 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Thu, 4 Feb 2021 18:00:10 +0100 Subject: [PATCH 18/29] Updated the readme a bit --- README.md | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 46ba00a..0ee0f37 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,22 @@ -This repository is still a work in progress +This repository is still a work in progress. +But we have a zip file available for testing right now.. -This build does require you to: +Download link to the prerelease alpha zip file is [here](https://gitlab.com/librewolf-community/browser/windows/uploads/5e9d436515d315d4e8953f88bf02bd99/librewolf-85.0.en-US.win64.zip). + +To do: + +* Creating an installer. +* Branding issues, include a good icon for librewolf.exe +* Other Branding Issues +* Improve this README.md to contain detailed instructions on how to build. + +For now, if you want to attempt to build, this build does require you to: * First build the mozilla-unified as explained in the mozilla docs, using all the ./mach bootstrap stuff * You can delete this mozilla-unified thing to save some space (try ./mach run on it just for fun) * Then clone the windows repo -* cd into it, and build with: **time bash build.sh fetch prepare build package** +* cd into it, and build with: **time bash build.sh fetch prepare build package installer_win** * you can perform each of the build steps individually and the overall script structure follows PKGBULD as used on Archlinux * This will produce a **librewolf-85.0.en-US.win64.zip** in this windows folder. From 3cf15ede146c2e235345345a2f414915998bf657 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Fri, 5 Feb 2021 23:15:23 +0100 Subject: [PATCH 19/29] split the installer stuff into a seperate shell script --- build.sh | 68 +++++++++++++++++++++--------------------------- installer-win.sh | 11 ++++++++ 2 files changed, 40 insertions(+), 39 deletions(-) create mode 100644 installer-win.sh diff --git a/build.sh b/build.sh index 50f3511..d10600e 100644 --- a/build.sh +++ b/build.sh @@ -151,31 +151,14 @@ package() { installer_win() { cd firefox-$pkgver - - # apply the LibreWolf settings - cp -rv ../settings/* obj-x86_64-pc-mingw32/dist/librewolf - - # recreate the zip file.. - cd obj-x86_64-pc-mingw32/dist - rm -f librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip - zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf - /c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum - rm -f ../../../librewolf-$pkgver.en-US.win64.zip* - cp librewolf-$pkgver.en-US.win64.zip* ../../.. - cd ../.. + + # there is just too much garbage in this installer function to + # have it all here.. + . installer-win.sh cd .. } -installer_macos() { - cd firefox-$pkgver - - # TODO: we want to apply the librewolf settings and make the .dmg file here. - echo 'build.sh: installer_macos() Not implemented yet.' - cd .. -} - - # windows: change $PATH to find all the build tools in .mozbuild # this might do the trick on macos aswell? @@ -188,32 +171,39 @@ fi # process commandline arguments and do something done_something=0 -if [[ "$*" == *fetch* ]]; then +if [[ "$*" == *all* ]]; then fetch - done_something=1 -fi -if [[ "$*" == *prepare* ]]; then prepare - done_something=1 -fi -if [[ "$*" == *build* ]]; then build - done_something=1 -fi -if [[ "$*" == *package* ]]; then package - done_something=1 -fi -if [[ "$*" == *installer_win* ]]; then installer_win done_something=1 -fi -if [[ "$*" == *installer_macos* ]]; then - installer_macos - done_something=1 +else + if [[ "$*" == *fetch* ]]; then + fetch + done_something=1 + fi + if [[ "$*" == *prepare* ]]; then + prepare + done_something=1 + fi + if [[ "$*" == *build* ]]; then + build + done_something=1 + fi + if [[ "$*" == *package* ]]; then + package + done_something=1 + fi + if [[ "$*" == *installer_win* ]]; then + installer_win + done_something=1 + fi fi + if (( done_something == 0 )); then - echo "Usage: $0 fetch | prepare | build | package | installer_win | installer_mac" + echo "Usage: $0 fetch | prepare | build | package | installer_win" + echo " use the parameter 'all' to just do everything." exit fi diff --git a/installer-win.sh b/installer-win.sh new file mode 100644 index 0000000..9a917ff --- /dev/null +++ b/installer-win.sh @@ -0,0 +1,11 @@ +# apply the LibreWolf settings +cp -rv ../settings/* obj-x86_64-pc-mingw32/dist/librewolf + +# recreate the zip file.. +cd obj-x86_64-pc-mingw32/dist +rm -f librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip +zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf +/c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum +rm -f ../../../librewolf-$pkgver.en-US.win64.zip* +cp librewolf-$pkgver.en-US.win64.zip* ../../.. +cd ../.. From a783187ed4d8a8aab1946eafd5600ee73fea5dd3 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 00:25:48 +0100 Subject: [PATCH 20/29] made installer_win easy to use (tab completion) --- build.sh | 38 ++++++++++++------------------- installer-win.sh => installer_win | 0 2 files changed, 14 insertions(+), 24 deletions(-) rename installer-win.sh => installer_win (100%) diff --git a/build.sh b/build.sh index d10600e..70a8914 100644 --- a/build.sh +++ b/build.sh @@ -154,7 +154,7 @@ installer_win() { # there is just too much garbage in this installer function to # have it all here.. - . installer-win.sh + . ../installer_win cd .. } @@ -171,39 +171,29 @@ fi # process commandline arguments and do something done_something=0 -if [[ "$*" == *all* ]]; then +if [[ "$*" == *fetch* ]]; then fetch + done_something=1 +fi +if [[ "$*" == *prepare* ]]; then prepare + done_something=1 +fi +if [[ "$*" == *build* ]]; then build + done_something=1 +fi +if [[ "$*" == *package* ]]; then package + done_something=1 +fi +if [[ "$*" == *installer_win* ]]; then installer_win done_something=1 -else - if [[ "$*" == *fetch* ]]; then - fetch - done_something=1 - fi - if [[ "$*" == *prepare* ]]; then - prepare - done_something=1 - fi - if [[ "$*" == *build* ]]; then - build - done_something=1 - fi - if [[ "$*" == *package* ]]; then - package - done_something=1 - fi - if [[ "$*" == *installer_win* ]]; then - installer_win - done_something=1 - fi fi if (( done_something == 0 )); then echo "Usage: $0 fetch | prepare | build | package | installer_win" - echo " use the parameter 'all' to just do everything." exit fi diff --git a/installer-win.sh b/installer_win similarity index 100% rename from installer-win.sh rename to installer_win From 54bd5916c8c7d7c458651b06647026979ca92e3c Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 13:45:32 +0100 Subject: [PATCH 21/29] first version of the installer --- .gitignore | 2 + build.sh | 8 ++- installer_win | 11 ---- installer_win.sh | 24 +++++++++ librewolf.nsi | 81 +++++++++++++++++++++++++++++ missing_branding_files/firefox.ico | Bin 0 -> 32038 bytes 6 files changed, 113 insertions(+), 13 deletions(-) delete mode 100644 installer_win create mode 100644 installer_win.sh create mode 100644 librewolf.nsi create mode 100644 missing_branding_files/firefox.ico diff --git a/.gitignore b/.gitignore index 1929584..6580505 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,5 @@ megabar.patch remove_addons.patch unity-menubar.patch mozconfig +Makefile +librewolf \ No newline at end of file diff --git a/build.sh b/build.sh index 70a8914..f071bc3 100644 --- a/build.sh +++ b/build.sh @@ -154,7 +154,7 @@ installer_win() { # there is just too much garbage in this installer function to # have it all here.. - . ../installer_win + . ../installer_win.sh cd .. } @@ -194,6 +194,10 @@ fi if (( done_something == 0 )); then - echo "Usage: $0 fetch | prepare | build | package | installer_win" + fetch + prepare + build + package + installer_win exit fi diff --git a/installer_win b/installer_win deleted file mode 100644 index 9a917ff..0000000 --- a/installer_win +++ /dev/null @@ -1,11 +0,0 @@ -# apply the LibreWolf settings -cp -rv ../settings/* obj-x86_64-pc-mingw32/dist/librewolf - -# recreate the zip file.. -cd obj-x86_64-pc-mingw32/dist -rm -f librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip -zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf -/c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum -rm -f ../../../librewolf-$pkgver.en-US.win64.zip* -cp librewolf-$pkgver.en-US.win64.zip* ../../.. -cd ../.. diff --git a/installer_win.sh b/installer_win.sh new file mode 100644 index 0000000..ede8372 --- /dev/null +++ b/installer_win.sh @@ -0,0 +1,24 @@ +# apply the LibreWolf settings +cp -rv ../settings/* obj-x86_64-pc-mingw32/dist/librewolf + +# recreate the zip file.. + +cd obj-x86_64-pc-mingw32/dist +# clean garbage files +rm -rf librewolf/uninstall librewolf/maintenanceservice* librewolf/pingsender.exe +# be sure to remove the previous zip file.. +rm -f librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip +zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf +/c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum +# copy the resulting zip file +rm -vf ../../../librewolf-$pkgver.en-US.win64.zip* +cp -v librewolf-$pkgver.en-US.win64.zip* ../../.. +cd ../.. + +# now to try to make the installer +pushd .. +rm -vrf librewolf +unzip librewolf-$pkgver.en-US.win64.zip +cp -v missing_branding_files/firefox.ico librewolf/librewolf.ico +makensis-3.01.exe librewolf.nsi +popd diff --git a/librewolf.nsi b/librewolf.nsi new file mode 100644 index 0000000..ff1e667 --- /dev/null +++ b/librewolf.nsi @@ -0,0 +1,81 @@ +# +# Change these values to fit your application... +# + +!define APPNAME "LibreWolf" # Full app name, like: Gtk+ 2.0 Hello World +!define PROGNAME "librewolf" # executable name, like: gtk2hello +!define PROG_VERSION "85.0" # the program version, like: 0.3.0 +!define ICON_NAME "librewolf.ico" # filename of icon to use for this app, this file should be in src/ +!define COMPANYNAME "LibreWolf" # Your name, or company (or just the program name) +!define ESTIMATED_SIZE 190000 # Estimated size (in KB) of installed program for use in "add or remove programs" / 190 MB + +# +# The actual installer/uninstaller, you should not need to change much here below +# + +Name "${PROGNAME}" +OutFile "${PROGNAME}-${PROG_VERSION}.en-US.win64-setup.exe" +InstallDir $PROGRAMFILES64\${APPNAME} +RequestExecutionLevel admin + +Page directory +Page instfiles + +function .onInit + setShellVarContext all +functionEnd + +Section "${PROGNAME}" + + # Copy files + SetOutPath $INSTDIR + File /r librewolf\*.* + + # Start Menu + createDirectory "$SMPROGRAMS\${COMPANYNAME}" + createShortCut "$SMPROGRAMS\${COMPANYNAME}\${APPNAME}.lnk" "$INSTDIR\${PROGNAME}.exe" "" "$INSTDIR\${ICON_NAME}" + + # Uninstaller + writeUninstaller "$INSTDIR\uninstall.exe" + + # Registry information for add/remove programs + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "DisplayName" "${APPNAME}" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "UninstallString" "$\"$INSTDIR\uninstall.exe$\"" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "QuietUninstallString" "$\"$INSTDIR\uninstall.exe$\" /S" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "InstallLocation" "$\"$INSTDIR$\"" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "DisplayIcon" "$\"$INSTDIR\${ICON_NAME}$\"" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "Publisher" "${COMPANYNAME}" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "DisplayVersion" "${PROG_VERSION}" + # There is no option for modifying or repairing the install + WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "NoModify" 1 + WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "NoRepair" 1 + # Set the INSTALLSIZE constant (!defined at the top of this script) so Add/Remove Programs can accurately report the size + WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "EstimatedSize" ${ESTIMATED_SIZE} + +SectionEnd + +# Before uninstall, ask for confirmation +function un.onInit + SetShellVarContext all + + #Verify the uninstaller - last chance to back out + MessageBox MB_OKCANCEL "Permanantly remove ${APPNAME}?" IDOK next + Abort + next: +functionEnd + +# Uninstaller +section "uninstall" + + # Remove Start Menu launcher + delete "$SMPROGRAMS\${COMPANYNAME}\${APPNAME}.lnk" + # Try to remove the Start Menu folder - this will only happen if it is empty + rmDir "$SMPROGRAMS\${COMPANYNAME}" + + # Remove files + rmDir /r $INSTDIR + + # Remove uninstaller information from the registry + DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" + +sectionEnd diff --git a/missing_branding_files/firefox.ico b/missing_branding_files/firefox.ico new file mode 100644 index 0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f33f32af9ad825 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 19:01:36 +0100 Subject: [PATCH 22/29] changes --- README.md | 79 ++++++++++++++++++++++++++++++++++++++++++------ README2.md | 47 ---------------------------- build.sh | 4 +-- installer_win.sh | 28 ++++++++--------- 4 files changed, 86 insertions(+), 72 deletions(-) diff --git a/README.md b/README.md index 0ee0f37..c7f9391 100644 --- a/README.md +++ b/README.md @@ -1,22 +1,83 @@ +LibreWolf for Win64 +------------------- + This repository is still a work in progress. -But we have a zip file available for testing right now.. +But we have a zip file and an installer available for testing right now.. -Download link to the prerelease alpha zip file is [here](https://gitlab.com/librewolf-community/browser/windows/uploads/5e9d436515d315d4e8953f88bf02bd99/librewolf-85.0.en-US.win64.zip). +Download link to this prerelease is: +* Zip file is: [librewolf-85.0.en-US.win64.zip](https://gitlab.com/librewolf-community/browser/windows/uploads/5e9d436515d315d4e8953f88bf02bd99/librewolf-85.0.en-US.win64.zip). +* Installer file is: [librewolf-85.0.en-US.win64-setup.exe](). -To do: -* Creating an installer. -* Branding issues, include a good icon for librewolf.exe -* Other Branding Issues -* Improve this README.md to contain detailed instructions on how to build. +Building the package: +--------------------- For now, if you want to attempt to build, this build does require you to: * First build the mozilla-unified as explained in the mozilla docs, using all the ./mach bootstrap stuff * You can delete this mozilla-unified thing to save some space (try ./mach run on it just for fun) * Then clone the windows repo -* cd into it, and build with: **time bash build.sh fetch prepare build package installer_win** -* you can perform each of the build steps individually and the overall script structure follows PKGBULD as used on Archlinux +* cd into it, and build with: **time bash build.sh** +* You can perform each of the build steps individually and the overall script structure follows PKGBULD as used on Archlinux * This will produce a **librewolf-85.0.en-US.win64.zip** in this windows folder. +Once you have built the entire mozilla-unified with all the mach bootstrap stuff (which will +install the needed binaries in $HOME/.mozbuild), don't forget to copy the entire +C:\Program Files\Git folder to /c/mozilla-source to get a sed.exe that understands the -z option, +and to get sha256sum.exe. + +build.sh +-------- + +You can perform all the steps on one go, or perform the build steps individually, to note: +* build.sh fetch prepare build package installer_win + +To do: +------ + +* Branding issues. +* Improve this README.md to contain better, detailed instructions on how to build. +* problem with old sed. does not recognize -z. using the one from Git might be a work around. + + +Branding issue: resource files +------------------------------ + +* This section is just some notes. +* Build fail on missing stubinstaller (might be a FF bug as it should just take missing +stuff from the nightly branding folder?) + +``` +$ mkdir stubinstaller +$ cp bgstub.jpg stubinstaller +$ pwd +/c/mozilla-source/firefox-85.0/browser/branding/librewolf +$ + +* checking all the different files in nightly and librewolf + +$ cd nightly +$ find . | sort > /c/mozilla-source/branding-nightly.txt +$ cd ../librewolf/ +$ find . | sort > /c/mozilla-source/branding-librewolf.txt + + +$ diff branding-nightly.txt branding-librewolf.txt +4a5,6 +> ./bgstub.jpg +> ./bgstub_2x.jpg +7a10 +> ./content/about-background.png +9,10d11 +< ./content/about-logo.svg +< ./content/about-logo@2x.png +14,15d14 +< ./content/aboutlogins.svg +< ./content/firefox-wordmark.svg +22,24d20 +< ./default22.png +< ./default24.png +< ./default256.png +$ +``` diff --git a/README2.md b/README2.md index 792bf47..73c93b4 100644 --- a/README2.md +++ b/README2.md @@ -1,12 +1,6 @@ Just some notes --------------- -Once you have built the entire mozilla-unified with all the mach bootstrap stuff (which will -install the needed binaries in $HOME/.mozbuild), don't forget to copy the entire -C:\Program Files\Git folder to /c/mozilla-source to get a sed.exe that understands the -z option, -and to get sha256sum.exe. - - To build, one should use the following command in the checked out windows repo: $ time bash build.sh fetch prepare build package @@ -16,46 +10,5 @@ the final .zip is in: C:\mozilla-source\windows -* problem with old sed. does not recognize -z. using the one from Git might be a work around. -BRANDING: resource files -======================== - -* build fail on missing stubinstaller (might be a FF bug as it should just take missing -stuff from the nightly branding folder?) - -``` -$ mkdir stubinstaller -$ cp bgstub.jpg stubinstaller -$ pwd -/c/mozilla-source/firefox-85.0/browser/branding/librewolf -$ - -* checking all the different files in nightly and librewolf - -$ cd nightly -$ find . | sort > /c/mozilla-source/branding-nightly.txt -$ cd ../librewolf/ -$ find . | sort > /c/mozilla-source/branding-librewolf.txt - - -$ diff branding-nightly.txt branding-librewolf.txt -4a5,6 -> ./bgstub.jpg -> ./bgstub_2x.jpg -7a10 -> ./content/about-background.png -9,10d11 -< ./content/about-logo.svg -< ./content/about-logo@2x.png -14,15d14 -< ./content/aboutlogins.svg -< ./content/firefox-wordmark.svg -22,24d20 -< ./default22.png -< ./default24.png -< ./default256.png -$ -``` - diff --git a/build.sh b/build.sh index f071bc3..b09c882 100644 --- a/build.sh +++ b/build.sh @@ -160,6 +160,7 @@ installer_win() { } + # windows: change $PATH to find all the build tools in .mozbuild # this might do the trick on macos aswell? if [ -f '/c/mozilla-build/start-shell.bat' ]; then @@ -192,12 +193,11 @@ if [[ "$*" == *installer_win* ]]; then done_something=1 fi - +# by default, do the whole thing.. if (( done_something == 0 )); then fetch prepare build package installer_win - exit fi diff --git a/installer_win.sh b/installer_win.sh index ede8372..002adbe 100644 --- a/installer_win.sh +++ b/installer_win.sh @@ -2,23 +2,23 @@ cp -rv ../settings/* obj-x86_64-pc-mingw32/dist/librewolf # recreate the zip file.. - cd obj-x86_64-pc-mingw32/dist -# clean garbage files -rm -rf librewolf/uninstall librewolf/maintenanceservice* librewolf/pingsender.exe -# be sure to remove the previous zip file.. -rm -f librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip -zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf -/c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum -# copy the resulting zip file -rm -vf ../../../librewolf-$pkgver.en-US.win64.zip* -cp -v librewolf-$pkgver.en-US.win64.zip* ../../.. + # clean garbage files + rm -vrf librewolf/uninstall librewolf/maintenanceservice* librewolf/pingsender.exe + # be sure to remove the previous zip file.. + rm -vf librewolf-$pkgver.en-US.win64.txt librewolf-$pkgver.en-US.win64.zip + zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf + /c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum + # copy the resulting zip file + rm -vf ../../../librewolf-$pkgver.en-US.win64.zip* + cp -v librewolf-$pkgver.en-US.win64.zip* ../../.. cd ../.. # now to try to make the installer pushd .. -rm -vrf librewolf -unzip librewolf-$pkgver.en-US.win64.zip -cp -v missing_branding_files/firefox.ico librewolf/librewolf.ico -makensis-3.01.exe librewolf.nsi + rm -vrf librewolf + unzip librewolf-$pkgver.en-US.win64.zip + cp -v missing_branding_files/firefox.ico librewolf/librewolf.ico + makensis-3.01.exe librewolf.nsi + /c/mozilla-source/Git/usr/bin/sha256sum.exe librewolf-$pkgver.en-US.win64-setup.exe > librewolf-$pkgver.en-US.win64-setup.exe.sha256sum popd From 20c1f67709f88f39b71657bbe655f98768aa9a0b Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 19:01:44 +0100 Subject: [PATCH 23/29] changes --- README2.md | 14 -------------- 1 file changed, 14 deletions(-) delete mode 100644 README2.md diff --git a/README2.md b/README2.md deleted file mode 100644 index 73c93b4..0000000 --- a/README2.md +++ /dev/null @@ -1,14 +0,0 @@ -Just some notes ---------------- - -To build, one should use the following command in the checked out windows repo: - -$ time bash build.sh fetch prepare build package - - -the final .zip is in: - C:\mozilla-source\windows - - - - From ae8e27122252111d5bba41072f3c07a505e2f0d8 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 22:16:54 +0100 Subject: [PATCH 24/29] changes --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index c7f9391..0eed006 100644 --- a/README.md +++ b/README.md @@ -7,8 +7,9 @@ But we have a zip file and an installer available for testing right now.. Download link to this prerelease is: * Zip file is: [librewolf-85.0.en-US.win64.zip](https://gitlab.com/librewolf-community/browser/windows/uploads/5e9d436515d315d4e8953f88bf02bd99/librewolf-85.0.en-US.win64.zip). -* Installer file is: [librewolf-85.0.en-US.win64-setup.exe](). +* The installer is: [librewolf-85.0.en-US.win64-setup.exe](). +Note: If your version of LibreWolf does _not_ run, an additional install of the (Microsoft Visual C++ 2010 Redistributable Package (x64))[https://www.microsoft.com/en-us/download/details.aspx?id=14632] might be required. Building the package: --------------------- From 46c94f749c0dafbeff7ff82a84dd542fea3dda14 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 22:17:36 +0100 Subject: [PATCH 25/29] changes --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 0eed006..6f86041 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ Download link to this prerelease is: * Zip file is: [librewolf-85.0.en-US.win64.zip](https://gitlab.com/librewolf-community/browser/windows/uploads/5e9d436515d315d4e8953f88bf02bd99/librewolf-85.0.en-US.win64.zip). * The installer is: [librewolf-85.0.en-US.win64-setup.exe](). -Note: If your version of LibreWolf does _not_ run, an additional install of the (Microsoft Visual C++ 2010 Redistributable Package (x64))[https://www.microsoft.com/en-us/download/details.aspx?id=14632] might be required. +Note: If your version of LibreWolf does _not_ run, an additional install of the (Microsoft Visual C++ 2010 Redistributable Package for x64)[https://www.microsoft.com/en-us/download/details.aspx?id=14632] might be required. Building the package: --------------------- From a9fddc53234767a2c97d3bf247660648ec234a8e Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 22:18:20 +0100 Subject: [PATCH 26/29] changes --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 6f86041..dc4b12f 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ Download link to this prerelease is: * Zip file is: [librewolf-85.0.en-US.win64.zip](https://gitlab.com/librewolf-community/browser/windows/uploads/5e9d436515d315d4e8953f88bf02bd99/librewolf-85.0.en-US.win64.zip). * The installer is: [librewolf-85.0.en-US.win64-setup.exe](). -Note: If your version of LibreWolf does _not_ run, an additional install of the (Microsoft Visual C++ 2010 Redistributable Package for x64)[https://www.microsoft.com/en-us/download/details.aspx?id=14632] might be required. +Note: If your version of LibreWolf does _not_ run, an additional install of the [Microsoft Visual C++ 2010 Redistributable Package (x64)])(https://www.microsoft.com/en-us/download/details.aspx?id=14632) might be required. Building the package: --------------------- From 95b0b0b23fa196519e86cc474ef485ff665dbcca Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 22:18:57 +0100 Subject: [PATCH 27/29] changes --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index dc4b12f..f63c2d2 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ Download link to this prerelease is: * Zip file is: [librewolf-85.0.en-US.win64.zip](https://gitlab.com/librewolf-community/browser/windows/uploads/5e9d436515d315d4e8953f88bf02bd99/librewolf-85.0.en-US.win64.zip). * The installer is: [librewolf-85.0.en-US.win64-setup.exe](). -Note: If your version of LibreWolf does _not_ run, an additional install of the [Microsoft Visual C++ 2010 Redistributable Package (x64)])(https://www.microsoft.com/en-us/download/details.aspx?id=14632) might be required. +Note: If your version of LibreWolf does _not_ run, an additional install of the [Microsoft Visual C++ 2010 Redistributable Package (x64)](https://www.microsoft.com/en-us/download/details.aspx?id=14632) might be required. Building the package: --------------------- From 277f27a839d9a5094327efdb9a1b8a439c770d88 Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 23:06:51 +0100 Subject: [PATCH 28/29] changes --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index f63c2d2..69ca76c 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ But we have a zip file and an installer available for testing right now.. Download link to this prerelease is: * Zip file is: [librewolf-85.0.en-US.win64.zip](https://gitlab.com/librewolf-community/browser/windows/uploads/5e9d436515d315d4e8953f88bf02bd99/librewolf-85.0.en-US.win64.zip). -* The installer is: [librewolf-85.0.en-US.win64-setup.exe](). +* The installer is: [librewolf-85.0.en-US.win64-setup.exe](https://gitlab.com/librewolf-community/browser/windows/uploads/ec6f7e7dc1096bf7730f503d856d3a9f/librewolf-85.0.en-US.win64-setup.exe). Note: If your version of LibreWolf does _not_ run, an additional install of the [Microsoft Visual C++ 2010 Redistributable Package (x64)](https://www.microsoft.com/en-us/download/details.aspx?id=14632) might be required. From 5d316be30a4a64fb8ba3001c373564c21c43437d Mon Sep 17 00:00:00 2001 From: Bert van der Weerd Date: Sat, 6 Feb 2021 23:16:18 +0100 Subject: [PATCH 29/29] changes --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 69ca76c..8a8af89 100644 --- a/README.md +++ b/README.md @@ -37,6 +37,7 @@ You can perform all the steps on one go, or perform the build steps individually To do: ------ +* Listing known issues in this README.md * Branding issues. * Improve this README.md to contain better, detailed instructions on how to build. * problem with old sed. does not recognize -z. using the one from Git might be a work around.