diff --git a/.gitignore b/.gitignore index 7ffef8f..bdb4153 100644 --- a/.gitignore +++ b/.gitignore @@ -8,4 +8,4 @@ mozilla-vpn-ad.patch mozconfig librewolf tmp.nsi -tmp-experimental.nsi \ No newline at end of file +tmp-permissive.nsi \ No newline at end of file diff --git a/artifacts_deb.sh b/artifacts_deb.sh index b7bbac5..b4443fd 100644 --- a/artifacts_deb.sh +++ b/artifacts_deb.sh @@ -32,19 +32,19 @@ if [ $? -ne 0 ]; then exit 1; fi # now to try to make the installer # (create a .deb here) -# patch to experimental config -if [ ! -z $experimental ]; then +# patch to permissive config +if [ ! -z $permissive ]; then pushd librewolf - echo "Applying experimental patches..." - patch -p1 -i ../patches/experimental/librewolf-config.patch + echo "Applying permissive patches..." + patch -p1 -i ../patches/permissive/librewolf-config.patch if [ $? -ne 0 ]; then exit 1; fi - patch -p1 -i ../patches/experimental/librewolf-policies.patch + patch -p1 -i ../patches/permissive/librewolf-policies.patch if [ $? -ne 0 ]; then exit 1; fi popd # create the final zip artifact - rm -f librewolf-$pkgver.en-US.$ospkg-experimental.zip - zip -qr9 librewolf-$pkgver.en-US.$ospkg-experimental.zip librewolf + rm -f librewolf-$pkgver.en-US.$ospkg-permissive.zip + zip -qr9 librewolf-$pkgver.en-US.$ospkg-permissive.zip librewolf if [ $? -ne 0 ]; then exit 1; fi # now to try to make the installer diff --git a/artifacts_rpm.sh b/artifacts_rpm.sh index 54548dd..3f72d97 100644 --- a/artifacts_rpm.sh +++ b/artifacts_rpm.sh @@ -33,19 +33,19 @@ if [ $? -ne 0 ]; then exit 1; fi # now to try to make the installer # (create a .deb here) -# patch to experimental config -if [ ! -z $experimental ]; then +# patch to permissive config +if [ ! -z $permissive ]; then pushd librewolf - echo "Applying experimental patches..." - patch -p1 -i ../patches/experimental/librewolf-config.patch + echo "Applying permissive patches..." + patch -p1 -i ../patches/permissive/librewolf-config.patch if [ $? -ne 0 ]; then exit 1; fi - patch -p1 -i ../patches/experimental/librewolf-policies.patch + patch -p1 -i ../patches/permissive/librewolf-policies.patch if [ $? -ne 0 ]; then exit 1; fi popd # create the final zip artifact - rm -f librewolf-$pkgver.en-US.$ospkg-experimental.zip - zip -qr9 librewolf-$pkgver.en-US.$ospkg-experimental.zip librewolf + rm -f librewolf-$pkgver.en-US.$ospkg-permissive.zip + zip -qr9 librewolf-$pkgver.en-US.$ospkg-permissive.zip librewolf if [ $? -ne 0 ]; then exit 1; fi # now to try to make the installer diff --git a/artifacts_win.sh b/artifacts_win.sh index bea64db..802de48 100644 --- a/artifacts_win.sh +++ b/artifacts_win.sh @@ -35,25 +35,25 @@ sed "s/pkg_version/$pkgver/g" < artifacts_win.nsi > tmp.nsi makensis-3.01.exe -V1 tmp.nsi if [ $? -ne 0 ]; then exit 1; fi -# patch to experimental config -if [ ! -z $experimental ]; then +# patch to permissive config +if [ ! -z $permissive ]; then pushd librewolf - echo "Applying experimental patches..." - patch -p1 -i ../patches/experimental/librewolf-config.patch + echo "Applying permissive patches..." + patch -p1 -i ../patches/permissive/librewolf-config.patch if [ $? -ne 0 ]; then exit 1; fi - patch -p1 -i ../patches/experimental/librewolf-policies.patch + patch -p1 -i ../patches/permissive/librewolf-policies.patch if [ $? -ne 0 ]; then exit 1; fi popd # create the final zip artifact - rm -f librewolf-$pkgver.en-US.$ospkg-experimental.zip - zip -qr9 librewolf-$pkgver.en-US.$ospkg-experimental.zip librewolf + rm -f librewolf-$pkgver.en-US.$ospkg-permissive.zip + zip -qr9 librewolf-$pkgver.en-US.$ospkg-permissive.zip librewolf if [ $? -ne 0 ]; then exit 1; fi # now to try to make the installer - rm -f librewolf-$pkgver.en-US.win64-experimental-setup.exe tmp-experimental.nsi - sed "s/win64-setup/win64-experimental-setup/g" < tmp.nsi > tmp-experimental.nsi - makensis-3.01.exe -V1 tmp-experimental.nsi + rm -f librewolf-$pkgver.en-US.win64-permissive-setup.exe tmp-permissive.nsi + sed "s/win64-setup/win64-permissive-setup/g" < tmp.nsi > tmp-permissive.nsi + makensis-3.01.exe -V1 tmp-permissive.nsi if [ $? -ne 0 ]; then exit 1; fi fi diff --git a/build.sh b/build.sh index 15cc24b..68bfd74 100755 --- a/build.sh +++ b/build.sh @@ -54,13 +54,13 @@ clean() { # windows rm -f librewolf-$pkgver.en-US.win64.zip rm -f librewolf-$pkgver.en-US.win64-setup.exe - rm -f librewolf-$pkgver.en-US.win64-experimental.zip - rm -f librewolf-$pkgver.en-US.win64-experimental-setup.exe - rm -f tmp.nsi tmp-experimental.nsi + rm -f librewolf-$pkgver.en-US.win64-permissive.zip + rm -f librewolf-$pkgver.en-US.win64-permissive-setup.exe + rm -f tmp.nsi tmp-permissive.nsi # linux rm -f librewolf-$pkgver.en-US.deb.zip - rm -f librewolf-$pkgver.en-US.deb-experimental.zip + rm -f librewolf-$pkgver.en-US.deb-permissive.zip rm -f librewolf-$pkgver.en-US.rpm.zip echo "clean: done." @@ -318,14 +318,14 @@ git_subs() { } # -# Experimental configuration options +# Permissive configuration options # config_diff() { pushd settings > /dev/null cp "/c/Program Files/LibreWolf/librewolf.cfg" librewolf.cfg if [ $? -ne 0 ]; then exit 1; fi - git diff librewolf.cfg > ../patches/experimental/librewolf-config.patch + git diff librewolf.cfg > ../patches/permissive/librewolf-config.patch git diff librewolf.cfg git checkout librewolf.cfg > /dev/null 2>&1 popd > /dev/null @@ -335,7 +335,7 @@ policies_diff() { pushd settings/distribution > /dev/null cp "/c/Program Files/LibreWolf/distribution/policies.json" policies.json if [ $? -ne 0 ]; then exit 1; fi - git diff policies.json > ../../patches/experimental/librewolf-policies.patch + git diff policies.json > ../../patches/permissive/librewolf-policies.patch git diff policies.json git checkout policies.json > /dev/null 2>&1 popd > /dev/null @@ -370,8 +370,8 @@ git_init() { # 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 + export TPATH="$HOME/.mozbuild/clang/bin:$HOME/.mozbuild/cbindgen:$HOME/.mozbuild/node:$HOME/.mozbuild/nasm" + export PATH="$TPATH:$PATH" fi if [ -f "$HOME/.cargo/env" ]; then @@ -401,7 +401,7 @@ if [[ "$*" == *all* ]]; then extract do_patches build - experimental=experimental + permissive=permissive artifacts_win done_something=1 fi @@ -458,8 +458,8 @@ fi # creating the artifacts... -if [[ "$*" == *artifacts_exp* ]]; then - experimental=experimental +if [[ "$*" == *artifacts_perm* ]]; then + permissive=permissive artifacts_win done_something=1 else @@ -468,8 +468,8 @@ else done_something=1 fi fi -if [[ "$*" == *artifacts_deb_exp* ]]; then - experimental=experimental +if [[ "$*" == *artifacts_deb_perm* ]]; then + permissive=permissive artifacts_deb done_something=1 else @@ -478,8 +478,8 @@ else done_something=1 fi fi -if [[ "$*" == *artifacts_rpm_exp* ]]; then - experimental=experimental +if [[ "$*" == *artifacts_rpm_perm* ]]; then + permissive=permissive artifacts_rpm done_something=1 else @@ -511,22 +511,24 @@ if (( done_something == 0 )); then cat << EOF Use: ./build.sh fetch extract do_patches build artifacts_win - fetch - fetch the tarball. - extract - extract the tarball. - do_patches - create a mozconfig, and patch the source. - build - the actual build. - artifacts_win - apply .cfg, build the zip file and NSIS setup.exe installer. - artifacts_exp - package as above, but use the experimental config/policies. + fetch - fetch the tarball. + extract - extract the tarball. + do_patches - create a mozconfig, and patch the source. + build - the actual build. + + artifacts_win - apply .cfg, build the zip file and NSIS setup.exe installer. + artifacts_perm - package as above, but use the permissive config/policies. Linux related functions: - deps_deb - install dependencies with apt. - deps_rpm - install dependencies with dnf. - deps_pkg - install dependencies with pkg. - artifacts_deb - apply .cfg, create a dist zip file (for debian10). - artifacts_deb_exp - include experimental build. - artifacts_rpm - apply .cfg, create a dist zip file (for fedora33). - artifacts_rpm_exp - include experimental build. + deps_deb - install dependencies with apt. + deps_rpm - install dependencies with dnf. + deps_pkg - install dependencies with pkg. (freebsd) + + artifacts_deb - apply .cfg, create a dist zip file (for debian10). + artifacts_deb_perm - include permissive build. + artifacts_rpm - apply .cfg, create a dist zip file (for fedora33). + artifacts_rpm_perm - include permissive build. Generic utility functionality: @@ -534,7 +536,7 @@ Generic utility functionality: rustup - perform a rustup for this user. clean - remove generated cruft. - all - build all, produce all artifacts including -experimental. + all - build all, produce all artifacts including -permissive. git_subs - update git submodules. config_diff - diff between my .cfg and dist .cfg file. (win10) policies_diff - diff between my policies and the dist policies. (win10) diff --git a/patches/experimental/README.md b/patches/permissive/README.md similarity index 91% rename from patches/experimental/README.md rename to patches/permissive/README.md index fbf4766..0d86bfa 100644 --- a/patches/experimental/README.md +++ b/patches/permissive/README.md @@ -1,9 +1,11 @@ -# current differences between -release and -experimental +# current differences between -release and -permissive ## librewolf.cfg: * lockPref("dom.w3c_pointer_events.enabled", true); -> This fixes YouTube picture-in-picture. + * defaultPref("dom.event.contextmenu.enabled", true); -> This fixes lastpass.com context menu. + * defaultPref("extensions.update.url", ""); -> enable in-app manual check for extension updates. * Attempting new cookie behavior (use Settings > Cookies and Site Data > Manage Exceptions), these are the last three preferences in the cfg file: privacy.clearOnShutdown.cookies, privacy.clearOnShutdown.offlineApps, network.cookie.lifetimePolicy. diff --git a/patches/experimental/librewolf-config.patch b/patches/permissive/librewolf-config.patch similarity index 100% rename from patches/experimental/librewolf-config.patch rename to patches/permissive/librewolf-config.patch diff --git a/patches/experimental/librewolf-policies.patch b/patches/permissive/librewolf-policies.patch similarity index 100% rename from patches/experimental/librewolf-policies.patch rename to patches/permissive/librewolf-policies.patch