Compare commits
No commits in common. "master" and "v86.0.1-1" have entirely different histories.
11 changed files with 602 additions and 25 deletions
9
.gitignore
vendored
Normal file
9
.gitignore
vendored
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
firefox-*
|
||||
librewolf-*
|
||||
megabar.patch
|
||||
remove_addons.patch
|
||||
unity-menubar.patch
|
||||
mozconfig
|
||||
Makefile
|
||||
librewolf
|
||||
tmp.nsi
|
||||
6
.gitmodules
vendored
Normal file
6
.gitmodules
vendored
Normal file
|
|
@ -0,0 +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
|
||||
31
HOW_TO_BUILD.md
Normal file
31
HOW_TO_BUILD.md
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
Building the package means first getting FF itself to build:
|
||||
------------------------------------------------------------
|
||||
|
||||
These instructions are for an _interactive_ build.
|
||||
|
||||
* Follow the guidelines in the [Building Firefox On Windows](https://firefox-source-docs.mozilla.org/setup/windows_build.html) documentation from mozilla.org. And I actually recommend to follow this documentation until you have a working |mach run|. I also recommend using Git, not Mercurial, as we're going to need it later in our build.sh.
|
||||
* 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.
|
||||
* I also had to download/install in my appdata, python 3, a recent version (just search it), I ended up with the following command line:
|
||||
```
|
||||
C:/Users/librewolf/AppData/Local/Programs/Python/Python39/python.exe ./bootstrap.py --vcs=git --application-choice browser --no-interactive --no-system-changes
|
||||
```
|
||||
* You can now delete the mozilla-unified folder, or keep it, if you want to play with FF itself.
|
||||
* Then clone the windows repo:
|
||||
```
|
||||
git clone --recursive https://gitlab.com/librewolf-community/browser/windows.git
|
||||
```
|
||||
* cd into it, and build with:
|
||||
```
|
||||
bash build.sh
|
||||
```
|
||||
* This should produce a zip and installer exe in your top folder.
|
||||
|
||||
build.sh
|
||||
--------
|
||||
|
||||
You can perform all the steps on one go, or perform the build steps individually, to note:
|
||||
```
|
||||
bash build.sh fetch prepare build package installer_win
|
||||
```
|
||||
36
KNOWN_ISSUES.md
Normal file
36
KNOWN_ISSUES.md
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
Known Issues (2021-02-07)
|
||||
-------------------------
|
||||
|
||||
These issues are already reported, and sorted by priority:
|
||||
|
||||
* about:addons search not working (use [https://addons.mozilla.org/](https://addons.mozilla.org/) directly) ([issue #16](https://gitlab.com/librewolf-community/browser/windows/-/issues/16))
|
||||
* Unable to set as default browser ([issue #15](https://gitlab.com/librewolf-community/browser/windows/-/issues/15))
|
||||
* Automation builds. This seems to be a possibility mentioned [here](https://firefox-source-docs.mozilla.org/setup/windows_build.html#building-firefox-on-windows). ([issue #6](https://gitlab.com/librewolf-community/browser/windows/-/issues/6))
|
||||
* Is there any way to update? (no, not soon) ([issue #12](https://gitlab.com/librewolf-community/browser/windows/-/issues/12))
|
||||
* Previous session tabs, doesn't restoring after restart, although option is enabled in settings. ([issue #11](https://gitlab.com/librewolf-community/browser/windows/-/issues/11))
|
||||
* There some issue with rendering. All looks a bit blurred, or if there no smoothing enabled. ([issue #11](https://gitlab.com/librewolf-community/browser/windows/-/issues/11))
|
||||
* Choosing a bookmark inside an empty tab loads the page in the same tab, else, if the tab is not empty, it loads in a new tab. Right-clicking on the bookmark, and selecting "Open" (which is bold) from the context menu correctly opens the link in the same tab. Essentially, unless the tab is empty, left-clicking on a link behaves as if middle-mouse-clicking on a link. ([issue #11](https://gitlab.com/librewolf-community/browser/windows/-/issues/11))
|
||||
* Middle-mouse-button scrolling does not work? Is this intentional, and if yes, is there a setting to re-enable it again? ([issue #11](https://gitlab.com/librewolf-community/browser/windows/-/issues/11))
|
||||
* When I tweaked some settings according to privacytools.io and I tried coveryourtracks it gave 17 bits of data, while a vanilla hardened Firefox gave 14 bits in same Configuration. This is very concerning as librewolf is supposed to perform better than FF. ([issue #11](https://gitlab.com/librewolf-community/browser/windows/-/issues/11))
|
||||
* _Theme Aspenglow_ and the minimize/maximize/close buttons don't work correctly. ([issue #11](https://gitlab.com/librewolf-community/browser/windows/-/issues/11))
|
||||
* GPO (Group Policy Objects) support. ([issue #3](https://gitlab.com/librewolf-community/browser/windows/-/issues/3))
|
||||
|
||||
Other issues
|
||||
------------
|
||||
|
||||
The following issues are not considered windows-specific:
|
||||
|
||||
* [issue #8](https://gitlab.com/librewolf-community/browser/windows/-/issues/8): belongs in [LibreWolf / Settings](https://gitlab.com/librewolf-community/settings).
|
||||
* [issue #9](https://gitlab.com/librewolf-community/browser/windows/-/issues/9): belongs in [LibreWolf / Settings](https://gitlab.com/librewolf-community/settings).
|
||||
|
||||
The following issues are considered closed:
|
||||
|
||||
* [issue #2](https://gitlab.com/librewolf-community/browser/windows/-/issues/2)
|
||||
* [issue #4](https://gitlab.com/librewolf-community/browser/windows/-/issues/4)
|
||||
|
||||
These don't have their own issue yet:
|
||||
|
||||
* IPV6 issues, it's not working properly?
|
||||
* problem with old sed. does not recognize -z. using the one from Git might be a work around.
|
||||
* What IP address does LW show on my sb site, and why does it show anything at all when Bing does show the ip address of my nginx? what header stuff is going on?
|
||||
* why does this anoying thing happen to my 'copy username' menu in lastpass (the local menu shows up)
|
||||
32
README.md
32
README.md
|
|
@ -1,30 +1,12 @@
|
|||
# LibreWolf Issue Tracker & Update Tools 🚀
|
||||
LibreWolf for Win64
|
||||
-------------------
|
||||
|
||||
Welcome to the **LibreWolf for Windows** repository! This repository is now dedicated to the **Issue Tracker**. Submit your issues and get the latest updates on LibreWolf for Windows.
|
||||
We have a zip file and an installer available for download.. We no longer consider these builds alpha quality, but it is not out of beta yet either.
|
||||
|
||||
To download the latest release, visit the [official LibreWolf release page](https://gitlab.com/librewolf-community/browser/bsys6/-/releases). For installation options, check out the [FAQ](https://librewolf.net/docs/faq/).
|
||||
**Downloads**: To get the installer, head over to the **[releases](https://gitlab.com/librewolf-community/browser/windows/-/releases)** page.
|
||||
|
||||
## Update Tools 🛠️
|
||||
Note: If your version of LibreWolf does _not_ run, an additional install of the [vc_redist.x64.exe](https://aka.ms/vs/16/release/VC_redist.x64.exe) component might be required.
|
||||
|
||||
Stay secure and up-to-date with these LibreWolf update tools:
|
||||
This repository is for the windows installer, this repo is not for _librewolf.cfg_ issues, that goes [here](https://gitlab.com/librewolf-community/settings). These config file settings are system-wide for all users.
|
||||
|
||||
1. **LibreWolf WinUpdater**: Kudos to @ltguillaume for this [automatic updater](https://codeberg.org/ltguillaume/librewolf-winupdater) that can be set up to update LibreWolf automatically or run manually.
|
||||
|
||||
2. **LibreWolf Update Checker Extension**: Created by Defkev, this [extension](https://addons.mozilla.org/en-US/firefox/addon/librewolf-updater/) will notify you when an update is available and guide you to the download link.
|
||||
|
||||
> Please note: The *updater* can _install_ updates automatically, while the *extension* can only _check_ for updates.
|
||||
|
||||
## LibreWolf for Windows 🖥️
|
||||
|
||||
- LibreWolf supports multiple UI languages, available in settings.
|
||||
- The latest **-portable.zip** release is self-contained and can be run on removable storage.
|
||||
|
||||
## Issue Tracker 🎫
|
||||
|
||||
- For issues with Settings or Advanced Settings (`about:config`), submit them to the [settings repository](https://gitlab.com/librewolf-community/settings/-/issues).
|
||||
- For other issues, such as crashes/theme/graphics/speed problems, submit them to [issues for windows repository](https://gitlab.com/librewolf-community/browser/windows/-/issues).
|
||||
|
||||
## Building from Source 🏗️
|
||||
|
||||
- Our `bsys` build system supports cross-compiling from Linux to Windows. Building the Windows version from within Windows is not tested yet.
|
||||
- The build system can be found here: [bsys6](https://gitlab.com/librewolf-community/browser/bsys6).
|
||||
Please consult the file _KNOWN_ISSUES.md_ above, to see if your issue is already reported.
|
||||
|
|
|
|||
16
branding_files/configure.sh
Normal file
16
branding_files/configure.sh
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
MOZ_APP_NAME=librewolf
|
||||
MOZ_APP_BASENAME=LibreWolf
|
||||
MOZ_APP_PROFILE=LibreWolf
|
||||
MOZ_APP_VENDOR="LibreWolf community"
|
||||
MOZ_APP_DISPLAYNAME=LibreWolf
|
||||
MOZ_APP_REMOTINGNAME=librewolf
|
||||
MOZ_DEV_EDITION=1
|
||||
MOZ_TELEMETRY_REPORTING=
|
||||
MOZ_SERVICES_HEALTHREPORT=
|
||||
MOZ_NORMANDY=
|
||||
MOZ_REQUIRE_SIGNING=
|
||||
MOZ_DEFAULT_BROWSER_AGENT=0
|
||||
241
build.sh
Normal file
241
build.sh
Normal file
|
|
@ -0,0 +1,241 @@
|
|||
# build.sh - build librewolf on windows
|
||||
# derived from https://gitlab.com/librewolf-community/browser/linux/-/blob/master/PKGBUILD
|
||||
|
||||
pkgname=librewolf
|
||||
_pkgname=LibreWolf
|
||||
|
||||
pkgver=86.0.1
|
||||
|
||||
|
||||
|
||||
fetch() {
|
||||
echo "fetch: begin."
|
||||
|
||||
# fetch the firefox source.
|
||||
rm -f firefox-$pkgver.source.tar.xz
|
||||
wget https://archive.mozilla.org/pub/firefox/releases/$pkgver/source/firefox-$pkgver.source.tar.xz
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
if [ ! -f firefox-$pkgver.source.tar.xz ]; then exit 1; fi
|
||||
|
||||
echo "fetch: done."
|
||||
}
|
||||
|
||||
|
||||
|
||||
extract() {
|
||||
echo "extract: begin."
|
||||
|
||||
echo "Deleting previous firefox-${pkgver} ..."
|
||||
rm -rf firefox-$pkgver
|
||||
|
||||
echo "Extracting firefox-$pkgver.source.tar.xz ..."
|
||||
tar xf firefox-$pkgver.source.tar.xz
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
if [ ! -d firefox-$pkgver ]; then exit 1; fi
|
||||
|
||||
echo "extract: done."
|
||||
}
|
||||
|
||||
|
||||
|
||||
do_patches() {
|
||||
echo "do_patches: begin."
|
||||
|
||||
# get the patches
|
||||
echo 'Getting patches..'
|
||||
rm -f megabar.patch remove_addons.patch
|
||||
wget -q https://gitlab.com/librewolf-community/browser/linux/-/raw/master/megabar.patch
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
if [ ! -f megabar.patch ]; then exit 1; fi
|
||||
wget -q https://gitlab.com/librewolf-community/browser/linux/-/raw/master/remove_addons.patch
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
if [ ! -f remove_addons.patch ]; then exit 1; fi
|
||||
|
||||
if [ ! -d firefox-$pkgver ]; then exit 1; fi
|
||||
cd firefox-$pkgver
|
||||
|
||||
cat >../mozconfig <<END
|
||||
ac_add_options --enable-application=browser
|
||||
|
||||
# This supposedly speeds up compilation (We test through dogfooding anyway)
|
||||
ac_add_options --disable-tests
|
||||
ac_add_options --disable-debug
|
||||
|
||||
ac_add_options --enable-release
|
||||
ac_add_options --enable-hardening
|
||||
ac_add_options --enable-rust-simd
|
||||
ac_add_options --enable-optimize
|
||||
|
||||
|
||||
# Branding
|
||||
ac_add_options --enable-update-channel=release
|
||||
# suspect: ac_add_options --with-app-name=${pkgname}
|
||||
# suspect: ac_add_options --with-app-basename=${_pkgname}
|
||||
ac_add_options --with-branding=browser/branding/${pkgname}
|
||||
ac_add_options --with-distribution-id=io.gitlab.${pkgname}-community
|
||||
ac_add_options --with-unsigned-addon-scopes=app,system
|
||||
ac_add_options --allow-addon-sideload
|
||||
export MOZ_REQUIRE_SIGNING=0
|
||||
|
||||
# Features
|
||||
ac_add_options --disable-crashreporter
|
||||
ac_add_options --disable-updater
|
||||
|
||||
# Disables crash reporting, telemetry and other data gathering tools
|
||||
mk_add_options MOZ_CRASHREPORTER=0
|
||||
mk_add_options MOZ_DATA_REPORTING=0
|
||||
mk_add_options MOZ_SERVICES_HEALTHREPORT=0
|
||||
mk_add_options MOZ_TELEMETRY_REPORTING=0
|
||||
|
||||
# first attempt to fix the win32 vcredist issue results in build errors..
|
||||
#WIN32_REDIST_DIR=$VCINSTALLDIR\redist\x86\Microsoft.VC141.CRT
|
||||
END
|
||||
|
||||
echo 'Applying patches...'
|
||||
|
||||
# Apply patches..
|
||||
patch -p1 -i ../remove_addons.patch
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
patch -p1 -i ../megabar.patch
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
# Disabling Pocket
|
||||
sed -i "s/'pocket'/#'pocket'/g" browser/components/moz.build
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
# this one only to remove an annoying error message:
|
||||
sed -i 's#SaveToPocket.init();#// SaveToPocket.init();#g' browser/components/BrowserGlue.jsm
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
# 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'
|
||||
# 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
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
|
||||
# allow SearchEngines option in non-ESR builds
|
||||
sed -i 's#"enterprise_only": true,#"enterprise_only": false,#g' browser/components/enterprisepolicies/schemas/policies-schema.json
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
_settings_services_sed='s#firefox.settings.services.mozilla.com#f.s.s.m.c.qjz9zk#g'
|
||||
|
||||
# stop some undesired requests (https://gitlab.com/librewolf-community/browser/common/-/issues/10)
|
||||
sed "$_settings_services_sed" -i browser/components/newtab/data/content/activity-stream.bundle.js
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
sed "$_settings_services_sed" -i modules/libpref/init/all.js
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
sed "$_settings_services_sed" -i services/settings/Utils.jsm
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
sed "$_settings_services_sed" -i toolkit/components/search/SearchUtils.jsm
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
# copy branding resources
|
||||
cp -r ../common/source_files/* ./
|
||||
# new branding stuff
|
||||
cp ../branding_files/configure.sh browser/branding/librewolf
|
||||
|
||||
# just a straight copy for now..
|
||||
cp ../mozconfig .
|
||||
|
||||
cd ..
|
||||
echo "do_patches: done."
|
||||
}
|
||||
|
||||
|
||||
|
||||
build() {
|
||||
echo "build: begin."
|
||||
if [ ! -d firefox-$pkgver ]; then exit 1; fi
|
||||
cd firefox-$pkgver
|
||||
|
||||
./mach build
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
cd ..
|
||||
echo "build: done."
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
artifacts() {
|
||||
echo "artifacts: begin."
|
||||
if [ ! -d firefox-$pkgver ]; then exit 1; fi
|
||||
cd firefox-$pkgver
|
||||
|
||||
./mach package
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
# there is just too much garbage in this installer function to
|
||||
# have it all here..
|
||||
. ../installer_win.sh
|
||||
|
||||
cd ..
|
||||
echo "artifacts: done."
|
||||
}
|
||||
|
||||
|
||||
|
||||
# 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
|
||||
export TPATH=$HOME/.mozbuild/clang/bin:$HOME/.mozbuild/cbindgen:$HOME/.mozbuild/node:$HOME/.mozbuild/nasm
|
||||
export PATH=$TPATH:$PATH
|
||||
fi
|
||||
|
||||
|
||||
|
||||
# process commandline arguments and do something
|
||||
|
||||
done_something=0
|
||||
|
||||
if [[ "$*" == *fetch* ]]; then
|
||||
fetch
|
||||
done_something=1
|
||||
fi
|
||||
if [[ "$*" == *extract* ]]; then
|
||||
extract
|
||||
done_something=1
|
||||
fi
|
||||
if [[ "$*" == *do_patches* ]]; then
|
||||
do_patches
|
||||
done_something=1
|
||||
fi
|
||||
if [[ "$*" == *build* ]]; then
|
||||
build
|
||||
done_something=1
|
||||
fi
|
||||
if [[ "$*" == *artifacts* ]]; then
|
||||
artifacts
|
||||
done_something=1
|
||||
fi
|
||||
|
||||
# by default, give help..
|
||||
if (( done_something == 0 )); then
|
||||
cat <<EOF
|
||||
Use: ./build.sh fetch extract do_patches build package installer_win
|
||||
|
||||
fetch - fetch the tarball.
|
||||
extract - extract the tarball.
|
||||
do_patches - create a mozconfig, and patch the source.
|
||||
build - the actual build.
|
||||
artifacts - build the .zip and NSIS setup.exe installer.
|
||||
|
||||
If no parameters are given, it prints this help message.
|
||||
|
||||
EOF
|
||||
exit 1
|
||||
fi
|
||||
1
common
Submodule
1
common
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit 9120ca6c6709673b0188a081ec6383c4db75d169
|
||||
122
installer_win.nsi
Normal file
122
installer_win.nsi
Normal file
|
|
@ -0,0 +1,122 @@
|
|||
#
|
||||
# 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 "pkg_version" # the program version, like: 0.3.0
|
||||
!define ICON_NAME "librewolf.ico" # filename of icon to use for this app
|
||||
!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}"
|
||||
createShortCut "$SMPROGRAMS\${COMPANYNAME}\Uninstall.lnk" "$INSTDIR\uninstall.exe" "" ""
|
||||
|
||||
# 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}
|
||||
|
||||
|
||||
#
|
||||
# Registry information to let Windows pick us up in the list of available browsers
|
||||
#
|
||||
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf" "" "LibreWolf"
|
||||
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\Capabilities" "ApplicationDescription" "LibreWolf"
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\Capabilities" "ApplicationIcon" "$INSTDIR\librewolf.exe,0"
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\Capabilities" "ApplicationName" "LibreWolf"
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\Capabilities\FileAssociations" ".htm" "LibreWolfHTM"
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\Capabilities\FileAssociations" ".html" "LibreWolfHTM"
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\Capabilities\Startmenu" "StartMenuInternet" "LibreWolf"
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\Capabilities\URLAssociations" "http" "LibreWolfHTM"
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\Capabilities\URLAssociations" "https" "LibreWolfHTM"
|
||||
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\DefaultIcon" "" "$INSTDIR\librewolf.exe,0"
|
||||
WriteRegStr HKLM "Software\Clients\StartMenuInternet\LibreWolf\shell\open\command" "" "$INSTDIR\librewolf.exe"
|
||||
|
||||
WriteRegStr HKLM "Software\RegisteredApplications" "LibreWolf" "Software\Clients\StartMenuInternet\LibreWolf\Capabilities"
|
||||
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM" "" "LibreWolf Handler"
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM" "AppUserModelId" "LibreWolf"
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM\Application" "AppUserModelId" "LibreWolf"
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM\Application" "ApplicationIcon" "$INSTDIR\librewolf.exe,0"
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM\Application" "ApplicationName" "LibreWolf"
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM\Application" "ApplicationDescription" "Howling to Freedom"
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM\Application" "ApplicationCompany" "LibreWolf"
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM\DefaultIcon" "" "$INSTDIR\librewolf.exe,0"
|
||||
WriteRegStr HKLM "Software\Classes\LibreWolfHTM\shell\open\command" "" "$INSTDIR\librewolf.exe %1"
|
||||
|
||||
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"
|
||||
delete "$SMPROGRAMS\${COMPANYNAME}\Uninstall.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}"
|
||||
|
||||
#
|
||||
# Windows default browser integration
|
||||
#
|
||||
|
||||
DeleteRegKey HKLM "Software\Clients\StartMenuInternet\LibreWolf"
|
||||
DeleteRegKey HKLM "Software\RegisteredApplications"
|
||||
DeleteRegKey HKLM "Software\Classes\LibreWolfHTM"
|
||||
|
||||
sectionEnd
|
||||
132
installer_win.sh
Normal file
132
installer_win.sh
Normal file
|
|
@ -0,0 +1,132 @@
|
|||
# sanity checks
|
||||
if [ ! -d obj-x86_64-pc-mingw32/dist/firefox ]; then
|
||||
echo "installer_win.sh: directory obj-x86_64-pc-mingw32/dist/firefox not found."
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
rm -rf ../firefox ../librewolf
|
||||
cp -r obj-x86_64-pc-mingw32/dist/firefox ..
|
||||
|
||||
|
||||
pushd ..
|
||||
mv firefox librewolf
|
||||
|
||||
|
||||
# apply the LibreWolf settings
|
||||
cp -rv settings/* librewolf
|
||||
# rename the executable manually
|
||||
cd librewolf ; mv -v firefox.exe librewolf.exe ; cd ..
|
||||
|
||||
# recreate the zip file..
|
||||
|
||||
# clean garbage files
|
||||
cd librewolf ; rm -rf maintenanceservice* pingsender.exe firefox.*.xml precomplete removed-files ; cd ..
|
||||
|
||||
|
||||
# be sure to remove the previous zip file..
|
||||
rm -f librewolf-$pkgver.en-US.win64.zip*
|
||||
|
||||
zip -r9 librewolf-$pkgver.en-US.win64.zip librewolf
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
sha256sum.exe librewolf-$pkgver.en-US.win64.zip > librewolf-$pkgver.en-US.win64.zip.sha256sum
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
|
||||
|
||||
function generate_installer() {
|
||||
# generate the .nsi intaller file.
|
||||
cat >installer_win.nsi <<END
|
||||
#
|
||||
# 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 "${pkgver}" # the program version, like: 0.3.0
|
||||
!define ICON_NAME "librewolf.ico" # filename of icon to use for this app
|
||||
!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
|
||||
END
|
||||
}
|
||||
|
||||
# now to try to make the installer.
|
||||
cp -v common/source_files/browser/branding/librewolf/firefox.ico librewolf/librewolf.ico
|
||||
|
||||
sed "s/pkg_version/$pkgver/g" < installer_win.nsi > tmp.nsi
|
||||
makensis-3.01.exe tmp.nsi
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
sha256sum.exe librewolf-$pkgver.en-US.win64-setup.exe > librewolf-$pkgver.en-US.win64-setup.exe.sha256sum
|
||||
if [ $? -ne 0 ]; then exit 1; fi
|
||||
|
||||
popd
|
||||
1
settings
Submodule
1
settings
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit c5c75a39dd91a8772255a78493853be6553262b2
|
||||
Loading…
Add table
Reference in a new issue