Compare commits
86 commits
Author | SHA1 | Date | |
---|---|---|---|
Dominika | 8cc38aced8 | ||
Dominika | 03dd51e472 | ||
Dominika | 2a7c8af65f | ||
Dominika Liberda | 0be3fe7abb | ||
Dominika Liberda | fbd1ebe106 | ||
Dominika Liberda | ddf182b041 | ||
Dominika Liberda | d4f2fc5f6f | ||
Dominika Liberda | 367999d9a9 | ||
Dominika Liberda | a3db9047d0 | ||
Dominika Liberda | b589bdd92a | ||
Dominika Liberda | 1bfe6ab98e | ||
Dominika Liberda | 894ee2dd85 | ||
Dominika Liberda | 12fe44f097 | ||
Dominika Liberda | ce9f7d7639 | ||
Dominika Liberda | 97a8e62e94 | ||
Dominika Liberda | 99b0e85392 | ||
Dominika Liberda | d92750f28f | ||
Dominika Liberda | 10612c8cc3 | ||
Dominika Liberda | 83a6751e80 | ||
Dominika Liberda | e7d4305a04 | ||
Dominika Liberda | 7c105c8ecb | ||
Dominika Liberda | b508fc9d0a | ||
Dominika Liberda | bb26234350 | ||
Dominika Liberda | 93b98fdacd | ||
Dominika Liberda | acb29bc4e6 | ||
Dominika Liberda | 144a9f1793 | ||
Dominika Liberda | 2323842987 | ||
Dominika Liberda | a6fa2867ae | ||
Dominika Liberda | 52b2c8e955 | ||
Dominika Liberda | 5d0e25f3ca | ||
Dominika Liberda | a4d819e2dd | ||
Dominika Liberda | 7b1fba588c | ||
Dominika Liberda | 8bcd7a17f2 | ||
Dominika Liberda | b0a21ef9df | ||
Dominika Liberda | a52f076e10 | ||
Dominika Liberda | e3e49a7da2 | ||
Dominika Liberda | 6df64d7560 | ||
Dominika Liberda | df3ba5ff49 | ||
Dominika Liberda | e057b7c338 | ||
Dominika Liberda | bd5a61ad49 | ||
Dominika Liberda | 61ef268cd7 | ||
Dominika Liberda | e14993de88 | ||
Dominika Liberda | cc4f1b7473 | ||
Dominika Liberda | ca6bad6d04 | ||
Dominika Liberda | d537748ea7 | ||
Dominika Liberda | 33a9b396e0 | ||
Dominika Liberda | 90f0e69652 | ||
Dominika Liberda | 59d553962e | ||
Dominika Liberda | aeac987294 | ||
Dominika Liberda | e90b3739b2 | ||
Dominika Liberda | a03a53c794 | ||
Dominika Liberda | f0241fda8f | ||
Dominika Liberda | 0526013cdc | ||
d56b020e95 | |||
434858650e | |||
17e1d6daf7 | |||
26d33367db | |||
ad9c9ecad4 | |||
f34e124596 | |||
bb4d2b8c3b | |||
abb2956b6d | |||
f6ff95a833 | |||
238b9d0c9f | |||
56b66d16f3 | |||
f78a1c2a36 | |||
5af20be933 | |||
5474baabed | |||
156fce08a1 | |||
25f3891908 | |||
743cb8ccf3 | |||
29bdf33a69 | |||
5308f573df | |||
d47b222401 | |||
de25ab61ed | |||
55617c3433 | |||
5d49ace775 | |||
ab559ab3f7 | |||
bb4152027b | |||
4db19b3317 | |||
b8677c649c | |||
a2061e3ef1 | |||
95feca84f5 | |||
5af02721e8 | |||
9e90fb3a9b | |||
062a454cf3 | |||
53ed43ecfe |
|
@ -9,37 +9,28 @@ variables:
|
|||
# AARCH64: $AARCH64
|
||||
# X86_64: $X86_64
|
||||
|
||||
.carch_aarch64: &carch_aarch64
|
||||
variables:
|
||||
CARCH: 'aarch64'
|
||||
|
||||
.carch_x86_64: &carch_x86_64
|
||||
variables:
|
||||
CARCH: 'x86_64'
|
||||
|
||||
.tarball_build_config: &tarball_build_config
|
||||
tarball_x86_64:
|
||||
image: ghcr.io/void-linux/void-linux:latest-thin-bb-x86_64
|
||||
stage: build
|
||||
script:
|
||||
- ./build_tarball.sh "${CI_PROJECT_DIR}/LibreWolf-${pkgver}-${pkgrel}.${CARCH}.tar.bz2"
|
||||
- echo "repository=https://void.sakamoto.pl/current/" > /usr/share/xbps.d/00-repository-main.conf
|
||||
- echo "repository=https://void.sakamoto.pl/current/nonfree" >> /usr/share/xbps.d/00-repository-main.conf
|
||||
- xbps-install -Sy bash
|
||||
- bash ./build_tarball.sh "${CI_PROJECT_DIR}/Foxgirl-${pkgver}-${pkgrel}.${CARCH}.tar.bz2"
|
||||
artifacts:
|
||||
name: "Librewolf-Tarball-${pkgver}-${pkgrel}-${CARCH}"
|
||||
name: "Foxgirl-${pkgver}-${pkgrel}-${CARCH}"
|
||||
paths:
|
||||
- "LibreWolf-${pkgver}-${pkgrel}.${CARCH}.tar.bz2"
|
||||
- "Foxgirl-${pkgver}-${pkgrel}.${CARCH}.tar.bz2"
|
||||
|
||||
tarball_x86_64:
|
||||
image: ubuntu:16.04
|
||||
tags: [x86_64b]
|
||||
<<: *carch_x86_64
|
||||
<<: *tarball_build_config
|
||||
only:
|
||||
variables:
|
||||
- $X86_64
|
||||
|
||||
tarball_aarch64:
|
||||
image: arm64v8/ubuntu:16.04
|
||||
tags: [aarch64b]
|
||||
<<: *carch_aarch64
|
||||
<<: *tarball_build_config
|
||||
only:
|
||||
variables:
|
||||
- $AARCH64
|
||||
tarball_x86_64_musl:
|
||||
image: ghcr.io/void-linux/void-linux:latest-thin-bb-x86_64-musl
|
||||
stage: build
|
||||
script:
|
||||
- echo "repository=https://void.sakamoto.pl/current/musl" > /usr/share/xbps.d/00-repository-main.conf
|
||||
- echo "repository=https://void.sakamoto.pl/current/musl/nonfree" >> /usr/share/xbps.d/00-repository-main.conf
|
||||
- xbps-install -Sy bash
|
||||
- bash ./build_tarball.sh "${CI_PROJECT_DIR}/Foxgirl-${pkgver}-${pkgrel}.${CARCH}.tar.bz2"
|
||||
artifacts:
|
||||
name: "Foxgirl-${pkgver}-${pkgrel}-${CARCH}_musl"
|
||||
paths:
|
||||
- "Foxgirl-${pkgver}-${pkgrel}.${CARCH}.tar.bz2"
|
||||
|
|
10
CHANGELOG.md
10
CHANGELOG.md
|
@ -7,6 +7,16 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
|||
This project follows the official Firefox releases, but also uses
|
||||
[Arch Linux Package Versioning](https://wiki.archlinux.org/index.php/Arch_package_guidelines#Package_versioning) to mark individual releases in between versions.
|
||||
|
||||
## [88.0-1] - TBD
|
||||
|
||||
### Changed
|
||||
|
||||
- New upstream release 88.0-1
|
||||
- Several yet-to-be documented changes from previous updates that are not yet added to the changelog (tbd)
|
||||
- Switched to building on Ubuntu Bionic (18.04) from Xenial (16.04) as the latter is now EOL/EOS
|
||||
- Releases can from now on be found in the specific subprojects (debian, windows, flatpak, appimage, arch, macos) for consistency; this project will only hold the tarball used for the flatpak and appimage releases
|
||||
|
||||
|
||||
## [85.0.2-2] – 2021-02-15
|
||||
|
||||
### Changed
|
||||
|
|
|
@ -3,19 +3,24 @@
|
|||
<id>io.gitlab.librewolf-community</id>
|
||||
<launchable type="desktop-id">io.gitlab.librewolf-community.desktop</launchable>
|
||||
<name>LibreWolf</name>
|
||||
<developer_name>LibreWolf Community</developer_name>
|
||||
<summary>LibreWolf Web Browser</summary>
|
||||
<metadata_license>CC0-1.0</metadata_license>
|
||||
<project_license>MPL-2.0</project_license>
|
||||
<screenshots>
|
||||
<screenshot type="default">
|
||||
<image type="source" width="1512" height="900">https://librewolf-community.gitlab.io/images/screenshot.png</image>
|
||||
</screenshot>
|
||||
</screenshots>
|
||||
<description>
|
||||
<p><strong>LibreWolf</strong></p>
|
||||
<p>LibreWolf</p>
|
||||
<p>This project is an independent fork of Firefox, with the primary goals of privacy security and user freedom. It is the community run successor to LibreFox.</p>
|
||||
<p>LibreWolf uses more than 500 privacy/security/performance settings, patches, LibreWolf-Addons (optional) and is designed to minimize data collection and telemetry as much as possible (updater, crashreporter and Firefox’s integrated addons that don’t respect privacy are removed).</p>
|
||||
<p><strong>LibreWolf is NOT associated with Mozilla or its products.</strong></p>
|
||||
<p>LibreWolf is NOT associated with Mozilla or its products.</p>
|
||||
<p>Features:</p>
|
||||
<ul>
|
||||
<li>Latest Version of Firefox: LibreWolf is compiled directly from the latest build of Firefox Stable. You will have the the latest features, and security updates.</li>
|
||||
<li>Completely Independent Build: LibreWolf uses a completely independent build from Firefox and has its own settings, profile folder and installation path. As a result, it can be installed alongside Firefox or any other browser.</li>
|
||||
<li>IJWY (I Just Want You To Shut Up): embedded server links and other calling home functions are removed. In other words, zero unauthorized or background connections by default.</li>
|
||||
<li>Settings protection: important settings are enforced/locked within librewolf.cfg and policies.json, those settings cannot be changed by addons/updates/LibreWolf itself or unwanted/accidental manipulation; To change those settings you can easily do it by editing librewolf.cfg and policies.json.</li>
|
||||
<li>LibreWolf-addons: set of optional LibreWolf extensions</li>
|
||||
<li>Statistics disabled: telemetry and similar functions are disabled</li>
|
||||
|
|
|
@ -4,7 +4,8 @@
|
|||
# - any command fails (-e | --errexit)
|
||||
# - any variable is unset (-u | --nounset)
|
||||
# - a part of a piped sequence fails (-o pipefail)
|
||||
set -euo pipefail
|
||||
#set -euo pipefail
|
||||
set -e
|
||||
|
||||
SCRIPT_FOLDER=$(realpath $(dirname $0));
|
||||
|
||||
|
|
|
@ -5,24 +5,18 @@ Author: Olivier Tilloy <olivier.tilloy@canonical.com>
|
|||
|
||||
--- a/build/moz.configure/toolchain.configure
|
||||
+++ b/build/moz.configure/toolchain.configure
|
||||
@@ -2418,8 +2418,8 @@
|
||||
@@ -2287,10 +2287,12 @@
|
||||
set_config("LINKER_KIND", select_linker.KIND)
|
||||
|
||||
|
||||
-@depends_if(select_linker, macos_sdk, sysroot_path, multiarch_dir)
|
||||
-def linker_ldflags(linker, macos_sdk, sysroot_path, multiarch_dir):
|
||||
+@depends_if(select_linker, macos_sdk, sysroot_path, multiarch_dir, host)
|
||||
+def linker_ldflags(linker, macos_sdk, sysroot_path, multiarch_dir, host):
|
||||
-@depends_if(select_linker, target, target_sysroot, target_multiarch_dir, c_compiler)
|
||||
+@depends_if(select_linker, target, target_sysroot, target_multiarch_dir, c_compiler, host)
|
||||
@imports("os")
|
||||
-def linker_ldflags(linker, target, sysroot, multiarch_dir, c_compiler):
|
||||
+def linker_ldflags(linker, target, sysroot, multiarch_dir, c_compiler, host):
|
||||
flags = list((linker and linker.LINKER_FLAG) or [])
|
||||
if macos_sdk:
|
||||
if linker and linker.KIND == "ld64":
|
||||
@@ -2427,6 +2427,9 @@
|
||||
else:
|
||||
flags.append("-Wl,--sysroot=%s" % macos_sdk)
|
||||
|
||||
+ if host.cpu == "arm":
|
||||
+ flags.append("-Wl,--no-keep-memory")
|
||||
+
|
||||
if sysroot_path and multiarch_dir:
|
||||
# Non-Debian-patched binutils linkers (both BFD and gold) don't lookup
|
||||
# in multi-arch directories.
|
||||
# rpath-link is irrelevant to wasm, see for more info https://github.com/emscripten-core/emscripten/issues/11076.
|
||||
if sysroot.path and multiarch_dir and target.os != "WASI":
|
||||
for d in ("lib", "usr/lib"):
|
||||
|
|
|
@ -1,54 +0,0 @@
|
|||
Description: point clang to the toolchain provided by the gcc-mozilla package (version 7 required for C++ 17), and statically link against libstdc++
|
||||
Author: Olivier Tilloy <olivier.tilloy@canonical.com>
|
||||
Bug-Ubuntu: https://launchpad.net/bugs/1856861
|
||||
|
||||
--- a/build/moz.configure/toolchain.configure
|
||||
+++ b/build/moz.configure/toolchain.configure
|
||||
@@ -1252,6 +1252,7 @@ try_compile(includes=['cstddef'],
|
||||
"#endif",
|
||||
]
|
||||
),
|
||||
+ flags=["--gcc-toolchain=/usr/lib/gcc-mozilla"],
|
||||
check_msg="for new enough STL headers from libstdc++",
|
||||
when=needs_libstdcxx_newness_check,
|
||||
onerror=die_on_old_libstdcxx,
|
||||
@@ -1433,6 +1434,10 @@ set_config('_DEPEND_CFLAGS', depend_cfla
|
||||
set_config("_HOST_DEPEND_CFLAGS", depend_cflags(host_c_compiler))
|
||||
|
||||
|
||||
+add_old_configure_assignment("CFLAGS", ["--gcc-toolchain=/usr/lib/gcc-mozilla"])
|
||||
+add_old_configure_assignment("CXXFLAGS", ["--gcc-toolchain=/usr/lib/gcc-mozilla"])
|
||||
+
|
||||
+
|
||||
@depends(c_compiler)
|
||||
def preprocess_option(compiler):
|
||||
# The uses of PREPROCESS_OPTION depend on the spacing for -o/-Fi.
|
||||
@@ -2137,6 +2142,7 @@ def linker_ldflags(linker, macos_sdk, ho
|
||||
if host.cpu == "arm":
|
||||
flags.append("-Wl,--no-keep-memory")
|
||||
|
||||
+ flags.append("-static-libstdc++")
|
||||
if sysroot_path and multiarch_dir:
|
||||
# Non-Debian-patched binutils linkers (both BFD and gold) don't lookup
|
||||
# in multi-arch directories.
|
||||
--- a/servo/components/style/build_gecko.rs
|
||||
+++ b/servo/components/style/build_gecko.rs
|
||||
@@ -149,6 +149,8 @@ impl BuilderExt for Builder {
|
||||
builder = builder.with_rustfmt(path);
|
||||
}
|
||||
|
||||
+ builder = builder.clang_arg("--gcc-toolchain=/usr/lib/gcc-mozilla");
|
||||
+
|
||||
for dir in SEARCH_PATHS.iter() {
|
||||
builder = builder.clang_arg("-I").clang_arg(dir.to_str().unwrap());
|
||||
}
|
||||
--- a/layout/style/test/moz.build
|
||||
+++ b/layout/style/test/moz.build
|
||||
@@ -18,6 +18,7 @@ DIRS += ['gtest']
|
||||
"host_ListCSSProperties",
|
||||
]
|
||||
)
|
||||
+HOST_CXXFLAGS += ["--gcc-toolchain=/usr/lib/gcc-mozilla"]
|
||||
|
||||
MOCHITEST_MANIFESTS += [
|
||||
"mochitest.ini",
|
|
@ -1,7 +1,7 @@
|
|||
--- a/third_party/libwebrtc/webrtc/system_wrappers/cpu_features_linux_gn/moz.build
|
||||
+++ b/third_party/libwebrtc/webrtc/system_wrappers/cpu_features_linux_gn/moz.build
|
||||
@@ -31,10 +31,6 @@ LOCAL_INCLUDES += [
|
||||
"/third_party/libwebrtc/webrtc/"
|
||||
"/tools/profiler/public"
|
||||
]
|
||||
|
||||
-UNIFIED_SOURCES += [
|
||||
|
|
|
@ -1,71 +0,0 @@
|
|||
# Revert 6700a8dfaeb1e303955acc05dabd245b9ae3c97e
|
||||
|
||||
Bug 1622963 - Require python 3.6 for the build system. r=firefox-build-system-reviewers,rstewart
|
||||
|
||||
Differential Revision: https://phabricator.services.mozilla.com/D77754
|
||||
|
||||
diff -r 81f3a9d8e5f4 build/moz.configure/init.configure
|
||||
--- a/build/moz.configure/init.configure Tue Nov 17 21:27:44 2020 +0000
|
||||
+++ b/build/moz.configure/init.configure Wed Nov 18 08:22:17 2020 +0100
|
||||
@@ -216,7 +216,7 @@
|
||||
# Python 3
|
||||
# ========
|
||||
|
||||
-option(env="PYTHON3", nargs=1, help="Python 3 interpreter (3.6 or later)")
|
||||
+option(env="PYTHON3", nargs=1, help="Python 3 interpreter (3.5 or later)")
|
||||
|
||||
option(
|
||||
env="VIRTUALENV_NAME",
|
||||
@@ -327,7 +327,7 @@
|
||||
)
|
||||
else:
|
||||
# Fall back to the search routine.
|
||||
- python, version = find_python3_executable(min_version="3.6.0")
|
||||
+ python, version = find_python3_executable(min_version="3.5.0")
|
||||
|
||||
# The API returns a bytes whereas everything in configure is unicode.
|
||||
if python:
|
||||
@@ -335,15 +335,15 @@
|
||||
|
||||
if not python:
|
||||
raise FatalCheckError(
|
||||
- "Python 3.6 or newer is required to build. "
|
||||
+ "Python 3.5 or newer is required to build. "
|
||||
"Ensure a `python3.x` executable is in your "
|
||||
"PATH or define PYTHON3 to point to a Python "
|
||||
- "3.6 executable."
|
||||
+ "3.5 executable."
|
||||
)
|
||||
|
||||
- if version < (3, 6, 0):
|
||||
+ if version < (3, 5, 0):
|
||||
raise FatalCheckError(
|
||||
- "Python 3.6 or newer is required to build; "
|
||||
+ "Python 3.5 or newer is required to build; "
|
||||
"%s is Python %d.%d" % (python, version[0], version[1])
|
||||
)
|
||||
|
||||
diff -r 81f3a9d8e5f4 python/mozbuild/mozbuild/pythonutil.py
|
||||
--- a/python/mozbuild/mozbuild/pythonutil.py Tue Nov 17 21:27:44 2020 +0000
|
||||
+++ b/python/mozbuild/mozbuild/pythonutil.py Wed Nov 18 08:22:17 2020 +0100
|
||||
@@ -44,7 +44,7 @@
|
||||
def _find_python_executable(major):
|
||||
if major not in (2, 3):
|
||||
raise ValueError("Expected a Python major version of 2 or 3")
|
||||
- min_versions = {2: "2.7.0", 3: "3.6.0"}
|
||||
+ min_versions = {2: "2.7.0", 3: "3.5.0"}
|
||||
|
||||
def ret(min_version=min_versions[major]):
|
||||
from mozfile import which
|
||||
diff -r 81f3a9d8e5f4 python/mozbuild/mozbuild/virtualenv.py
|
||||
--- a/python/mozbuild/mozbuild/virtualenv.py Tue Nov 17 21:27:44 2020 +0000
|
||||
+++ b/python/mozbuild/mozbuild/virtualenv.py Wed Nov 18 08:22:17 2020 +0100
|
||||
@@ -691,7 +691,7 @@
|
||||
major, minor, micro = sys.version_info[:3]
|
||||
minimum_python_versions = {
|
||||
2: LooseVersion("2.7.3"),
|
||||
- 3: LooseVersion("3.6.0"),
|
||||
+ 3: LooseVersion("3.5.0"),
|
||||
}
|
||||
our = LooseVersion("%d.%d.%d" % (major, minor, micro))
|
||||
|
|
@ -1,432 +0,0 @@
|
|||
Description: remove f-strings that require Python 3.6 (https://docs.python.org/3/whatsnew/3.6.html#whatsnew36-pep498)
|
||||
Author: Olivier Tilloy <olivier.tilloy@canonical.com>
|
||||
|
||||
--- a/third_party/python/glean_parser/glean_parser/lint.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/lint.py
|
||||
@@ -42,10 +42,10 @@ def _english_list(items: List[str]) -> s
|
||||
if len(items) == 0:
|
||||
return ""
|
||||
elif len(items) == 1:
|
||||
- return f"'{items[0]}'"
|
||||
+ return "'{}'".format(items[0])
|
||||
else:
|
||||
return "{}, or '{}'".format(
|
||||
- ", ".join([f"'{x}'" for x in items[:-1]]), items[-1]
|
||||
+ ", ".join(["'{}'".format(x) for x in items[:-1]]), items[-1]
|
||||
)
|
||||
|
||||
|
||||
@@ -88,10 +88,11 @@ def check_common_prefix(
|
||||
if i > 0:
|
||||
common_prefix = "_".join(first[:i])
|
||||
yield (
|
||||
- f"Within category '{category_name}', all metrics begin with "
|
||||
- f"prefix '{common_prefix}'."
|
||||
+ "Within category '{}', all metrics begin with "
|
||||
+ "prefix '{}'."
|
||||
"Remove the prefixes on the metric names and (possibly) "
|
||||
"rename the category."
|
||||
+ .format(category_name, common_prefix)
|
||||
)
|
||||
|
||||
|
||||
@@ -131,17 +132,19 @@ def check_unit_in_name(
|
||||
or unit_in_name == time_unit.name
|
||||
):
|
||||
yield (
|
||||
- f"Suffix '{unit_in_name}' is redundant with time_unit "
|
||||
- f"'{time_unit.name}'. Only include time_unit."
|
||||
+ "Suffix '{}' is redundant with time_unit "
|
||||
+ "'{}'. Only include time_unit."
|
||||
+ .format(unit_in_name, time_unit.name)
|
||||
)
|
||||
elif (
|
||||
unit_in_name in TIME_UNIT_ABBREV.keys()
|
||||
or unit_in_name in TIME_UNIT_ABBREV.values()
|
||||
):
|
||||
yield (
|
||||
- f"Suffix '{unit_in_name}' doesn't match time_unit "
|
||||
- f"'{time_unit.name}'. "
|
||||
+ "Suffix '{}' doesn't match time_unit "
|
||||
+ "'{}'. "
|
||||
"Confirm the unit is correct and only include time_unit."
|
||||
+ .format(unit_in_name, time_unit.name)
|
||||
)
|
||||
|
||||
elif memory_unit is not None:
|
||||
@@ -150,26 +153,29 @@ def check_unit_in_name(
|
||||
or unit_in_name == memory_unit.name
|
||||
):
|
||||
yield (
|
||||
- f"Suffix '{unit_in_name}' is redundant with memory_unit "
|
||||
- f"'{memory_unit.name}'. "
|
||||
+ "Suffix '{}' is redundant with memory_unit "
|
||||
+ "'{}'. "
|
||||
"Only include memory_unit."
|
||||
+ .format(unit_in_name, memory_unit.name)
|
||||
)
|
||||
elif (
|
||||
unit_in_name in MEMORY_UNIT_ABBREV.keys()
|
||||
or unit_in_name in MEMORY_UNIT_ABBREV.values()
|
||||
):
|
||||
yield (
|
||||
- f"Suffix '{unit_in_name}' doesn't match memory_unit "
|
||||
- f"{memory_unit.name}'. "
|
||||
+ "Suffix '{}' doesn't match memory_unit "
|
||||
+ "{}'. "
|
||||
"Confirm the unit is correct and only include memory_unit."
|
||||
+ .format(unit_in_name, memory_unit.name)
|
||||
)
|
||||
|
||||
elif unit is not None:
|
||||
if unit_in_name == unit:
|
||||
yield (
|
||||
- f"Suffix '{unit_in_name}' is redundant with unit param "
|
||||
- f"'{unit}'. "
|
||||
+ "Suffix '{}' is redundant with unit param "
|
||||
+ "'{}'. "
|
||||
"Only include unit."
|
||||
+ .format(unit_in_name, unit)
|
||||
)
|
||||
|
||||
|
||||
@@ -183,8 +189,9 @@ def check_category_generic(
|
||||
|
||||
if category_name in GENERIC_CATEGORIES:
|
||||
yield (
|
||||
- f"Category '{category_name}' is too generic. "
|
||||
- f"Don't use {_english_list(GENERIC_CATEGORIES)} for category names"
|
||||
+ "Category '{}' is too generic. "
|
||||
+ "Don't use {} for category names"
|
||||
+ .format(category_name, _english_list(GENERIC_CATEGORIES))
|
||||
)
|
||||
|
||||
|
||||
@@ -195,9 +202,10 @@ def check_bug_number(
|
||||
|
||||
if len(number_bugs):
|
||||
yield (
|
||||
- f"For bugs {', '.join(number_bugs)}: "
|
||||
+ "For bugs {}: "
|
||||
"Bug numbers are deprecated and should be changed to full URLs. "
|
||||
"For example, use 'http://bugzilla.mozilla.org/12345' instead of '12345'."
|
||||
+ .format(', '.join(number_bugs))
|
||||
)
|
||||
|
||||
|
||||
@@ -220,7 +228,7 @@ def check_misspelled_pings(
|
||||
for builtin in pings.RESERVED_PING_NAMES:
|
||||
distance = _hamming_distance(ping, builtin)
|
||||
if distance == 1:
|
||||
- yield f"Ping '{ping}' seems misspelled. Did you mean '{builtin}'?"
|
||||
+ yield "Ping '{}' seems misspelled. Did you mean '{}'?".format(ping, builtin)
|
||||
|
||||
|
||||
def check_user_lifetime_expiration(
|
||||
@@ -281,8 +289,9 @@ class GlinterNit:
|
||||
|
||||
def format(self):
|
||||
return (
|
||||
- f"{self.check_type.name.upper()}: {self.check_name}: "
|
||||
- f"{self.name}: {self.msg}"
|
||||
+ "{}: {}: "
|
||||
+ "{}: {}"
|
||||
+ .format(self.check_type.name.upper(), self.check_name, self.name, self.msg)
|
||||
)
|
||||
|
||||
|
||||
@@ -374,7 +383,7 @@ def lint_yaml_files(input_filepaths: Ite
|
||||
if len(nits):
|
||||
print("Sorry, Glean found some glinter nits:", file=file)
|
||||
for (path, p) in nits:
|
||||
- print(f"{path} ({p.line}:{p.column}) - {p.message}")
|
||||
+ print("{} ({}:{}) - {}".format(path, p.line, p.column, p.message))
|
||||
print("", file=file)
|
||||
print("Please fix the above nits to continue.", file=file)
|
||||
|
||||
--- a/third_party/python/glean_parser/glean_parser/markdown.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/markdown.py
|
||||
@@ -73,7 +73,7 @@ def metrics_docs(obj_name: str) -> str:
|
||||
if obj_name.startswith("labeled_"):
|
||||
fixedup_name += "s"
|
||||
|
||||
- return f"https://mozilla.github.io/glean/book/user/metrics/{fixedup_name}.html"
|
||||
+ return "https://mozilla.github.io/glean/book/user/metrics/{}.html".format(fixedup_name)
|
||||
|
||||
|
||||
def ping_docs(ping_name: str) -> str:
|
||||
@@ -84,7 +84,7 @@ def ping_docs(ping_name: str) -> str:
|
||||
if ping_name not in pings.RESERVED_PING_NAMES:
|
||||
return ""
|
||||
|
||||
- return f"https://mozilla.github.io/glean/book/user/pings/{ping_name}.html"
|
||||
+ return "https://mozilla.github.io/glean/book/user/pings/{}.html".format(ping_name)
|
||||
|
||||
|
||||
def if_empty(
|
||||
--- a/third_party/python/glean_parser/glean_parser/parser.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/parser.py
|
||||
@@ -46,7 +46,8 @@ def _update_validator(validator):
|
||||
if len(missing_properties):
|
||||
missing_properties = sorted(list(missing_properties))
|
||||
yield ValidationError(
|
||||
- f"Missing required properties: {', '.join(missing_properties)}"
|
||||
+ "Missing required properties: {}"
|
||||
+ .format(', '.join(missing_properties))
|
||||
)
|
||||
|
||||
validator.VALIDATORS["required"] = required
|
||||
@@ -65,7 +66,7 @@ def _load_file(
|
||||
return {}, None
|
||||
|
||||
if content is None:
|
||||
- yield util.format_error(filepath, "", f"'{filepath}' file can not be empty.")
|
||||
+ yield util.format_error(filepath, "", "'{}' file can not be empty.".format(filepath))
|
||||
return {}, None
|
||||
|
||||
if not isinstance(content, dict):
|
||||
@@ -76,7 +77,7 @@ def _load_file(
|
||||
|
||||
schema_key = content.get("$schema")
|
||||
if not isinstance(schema_key, str):
|
||||
- raise TypeError(f"Invalid schema key {schema_key}")
|
||||
+ raise TypeError("Invalid schema key {}".format(schema_key))
|
||||
|
||||
filetype = FILE_TYPES.get(schema_key)
|
||||
|
||||
@@ -117,7 +118,7 @@ def _get_schema(
|
||||
util.format_error(
|
||||
filepath,
|
||||
"",
|
||||
- f"$schema key must be one of {', '.join(schemas.keys())}",
|
||||
+ "$schema key must be one of {}".format(', '.join(schemas.keys())),
|
||||
)
|
||||
)
|
||||
return schemas[schema_id]
|
||||
@@ -189,7 +190,7 @@ def _instantiate_metrics(
|
||||
if not config.get("allow_reserved") and category_key.split(".")[0] == "glean":
|
||||
yield util.format_error(
|
||||
filepath,
|
||||
- f"For category '{category_key}'",
|
||||
+ "For category '{}'".format(category_key),
|
||||
"Categories beginning with 'glean' are reserved for "
|
||||
"Glean internal use.",
|
||||
)
|
||||
@@ -197,7 +198,7 @@ def _instantiate_metrics(
|
||||
all_objects.setdefault(category_key, OrderedDict())
|
||||
|
||||
if not isinstance(category_val, dict):
|
||||
- raise TypeError(f"Invalid content for {category_key}")
|
||||
+ raise TypeError("Invalid content for {}".format(category_key))
|
||||
|
||||
for metric_key, metric_val in category_val.items():
|
||||
try:
|
||||
@@ -207,7 +208,7 @@ def _instantiate_metrics(
|
||||
except Exception as e:
|
||||
yield util.format_error(
|
||||
filepath,
|
||||
- f"On instance {category_key}.{metric_key}",
|
||||
+ "On instance {}.{}".format(category_key, metric_key),
|
||||
str(e),
|
||||
)
|
||||
metric_obj = None
|
||||
@@ -218,7 +219,7 @@ def _instantiate_metrics(
|
||||
):
|
||||
yield util.format_error(
|
||||
filepath,
|
||||
- f"On instance {category_key}.{metric_key}",
|
||||
+ "On instance {}.{}".format(category_key, metric_key),
|
||||
'Only internal metrics may specify "all-pings" '
|
||||
'in "send_in_pings"',
|
||||
)
|
||||
@@ -234,8 +235,9 @@ def _instantiate_metrics(
|
||||
filepath,
|
||||
"",
|
||||
(
|
||||
- f"Duplicate metric name '{category_key}.{metric_key}' "
|
||||
- f"already defined in '{already_seen}'"
|
||||
+ "Duplicate metric name '{}.{}' "
|
||||
+ "already defined in '{}'"
|
||||
+ .format(category_key, metric_key, already_seen)
|
||||
),
|
||||
)
|
||||
else:
|
||||
@@ -261,17 +263,17 @@ def _instantiate_pings(
|
||||
if ping_key in RESERVED_PING_NAMES:
|
||||
yield util.format_error(
|
||||
filepath,
|
||||
- f"For ping '{ping_key}'",
|
||||
- f"Ping uses a reserved name ({RESERVED_PING_NAMES})",
|
||||
+ "For ping '{}'".format(ping_key),
|
||||
+ "Ping uses a reserved name ({})".format(RESERVED_PING_NAMES),
|
||||
)
|
||||
continue
|
||||
if not isinstance(ping_val, dict):
|
||||
- raise TypeError(f"Invalid content for ping {ping_key}")
|
||||
+ raise TypeError("Invalid content for ping {}".format(ping_key))
|
||||
ping_val["name"] = ping_key
|
||||
try:
|
||||
ping_obj = Ping(**ping_val)
|
||||
except Exception as e:
|
||||
- yield util.format_error(filepath, f"On instance '{ping_key}'", str(e))
|
||||
+ yield util.format_error(filepath, "On instance '{}'".format(ping_key), str(e))
|
||||
continue
|
||||
|
||||
already_seen = sources.get(ping_key)
|
||||
@@ -280,8 +282,9 @@ def _instantiate_pings(
|
||||
yield util.format_error(
|
||||
filepath,
|
||||
"",
|
||||
- f"Duplicate ping name '{ping_key}' "
|
||||
- f"already defined in '{already_seen}'",
|
||||
+ "Duplicate ping name '{}' "
|
||||
+ "already defined in '{}'"
|
||||
+ .format(ping_key, already_seen),
|
||||
)
|
||||
else:
|
||||
all_objects.setdefault("pings", {})[ping_key] = ping_obj
|
||||
--- a/third_party/python/glean_parser/glean_parser/util.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/util.py
|
||||
@@ -132,7 +132,7 @@ def load_yaml_or_json(path: Path, ordere
|
||||
else:
|
||||
return yaml.load(fd, Loader=_NoDatesSafeLoader)
|
||||
else:
|
||||
- raise ValueError(f"Unknown file extension {path.suffix}")
|
||||
+ raise ValueError("Unknown file extension {}".format(path.suffix))
|
||||
|
||||
|
||||
def ensure_list(value: Any) -> Sequence[Any]:
|
||||
@@ -331,9 +331,9 @@ def format_error(filepath: Union[str, Pa
|
||||
else:
|
||||
filepath = "<string>"
|
||||
if header:
|
||||
- return f"{filepath}: {header}\n{_utils.indent(content)}"
|
||||
+ return "{}: {}\n{}".format(filepath, header, _utils.indent(content))
|
||||
else:
|
||||
- return f"{filepath}:\n{_utils.indent(content)}"
|
||||
+ return "{}:\n{}".format(filepath, _utils.indent(content))
|
||||
|
||||
|
||||
def parse_expires(expires: str) -> datetime.date:
|
||||
@@ -351,8 +351,8 @@ def parse_expires(expires: str) -> datet
|
||||
return datetime.date.fromisoformat(expires)
|
||||
except ValueError:
|
||||
raise ValueError(
|
||||
- f"Invalid expiration date '{expires}'. "
|
||||
- "Must be of the form yyyy-mm-dd in UTC."
|
||||
+ "Invalid expiration date '{}'. "
|
||||
+ "Must be of the form yyyy-mm-dd in UTC.".format(expires)
|
||||
)
|
||||
|
||||
|
||||
@@ -382,7 +382,7 @@ def validate_expires(expires: str) -> No
|
||||
max_date = datetime.datetime.now() + datetime.timedelta(days=730)
|
||||
if date > max_date.date():
|
||||
raise ValueError(
|
||||
- f"'{expires}' is more than 730 days (~2 years) in the future.",
|
||||
+ "'{}' is more than 730 days (~2 years) in the future.".format(expires),
|
||||
"Please make sure this is intentional.",
|
||||
"You can supress this warning by adding EXPIRATION_DATE_TOO_FAR to no_lint",
|
||||
"See: https://mozilla.github.io/glean_parser/metrics-yaml.html#no_lint",
|
||||
--- a/third_party/python/glean_parser/tools/extract_data_categories.py
|
||||
+++ b/third_party/python/glean_parser/tools/extract_data_categories.py
|
||||
@@ -62,7 +62,7 @@ def fetch_url(url: str) -> str:
|
||||
if content is not None:
|
||||
return content
|
||||
|
||||
- print(f"Fetching {url}")
|
||||
+ print("Fetching {}".format(url))
|
||||
content = urlopen(url).read()
|
||||
cache[url] = content
|
||||
time.sleep(0.5)
|
||||
@@ -97,7 +97,7 @@ def categories_as_strings(categories: Se
|
||||
"""
|
||||
if len(categories):
|
||||
return [
|
||||
- CATEGORY_MAP.get(x, f"!!!UNKNOWN CATEGORY {x}")
|
||||
+ CATEGORY_MAP.get(x, "!!!UNKNOWN CATEGORY {}".format(x))
|
||||
for x in sorted(list(categories))
|
||||
]
|
||||
else:
|
||||
@@ -119,24 +119,24 @@ def update_lines(
|
||||
|
||||
for line in lines_iter:
|
||||
output.append(line)
|
||||
- if line.startswith(f"{category_name}:"):
|
||||
+ if line.startswith("{}:".format(category_name)):
|
||||
break
|
||||
|
||||
for line in lines_iter:
|
||||
output.append(line)
|
||||
- if line.startswith(f" {metric_name}:"):
|
||||
+ if line.startswith(" {}:".format(metric_name)):
|
||||
break
|
||||
|
||||
for line in lines_iter:
|
||||
output.append(line)
|
||||
- if line.startswith(f" data_reviews:"):
|
||||
+ if line.startswith(" data_reviews:"):
|
||||
break
|
||||
|
||||
for line in lines_iter:
|
||||
if not line.strip().startswith("- "):
|
||||
output.append(" data_sensitivity:\n")
|
||||
for data_sensitivity in data_sensitivity_values:
|
||||
- output.append(f" - {data_sensitivity}\n")
|
||||
+ output.append(" - {}\n".format(data_sensitivity))
|
||||
output.append(line)
|
||||
break
|
||||
else:
|
||||
--- a/third_party/python/glean_parser/glean_parser/metrics.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/metrics.py
|
||||
@@ -138,7 +138,7 @@ class Metric:
|
||||
|
||||
metric_type = metric_info["type"]
|
||||
if not isinstance(metric_type, str):
|
||||
- raise TypeError(f"Unknown metric type {metric_type}")
|
||||
+ raise TypeError("Unknown metric type {}".format(metric_type))
|
||||
return cls.metric_types[metric_type](
|
||||
category=category,
|
||||
name=name,
|
||||
--- a/third_party/python/glean_parser/glean_parser/translate.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/translate.py
|
||||
@@ -112,7 +112,7 @@ def translate_metrics(
|
||||
for filepath in output_dir.glob(clear_pattern):
|
||||
filepath.unlink()
|
||||
if len(list(output_dir.iterdir())):
|
||||
- print(f"Extra contents found in '{output_dir}'.")
|
||||
+ print("Extra contents found in '{}'.".format(output_dir))
|
||||
|
||||
# We can't use shutil.copytree alone if the directory already exists.
|
||||
# However, if it doesn't exist, make sure to create one otherwise
|
||||
@@ -146,7 +146,7 @@ def translate(
|
||||
format_desc = OUTPUTTERS.get(output_format, None)
|
||||
|
||||
if format_desc is None:
|
||||
- raise ValueError(f"Unknown output format '{output_format}'")
|
||||
+ raise ValueError("Unknown output format '{}'".format(output_format))
|
||||
|
||||
return translate_metrics(
|
||||
input_filepaths,
|
||||
--- a/toolkit/components/glean/build_scripts/glean_parser_ext/js.py Tue Nov 17 21:27:44 2020 +0000
|
||||
+++ b/toolkit/components/glean/build_scripts/glean_parser_ext/js.py Wed Nov 18 10:51:04 2020 +0100
|
||||
@@ -57,7 +57,7 @@
|
||||
"""
|
||||
The metric's unique identifier, including the category and name
|
||||
"""
|
||||
- return f"{category}.{util.camelize(metric_name)}"
|
||||
+ return "{}.{}".format(category, util.camelize(metric_name))
|
||||
|
||||
|
||||
def type_name(obj):
|
||||
--- a/toolkit/components/glean/build_scripts/glean_parser_ext/rust.py Tue Nov 17 21:27:44 2020 +0000
|
||||
+++ b/toolkit/components/glean/build_scripts/glean_parser_ext/rust.py Wed Nov 18 10:51:04 2020 +0100
|
||||
@@ -175,7 +175,7 @@
|
||||
|
||||
metric_name = util.snake_case(metric.name)
|
||||
category_name = util.snake_case(category_name)
|
||||
- full_path = f"{category_name}::{metric_name}"
|
||||
+ full_path = "{}::{}".format(category_name, metric_name)
|
||||
|
||||
if metric.type == "event":
|
||||
events_by_id[get_metric_id(metric)] = full_path
|
|
@ -1,23 +0,0 @@
|
|||
Description: revert a change that requires Python 3.6 (https://docs.python.org/3/whatsnew/3.6.html#whatsnew36-pep487)
|
||||
Author: Olivier Tilloy <olivier.tilloy@canonical.com>
|
||||
|
||||
--- a/third_party/python/glean_parser/glean_parser/metrics.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/metrics.py
|
||||
@@ -15,6 +15,8 @@ from typing import Any, Dict, List, Opti
|
||||
from . import pings
|
||||
from . import util
|
||||
|
||||
+import pep487
|
||||
+
|
||||
|
||||
# Important: if the values are ever changing here, make sure
|
||||
# to also fix mozilla/glean. Otherwise language bindings may
|
||||
@@ -32,7 +34,7 @@ class DataSensitivity(enum.Enum):
|
||||
highly_sensitive = 4
|
||||
|
||||
|
||||
-class Metric:
|
||||
+class Metric(pep487.PEP487Object):
|
||||
typename = "ERROR"
|
||||
glean_internal_metric_cat = "glean.internal.metrics"
|
||||
metric_types = {}
|
|
@ -1,148 +0,0 @@
|
|||
Description: remove variable annotations that require Python 3.6 (https://docs.python.org/3/whatsnew/3.6.html#whatsnew36-pep526)
|
||||
Author: Olivier Tilloy <olivier.tilloy@canonical.com>
|
||||
|
||||
--- a/xpcom/ds/tools/incremental_dafsa.py
|
||||
+++ b/xpcom/ds/tools/incremental_dafsa.py
|
||||
@@ -14,12 +14,6 @@ from typing import List, Dict, Optional,
|
||||
|
||||
|
||||
class Node:
|
||||
- children: Dict[str, "Node"]
|
||||
- parents: Dict[str, List["Node"]]
|
||||
- character: str
|
||||
- is_root_node: bool
|
||||
- is_end_node: bool
|
||||
-
|
||||
def __init__(self, character, is_root_node=False, is_end_node=False):
|
||||
self.children = {}
|
||||
self.parents = {}
|
||||
@@ -156,9 +150,6 @@ class Node:
|
||||
|
||||
|
||||
class SuffixCursor:
|
||||
- index: int # Current position of the cursor within the DAFSA.
|
||||
- node: Node
|
||||
-
|
||||
def __init__(self, index, node):
|
||||
self.index = index
|
||||
self.node = node
|
||||
@@ -227,15 +218,6 @@ class DafsaAppendStateMachine:
|
||||
The next suffix node we'll attempt to find is at index "9".
|
||||
"""
|
||||
|
||||
- root_node: Node
|
||||
- prefix_index: int
|
||||
- suffix_cursor: SuffixCursor
|
||||
- stack: List[Node]
|
||||
- word: str
|
||||
- suffix_overlaps_prefix: bool
|
||||
- first_fork_index: Optional[int]
|
||||
- _state: Callable
|
||||
-
|
||||
def __init__(self, word, root_node, end_node):
|
||||
self.root_node = root_node
|
||||
self.prefix_index = 0
|
||||
@@ -471,9 +453,6 @@ def _duplicate_fork_nodes(stack, fork_in
|
||||
|
||||
|
||||
class Dafsa:
|
||||
- root_node: Node
|
||||
- end_node: Node
|
||||
-
|
||||
def __init__(self):
|
||||
self.root_node = Node(None, is_root_node=True)
|
||||
self.end_node = Node(None, is_end_node=True)
|
||||
--- a/third_party/python/glean_parser/glean_parser/lint.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/lint.py
|
||||
@@ -237,9 +237,7 @@ def check_user_lifetime_expiration(
|
||||
|
||||
# The checks that operate on an entire category of metrics:
|
||||
# {NAME: (function, is_error)}
|
||||
-CATEGORY_CHECKS: Dict[
|
||||
- str, Tuple[Callable[[str, Iterable[metrics.Metric]], LintGenerator], CheckType]
|
||||
-] = {
|
||||
+CATEGORY_CHECKS = {
|
||||
"COMMON_PREFIX": (check_common_prefix, CheckType.error),
|
||||
"CATEGORY_GENERIC": (check_category_generic, CheckType.error),
|
||||
}
|
||||
@@ -247,9 +245,7 @@ CATEGORY_CHECKS: Dict[
|
||||
|
||||
# The checks that operate on individual metrics:
|
||||
# {NAME: (function, is_error)}
|
||||
-INDIVIDUAL_CHECKS: Dict[
|
||||
- str, Tuple[Callable[[metrics.Metric, dict], LintGenerator], CheckType]
|
||||
-] = {
|
||||
+INDIVIDUAL_CHECKS = {
|
||||
"UNIT_IN_NAME": (check_unit_in_name, CheckType.error),
|
||||
"BUG_NUMBER": (check_bug_number, CheckType.error),
|
||||
"BASELINE_PING": (check_valid_in_baseline, CheckType.error),
|
||||
@@ -282,7 +278,7 @@ def lint_metrics(
|
||||
if parser_config is None:
|
||||
parser_config = {}
|
||||
|
||||
- nits: List[GlinterNit] = []
|
||||
+ nits = []
|
||||
for (category_name, category) in sorted(list(objs.items())):
|
||||
if category_name == "pings":
|
||||
continue
|
||||
@@ -363,7 +359,7 @@ def lint_yaml_files(input_filepaths: Ite
|
||||
|
||||
# Generic type since the actual type comes from yamllint, which we don't
|
||||
# control.
|
||||
- nits: List = []
|
||||
+ nits = []
|
||||
for path in input_filepaths:
|
||||
if not path.is_file() and parser_config.get("allow_missing_files", False):
|
||||
continue
|
||||
--- a/third_party/python/glean_parser/glean_parser/metrics.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/metrics.py
|
||||
@@ -33,10 +33,10 @@ class DataSensitivity(enum.Enum):
|
||||
|
||||
|
||||
class Metric:
|
||||
- typename: str = "ERROR"
|
||||
- glean_internal_metric_cat: str = "glean.internal.metrics"
|
||||
- metric_types: Dict[str, Any] = {}
|
||||
- default_store_names: List[str] = ["metrics"]
|
||||
+ typename = "ERROR"
|
||||
+ glean_internal_metric_cat = "glean.internal.metrics"
|
||||
+ metric_types = {}
|
||||
+ default_store_names = ["metrics"]
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
--- a/third_party/python/glean_parser/glean_parser/pings.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/pings.py
|
||||
@@ -49,7 +49,7 @@ class Ping:
|
||||
# _validated indicates whether this metric has already been jsonschema
|
||||
# validated (but not any of the Python-level validation).
|
||||
if not _validated:
|
||||
- data: Dict[str, util.JSONType] = {
|
||||
+ data = {
|
||||
"$schema": parser.PINGS_ID,
|
||||
self.name: self.serialize(),
|
||||
}
|
||||
--- a/third_party/python/glean_parser/glean_parser/util.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/util.py
|
||||
@@ -269,7 +269,7 @@ def fetch_remote_url(url: str, cache: bo
|
||||
if key in dc:
|
||||
return dc[key]
|
||||
|
||||
- contents: str = urllib.request.urlopen(url).read()
|
||||
+ contents = urllib.request.urlopen(url).read()
|
||||
|
||||
if cache:
|
||||
with diskcache.Cache(cache_dir) as dc:
|
||||
--- a/third_party/python/glean_parser/glean_parser/parser.py
|
||||
+++ b/third_party/python/glean_parser/glean_parser/parser.py
|
||||
@@ -339,8 +339,8 @@ def parse_objects(
|
||||
if config is None:
|
||||
config = {}
|
||||
|
||||
- all_objects: ObjectTree = OrderedDict()
|
||||
- sources: Dict[Any, Path] = {}
|
||||
+ all_objects = OrderedDict()
|
||||
+ sources = {}
|
||||
filepaths = util.ensure_list(filepaths)
|
||||
for filepath in filepaths:
|
||||
content, filetype = yield from _load_file(filepath, config)
|
|
@ -8,8 +8,8 @@ Description: reduce the rust debuginfo level
|
|||
with recent versions of rustc pretty much all supported architectures are
|
||||
affected, so it is now unconditional.
|
||||
|
||||
--- a/build/moz.configure/toolchain.configure
|
||||
+++ b/build/moz.configure/toolchain.configure
|
||||
--- a/build/moz.configure/rust.configure
|
||||
+++ b/build/moz.configure/rust.configure
|
||||
@@ -2167,7 +2167,7 @@ def rust_compile_flags(opt_level, debug_
|
||||
debug_assertions = False
|
||||
|
||||
|
|
|
@ -1,11 +0,0 @@
|
|||
--- a/build/moz.configure/rust.configure
|
||||
+++ b/build/moz.configure/rust.configure
|
||||
@@ -168,7 +168,7 @@
|
||||
rustc_min_version = Version("1.47.0")
|
||||
else:
|
||||
rustc_min_version = Version(MINIMUM_RUST_VERSION)
|
||||
- cargo_min_version = rustc_min_version
|
||||
+ cargo_min_version = Version("1.46.0")
|
||||
|
||||
version = rustc_info.version
|
||||
is_nightly = "nightly" in version.version
|
|
@ -1,144 +0,0 @@
|
|||
From 05971bd227dc6c359657d1501711e6865e9430f9 Mon Sep 17 00:00:00 2001
|
||||
From: Matthew Denton <mpdenton@chromium.org>
|
||||
Date: Tue, 28 Jul 2020 00:29:01 +0000
|
||||
Subject: [PATCH] Linux sandbox: update arm syscall numbers
|
||||
|
||||
Change-Id: Ia2c39a86fb3516040a74de963115e73b7b1a1e0c
|
||||
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2318316
|
||||
Reviewed-by: Robert Sesek <rsesek@chromium.org>
|
||||
Commit-Queue: Matthew Denton <mpdenton@chromium.org>
|
||||
Cr-Commit-Position: refs/heads/master@{#792090}
|
||||
---
|
||||
|
||||
diff --git a/security/sandbox/chromium/sandbox/linux/system_headers/arm64_linux_syscalls.h b/security/sandbox/chromium/sandbox/linux/system_headers/arm64_linux_syscalls.h
|
||||
index 59d0eab8..a242c18c 100644
|
||||
--- a/security/sandbox/chromium/sandbox/linux/system_headers/arm64_linux_syscalls.h
|
||||
+++ b/security/sandbox/chromium/sandbox/linux/system_headers/arm64_linux_syscalls.h
|
||||
@@ -1063,4 +1063,60 @@
|
||||
#define __NR_memfd_create 279
|
||||
#endif
|
||||
|
||||
+#if !defined(__NR_bpf)
|
||||
+#define __NR_bpf 280
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_execveat)
|
||||
+#define __NR_execveat 281
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_userfaultfd)
|
||||
+#define __NR_userfaultfd 282
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_membarrier)
|
||||
+#define __NR_membarrier 283
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_mlock2)
|
||||
+#define __NR_mlock2 284
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_copy_file_range)
|
||||
+#define __NR_copy_file_range 285
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_preadv2)
|
||||
+#define __NR_preadv2 286
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_pwritev2)
|
||||
+#define __NR_pwritev2 287
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_pkey_mprotect)
|
||||
+#define __NR_pkey_mprotect 288
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_pkey_alloc)
|
||||
+#define __NR_pkey_alloc 289
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_pkey_free)
|
||||
+#define __NR_pkey_free 290
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_statx)
|
||||
+#define __NR_statx 291
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_io_pgetevents)
|
||||
+#define __NR_io_pgetevents 292
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_rseq)
|
||||
+#define __NR_rseq 293
|
||||
+#endif
|
||||
+
|
||||
#endif // SANDBOX_LINUX_SYSTEM_HEADERS_ARM64_LINUX_SYSCALLS_H_
|
||||
diff --git a/security/sandbox/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h b/security/sandbox/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
|
||||
index 1addd53..85e2110b 100644
|
||||
--- a/security/sandbox/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
|
||||
+++ b/security/sandbox/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
|
||||
@@ -1385,6 +1385,62 @@
|
||||
#define __NR_memfd_create (__NR_SYSCALL_BASE+385)
|
||||
#endif
|
||||
|
||||
+#if !defined(__NR_bpf)
|
||||
+#define __NR_bpf (__NR_SYSCALL_BASE+386)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_execveat)
|
||||
+#define __NR_execveat (__NR_SYSCALL_BASE+387)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_userfaultfd)
|
||||
+#define __NR_userfaultfd (__NR_SYSCALL_BASE+388)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_membarrier)
|
||||
+#define __NR_membarrier (__NR_SYSCALL_BASE+389)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_mlock2)
|
||||
+#define __NR_mlock2 (__NR_SYSCALL_BASE+390)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_copy_file_range)
|
||||
+#define __NR_copy_file_range (__NR_SYSCALL_BASE+391)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_preadv2)
|
||||
+#define __NR_preadv2 (__NR_SYSCALL_BASE+392)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_pwritev2)
|
||||
+#define __NR_pwritev2 (__NR_SYSCALL_BASE+393)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_pkey_mprotect)
|
||||
+#define __NR_pkey_mprotect (__NR_SYSCALL_BASE+394)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_pkey_alloc)
|
||||
+#define __NR_pkey_alloc (__NR_SYSCALL_BASE+395)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_pkey_free)
|
||||
+#define __NR_pkey_free (__NR_SYSCALL_BASE+396)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_statx)
|
||||
+#define __NR_statx (__NR_SYSCALL_BASE+397)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_rseq)
|
||||
+#define __NR_rseq (__NR_SYSCALL_BASE+398)
|
||||
+#endif
|
||||
+
|
||||
+#if !defined(__NR_io_pgetevents)
|
||||
+#define __NR_io_pgetevents (__NR_SYSCALL_BASE+399)
|
||||
+#endif
|
||||
+
|
||||
// ARM private syscalls.
|
||||
#if !defined(__ARM_NR_BASE)
|
||||
#define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
|
|
@ -1,42 +0,0 @@
|
|||
Description: silence GTK style-related assertions caused by the lack of a "selection" CSS node on GtkTextView in the version of gtk3 in xenial.
|
||||
These assertions were caused by the fix for https://bugzilla.mozilla.org/1654323.
|
||||
Author: Olivier Tilloy <olivier.tilloy@canonical.com>
|
||||
|
||||
--- a/widget/gtk/nsLookAndFeel.cpp
|
||||
+++ b/widget/gtk/nsLookAndFeel.cpp
|
||||
@@ -1216,7 +1216,7 @@ void nsLookAndFeel::EnsureInit() {
|
||||
&color);
|
||||
mTextSelectedText = GDK_RGBA_TO_NS_RGBA(color);
|
||||
};
|
||||
- GrabSelectionColors(selectionStyle);
|
||||
+ GrabSelectionColors(selectionStyle ? selectionStyle : style);
|
||||
if (mTextSelectedBackground == mTextSelectedText) {
|
||||
// Some old distros/themes don't properly use the .selection style, so
|
||||
// fall back to the regular text view style.
|
||||
@@ -1413,6 +1413,7 @@ bool nsLookAndFeel::WidgetUsesImage(Widg
|
||||
GTK_STATE_FLAG_BACKDROP, GTK_STATE_FLAG_INSENSITIVE};
|
||||
|
||||
GtkStyleContext* style = GetStyleContext(aNodeType);
|
||||
+ if (!style) return false;
|
||||
|
||||
GValue value = G_VALUE_INIT;
|
||||
for (GtkStateFlags state : sFlagsToCheck) {
|
||||
--- a/widget/gtk/WidgetStyleCache.cpp
|
||||
+++ b/widget/gtk/WidgetStyleCache.cpp
|
||||
@@ -933,7 +933,7 @@ static GtkStyleContext* GetWidgetRootSty
|
||||
default:
|
||||
GtkWidget* widget = GetWidget(aNodeType);
|
||||
MOZ_ASSERT(widget);
|
||||
- return gtk_widget_get_style_context(widget);
|
||||
+ return (widget ? gtk_widget_get_style_context(widget) : nullptr);
|
||||
}
|
||||
|
||||
MOZ_ASSERT(style);
|
||||
@@ -1356,6 +1356,7 @@ GtkStyleContext* GetStyleContext(WidgetN
|
||||
style = GetCssNodeStyleInternal(aNodeType);
|
||||
StyleContextSetScale(style, aScale);
|
||||
}
|
||||
+ if (!style) return nullptr;
|
||||
bool stateChanged = false;
|
||||
bool stateHasDirection = gtk_get_minor_version() >= 8;
|
||||
GtkStateFlags oldState = gtk_style_context_get_state(style);
|
|
@ -1,8 +1,8 @@
|
|||
diff --git a/browser/components/urlbar/UrlbarInput.jsm b/browser/components/urlbar/UrlbarInput.jsm
|
||||
index b003b5f..e7a5332 100644
|
||||
index 73d15df..99cc41b 100644
|
||||
--- a/browser/components/urlbar/UrlbarInput.jsm
|
||||
+++ b/browser/components/urlbar/UrlbarInput.jsm
|
||||
@@ -1633,13 +1633,13 @@ class UrlbarInput {
|
||||
@@ -1692,13 +1692,13 @@ class UrlbarInput {
|
||||
|
||||
// Enable the animation only after the first extend call to ensure it
|
||||
// doesn't run when opening a new window.
|
||||
|
@ -24,19 +24,19 @@ index b003b5f..e7a5332 100644
|
|||
|
||||
endLayoutExtend() {
|
||||
diff --git a/browser/themes/shared/urlbar-searchbar.inc.css b/browser/themes/shared/urlbar-searchbar.inc.css
|
||||
index 9cc5b6f..97c2f19 100644
|
||||
index e9fde8b..6c4c444 100644
|
||||
--- a/browser/themes/shared/urlbar-searchbar.inc.css
|
||||
+++ b/browser/themes/shared/urlbar-searchbar.inc.css
|
||||
@@ -6,7 +6,7 @@
|
||||
@@ -5,7 +5,7 @@
|
||||
%endif
|
||||
|
||||
%define fieldBorderColor hsla(240,5%,5%,.25)
|
||||
%define fieldHoverBorderColor hsla(240,5%,5%,.35)
|
||||
-%define urlbarMarginInline 5px
|
||||
+%define urlbarMarginInline 0px
|
||||
%define urlbarSearchButtonWidth calc(16px + 2 * @identityBoxPaddingInline@)
|
||||
%define urlbarSearchButtonWidth calc(16px + 2 * var(--urlbar-icon-padding))
|
||||
|
||||
:root {
|
||||
@@ -197,13 +197,13 @@
|
||||
@@ -273,9 +273,9 @@
|
||||
}
|
||||
|
||||
#urlbar[breakout][breakout-extend] {
|
||||
|
@ -48,14 +48,18 @@ index 9cc5b6f..97c2f19 100644
|
|||
+ width: 100%;
|
||||
}
|
||||
|
||||
@supports -moz-bool-pref("browser.proton.urlbar.enabled") {
|
||||
@@ -288,7 +288,7 @@
|
||||
|
||||
@supports not -moz-bool-pref("browser.proton.urlbar.enabled") {
|
||||
#urlbar[breakout][breakout-extend] > #urlbar-background {
|
||||
- box-shadow: 0 3px 8px 0 rgba(0,0,0,.15)
|
||||
+ box-shadow: 0 1px 4px rgba(0,0,0,.05);
|
||||
}
|
||||
|
||||
#urlbar[breakout][breakout-extend][open] > #urlbar-background {
|
||||
@@ -211,9 +211,9 @@
|
||||
}
|
||||
@@ -297,9 +297,9 @@
|
||||
} /*** END !proton ***/
|
||||
|
||||
#urlbar[breakout][breakout-extend] > #urlbar-input-container {
|
||||
- height: calc(var(--urlbar-toolbar-height) + 2 * @urlbarBreakoutExtend@);
|
||||
|
@ -66,8 +70,8 @@ index 9cc5b6f..97c2f19 100644
|
|||
+ padding-inline: 0;
|
||||
}
|
||||
|
||||
#urlbar.searchButton[breakout][breakout-extend] > #urlbar-input-container > #urlbar-search-button {
|
||||
@@ -231,7 +231,7 @@
|
||||
@supports -moz-bool-pref("browser.proton.urlbar.enabled") {
|
||||
@@ -325,7 +325,7 @@
|
||||
}
|
||||
|
||||
#urlbar[breakout][breakout-extend] > #urlbar-background {
|
||||
|
@ -77,38 +81,38 @@ index 9cc5b6f..97c2f19 100644
|
|||
animation-timing-function: var(--animation-easing-function);
|
||||
}
|
||||
diff --git a/browser/themes/shared/urlbarView.inc.css b/browser/themes/shared/urlbarView.inc.css
|
||||
index b648467..0a12ef0 100644
|
||||
index c6ce546..da00fac 100644
|
||||
--- a/browser/themes/shared/urlbarView.inc.css
|
||||
+++ b/browser/themes/shared/urlbarView.inc.css
|
||||
@@ -56,8 +56,8 @@
|
||||
@@ -74,8 +74,8 @@
|
||||
display: block;
|
||||
text-shadow: none;
|
||||
overflow: clip;
|
||||
- margin-inline: @urlbarViewMarginInline@;
|
||||
- width: calc(100% - 2 * @urlbarViewMarginInline@);
|
||||
- margin-inline: calc(5px + var(--urlbar-container-padding));
|
||||
- width: calc(100% - 2 * (5px + var(--urlbar-container-padding)));
|
||||
+ margin-inline: 0;
|
||||
+ width: 100%;
|
||||
|
||||
/* Match urlbar-background's border. */
|
||||
border-inline: 1px solid transparent;
|
||||
@@ -90,7 +90,7 @@
|
||||
.urlbarView-row {
|
||||
}
|
||||
@@ -115,7 +115,7 @@
|
||||
flex-wrap: nowrap;
|
||||
fill: currentColor;
|
||||
fill-opacity: .6;
|
||||
- padding-block: 3px;
|
||||
+ padding-block: 0;
|
||||
}
|
||||
|
||||
.urlbarView-row-inner {
|
||||
@@ -207,6 +207,7 @@
|
||||
:root[uidensity=compact] .urlbarView-row {
|
||||
@@ -280,6 +280,7 @@
|
||||
object-fit: contain;
|
||||
flex-shrink: 0;
|
||||
-moz-context-properties: fill, fill-opacity;
|
||||
+ margin-inline-start: 20px;
|
||||
}
|
||||
|
||||
.urlbarView-row[type=tip] > .urlbarView-row-inner > .urlbarView-favicon {
|
||||
@@ -244,10 +245,10 @@
|
||||
@supports not -moz-bool-pref("browser.proton.urlbar.enabled") {
|
||||
@@ -324,10 +325,10 @@
|
||||
|
||||
.urlbarView-type-icon {
|
||||
position: absolute;
|
||||
|
@ -120,6 +124,6 @@ index b648467..0a12ef0 100644
|
|||
+ height: 16px;
|
||||
+ margin-bottom: 0;
|
||||
+ margin-inline-start: 0;
|
||||
align-self: end;
|
||||
background-repeat: no-repeat;
|
||||
background-size: contain;
|
||||
-moz-context-properties: fill, stroke;
|
|
@ -1,13 +1,18 @@
|
|||
diff --git a/browser/extensions/moz.build b/browser/extensions/moz.build
|
||||
index 0eb3c53..fb94b5c 100644
|
||||
index 269dcb2..ed7c31d 100644
|
||||
--- a/browser/extensions/moz.build
|
||||
+++ b/browser/extensions/moz.build
|
||||
@@ -4,4 +4,4 @@
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
@@ -5,10 +5,7 @@
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
-DIRS += ["doh-rollout", "formautofill", "screenshots", "webcompat", "report-site-issue"]
|
||||
+DIRS += ["formautofill", "screenshots"]
|
||||
DIRS += [
|
||||
- "doh-rollout",
|
||||
"formautofill",
|
||||
"screenshots",
|
||||
- "webcompat",
|
||||
- "report-site-issue",
|
||||
"pictureinpicture",
|
||||
]
|
||||
diff --git a/browser/locales/Makefile.in b/browser/locales/Makefile.in
|
||||
index 496379c..dd6f359 100644
|
||||
--- a/browser/locales/Makefile.in
|
|
@ -1,20 +1,22 @@
|
|||
--- a/browser/base/content/browser-menubar.inc
|
||||
+++ b/browser/base/content/browser-menubar.inc
|
||||
@@ -5,7 +5,11 @@
|
||||
|
||||
<menubar id="main-menubar"
|
||||
onpopupshowing="if (event.target.parentNode.parentNode == this &&
|
||||
@@ -7,7 +7,12 @@
|
||||
# On macOS, we don't track whether activation of the native menubar happened
|
||||
# with the keyboard.
|
||||
#ifndef XP_MACOSX
|
||||
- onpopupshowing="if (event.target.parentNode.parentNode == this)
|
||||
+ onpopupshowing="if (event.target.parentNode.parentNode == this &&
|
||||
+#ifdef MOZ_WIDGET_GTK
|
||||
+ document.documentElement.getAttribute('shellshowingmenubar') != 'true')
|
||||
+#else
|
||||
!('@mozilla.org/widget/nativemenuservice;1' in Cc))
|
||||
+ true)
|
||||
+#endif
|
||||
this.setAttribute('openedwithkey',
|
||||
event.target.parentNode.openedWithKey);">
|
||||
<menu id="file-menu" data-l10n-id="menu-file">
|
||||
event.target.parentNode.openedWithKey);"
|
||||
#endif
|
||||
--- a/browser/base/content/browser.js
|
||||
+++ b/browser/base/content/browser.js
|
||||
@@ -6231,11 +6231,18 @@ function onViewToolbarsPopupShowing(aEve
|
||||
@@ -6291,11 +6291,18 @@ function onViewToolbarsPopupShowing(aEve
|
||||
MozXULElement.insertFTLIfNeeded("browser/toolbarContextMenu.ftl");
|
||||
let firstMenuItem = aInsertPoint || popup.firstElementChild;
|
||||
let toolbarNodes = gNavToolbox.querySelectorAll("toolbar");
|
||||
|
@ -98,7 +100,7 @@
|
|||
"components.conf",
|
||||
--- a/modules/libpref/init/all.js
|
||||
+++ b/modules/libpref/init/all.js
|
||||
@@ -305,6 +305,9 @@ pref("dom.mouseevent.click.hack.use_lega
|
||||
@@ -301,6 +301,9 @@ pref("dom.mouseevent.click.hack.use_lega
|
||||
// Fastback caching - if this pref is negative, then we calculate the number
|
||||
// of content viewers to cache based on the amount of available memory.
|
||||
pref("browser.sessionhistory.max_total_viewers", -1);
|
||||
|
@ -110,7 +112,7 @@
|
|||
|
||||
--- a/toolkit/content/xul.css
|
||||
+++ b/toolkit/content/xul.css
|
||||
@@ -221,6 +221,13 @@ toolbar[type="menubar"] {
|
||||
@@ -230,6 +230,13 @@ toolbar[type="menubar"] {
|
||||
}
|
||||
%endif
|
||||
|
||||
|
@ -4292,7 +4294,7 @@
|
|||
+ MOZ_ASSERT(!mContentToObserverTable.Get(aContent, &old) || old == aObserver,
|
||||
+ "Multiple observers for the same content node are not supported");
|
||||
+
|
||||
+ mContentToObserverTable.Put(aContent, aObserver);
|
||||
+ mContentToObserverTable.InsertOrUpdate(aContent, aObserver);
|
||||
+}
|
||||
+
|
||||
+void
|
||||
|
@ -4352,7 +4354,7 @@
|
|||
+#include "mozilla/Attributes.h"
|
||||
+#include "mozilla/RefPtr.h"
|
||||
+#include "mozilla/UniquePtr.h"
|
||||
+#include "nsDataHashtable.h"
|
||||
+#include "nsTHashMap.h"
|
||||
+#include "nsStubMutationObserver.h"
|
||||
+#include "nsTArray.h"
|
||||
+
|
||||
|
@ -4459,7 +4461,7 @@
|
|||
+ nsIContent *mLastSource;
|
||||
+ nsNativeMenuChangeObserver *mLastTarget;
|
||||
+ nsTArray<mozilla::UniquePtr<MutationRecord> > mPendingMutations;
|
||||
+ nsDataHashtable<nsPtrHashKey<nsIContent>, nsNativeMenuChangeObserver *> mContentToObserverTable;
|
||||
+ nsTHashMap<nsPtrHashKey<nsIContent>, nsNativeMenuChangeObserver *> mContentToObserverTable;
|
||||
+
|
||||
+ static uint32_t sUpdateBlockersCount;
|
||||
+};
|
||||
|
@ -4737,7 +4739,7 @@
|
|||
+ }
|
||||
+
|
||||
+ GCancellable *cancellable = g_cancellable_new();
|
||||
+ mMenuBarRegistrationCancellables.Put(aMenuBar, cancellable);
|
||||
+ mMenuBarRegistrationCancellables.InsertOrUpdate(aMenuBar, cancellable);
|
||||
+
|
||||
+ // We keep a weak ref because we can't assume that GDBus cancellation
|
||||
+ // is reliable (see https://launchpad.net/bugs/953562)
|
||||
|
@ -4987,7 +4989,7 @@
|
|||
+
|
||||
+#include "mozilla/Attributes.h"
|
||||
+#include "nsCOMPtr.h"
|
||||
+#include "nsDataHashtable.h"
|
||||
+#include "nsTHashMap.h"
|
||||
+#include "nsINativeMenuService.h"
|
||||
+#include "nsTArray.h"
|
||||
+
|
||||
|
@ -5053,7 +5055,7 @@
|
|||
+ GDBusProxy *mDbusProxy;
|
||||
+ bool mOnline;
|
||||
+ nsTArray<nsMenuBar *> mMenuBars;
|
||||
+ nsDataHashtable<nsPtrHashKey<nsMenuBar>, GCancellable*> mMenuBarRegistrationCancellables;
|
||||
+ nsTHashMap<nsPtrHashKey<nsMenuBar>, GCancellable*> mMenuBarRegistrationCancellables;
|
||||
+
|
||||
+ static bool sShutdown;
|
||||
+ static nsNativeMenuService *sService;
|
||||
|
@ -5062,7 +5064,7 @@
|
|||
+#endif /* __nsNativeMenuService_h__ */
|
||||
--- a/widget/gtk/nsWindow.cpp
|
||||
+++ b/widget/gtk/nsWindow.cpp
|
||||
@@ -6386,6 +6386,10 @@ void nsWindow::HideWindowChrome(bool aSh
|
||||
@@ -6409,6 +6409,10 @@ void nsWindow::HideWindowChrome(bool aSh
|
||||
SetWindowDecoration(aShouldHide ? eBorderStyle_none : mBorderStyle);
|
||||
}
|
||||
|
||||
|
@ -5093,7 +5095,7 @@
|
|||
/**
|
||||
* GetLastUserInputTime returns a timestamp for the most recent user input
|
||||
* event. This is intended for pointer grab requests (including drags).
|
||||
@@ -719,6 +723,8 @@ class nsWindow final : public nsBaseWidg
|
||||
@@ -722,6 +726,8 @@ class nsWindow final : public nsBaseWidg
|
||||
static GtkWindowDecoration sGtkWindowDecoration;
|
||||
|
||||
static bool sTransparentMainWindow;
|
||||
|
@ -5124,7 +5126,7 @@
|
|||
import sys
|
||||
|
||||
# Static atom definitions, used to generate nsGkAtomList.h.
|
||||
@@ -2508,7 +2509,7 @@ STATIC_ATOMS = [
|
||||
@@ -2507,7 +2508,7 @@ STATIC_ATOMS = [
|
||||
InheritingAnonBoxAtom("AnonBox_mozSVGForeignContent", ":-moz-svg-foreign-content"),
|
||||
InheritingAnonBoxAtom("AnonBox_mozSVGText", ":-moz-svg-text"),
|
||||
# END ATOMS
|
||||
|
@ -5279,3 +5281,20 @@
|
|||
+NS_DEFINE_STATIC_IID_ACCESSOR(nsINativeMenuService, NS_INATIVEMENUSERVICE_IID)
|
||||
+
|
||||
+#endif // nsINativeMenuService_h_
|
||||
--- a/widget/nsWidgetsCID.h
|
||||
+++ b/widget/nsWidgetsCID.h
|
||||
@@ -66,6 +66,14 @@
|
||||
// Menus
|
||||
//-----------------------------------------------------------
|
||||
|
||||
+// {0B3FE5AA-BC72-4303-85AE-76365DF1251D}
|
||||
+#define NS_NATIVEMENUSERVICE_CID \
|
||||
+ { \
|
||||
+ 0x0B3FE5AA, 0xBC72, 0x4303, { \
|
||||
+ 0x85, 0xAE, 0x76, 0x36, 0x5D, 0xF1, 0x25, 0x1D \
|
||||
+ } \
|
||||
+ }
|
||||
+
|
||||
// {F6CD4F21-53AF-11d2-8DC4-00609703C14E}
|
||||
#define NS_POPUPMENU_CID \
|
||||
{ \
|
7
docs/README.md
Normal file
7
docs/README.md
Normal file
|
@ -0,0 +1,7 @@
|
|||
![Logo](https://librewolf-community.gitlab.io/images/logo.png)
|
||||
|
||||
# LibreWolf
|
||||
|
||||
## Documentation has moved
|
||||
|
||||
You can find the current documentation for LibreWolf at [librewolf-community.gitlab.io/docs/](https://librewolf-community.gitlab.io/docs/).
|
|
@ -4,66 +4,60 @@ printf "\n\n-------------------------------------- DEPENDENCY INSTALLATION -----
|
|||
set -e
|
||||
|
||||
# Setup Script Variables
|
||||
_DEPENDENCIES="wget git xvfb \
|
||||
xz-utils \
|
||||
gettext-base \
|
||||
curl python3 libjack-dev \
|
||||
python3-psutil python-psutil python3-dev python-dev \
|
||||
autotools-dev \
|
||||
autoconf2.13 \
|
||||
zip \
|
||||
libx11-dev \
|
||||
libx11-xcb-dev \
|
||||
libxt-dev \
|
||||
libxext-dev \
|
||||
libgtk2.0-dev \
|
||||
libgtk-3-dev \
|
||||
libglib2.0-dev \
|
||||
libpango1.0-dev \
|
||||
libfontconfig1-dev \
|
||||
libfreetype6-dev \
|
||||
libstartup-notification0-dev \
|
||||
libasound2-dev \
|
||||
libcurl4-openssl-dev \
|
||||
libdbus-glib-1-dev \
|
||||
hardening-wrapper \
|
||||
lsb-release \
|
||||
libiw-dev \
|
||||
mesa-common-dev \
|
||||
libnotify-dev \
|
||||
libxrender-dev \
|
||||
libpulse-dev \
|
||||
libssl-dev \
|
||||
yasm \
|
||||
unzip \
|
||||
dbus-x11 \
|
||||
python \
|
||||
nodejs-mozilla \
|
||||
nasm-mozilla \
|
||||
gcc-mozilla"
|
||||
|
||||
# cargo \
|
||||
# rustc \
|
||||
|
||||
export DEBIAN_FRONTEND=noninteractive
|
||||
|
||||
_DEPENDENCIES="wget git xorg-server-xvfb \
|
||||
xz grep coreutils patch tar \
|
||||
gettext pkg-config \
|
||||
curl python3 libjack \
|
||||
python3-psutil python3-devel python-devel \
|
||||
automake \
|
||||
autoconf213 \
|
||||
zip \
|
||||
libX11-devel \
|
||||
libXt-devel \
|
||||
libXext-devel \
|
||||
gtk+3-devel \
|
||||
libglib-devel \
|
||||
pango-devel \
|
||||
fontconfig-devel \
|
||||
freetype-devel \
|
||||
libcurl-devel \
|
||||
MesaLib-devel \
|
||||
libnotify-devel \
|
||||
libXrender-devel \
|
||||
pulseaudio-devel \
|
||||
openssl-devel \
|
||||
yasm \
|
||||
unzip \
|
||||
dbus-x11 \
|
||||
python \
|
||||
libffi-devel \
|
||||
nodejs-lts \
|
||||
cargo \
|
||||
rust \
|
||||
nasm \
|
||||
clang \
|
||||
llvm \
|
||||
alsa-lib-devel \
|
||||
jack-devel \
|
||||
perl \
|
||||
cbindgen \
|
||||
pixman-devel \
|
||||
libevent-devel libnotify-devel libvpx-devel \
|
||||
libXcomposite-devel libSM-devel libXdamage-devel \
|
||||
dbus-glib-devel \
|
||||
make"
|
||||
|
||||
# Installs Dependencies
|
||||
printf "\nInstalling dependencies: $_DEPENDENCIES\n";
|
||||
apt-get -qq update;
|
||||
apt-get -y -qq install $_DEPENDENCIES;
|
||||
xbps-install -Sy $_DEPENDENCIES 2>&1 >/dev/null
|
||||
|
||||
if [[ $CARCH == 'x86_64' ]];then
|
||||
# Installs (non-ancient) clang
|
||||
apt install -y software-properties-common apt-transport-https ca-certificates
|
||||
apt-add-repository "deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-11 main"
|
||||
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add
|
||||
apt-get update
|
||||
apt-get -y install clang-11 libclang-11-dev
|
||||
else
|
||||
apt-get -y install clang-8 libclang-8-dev
|
||||
if [[ "$(/lib/libc.so 2>&1)" == *"musl libc"* ]]; then
|
||||
xbps-install -y libfl-devel libssp-devel libssp 2>&1 >/dev/null
|
||||
fi
|
||||
|
||||
# we need a more recent rust
|
||||
curl https://sh.rustup.rs -o rustup.sh
|
||||
bash rustup.sh -y
|
||||
source /root/.cargo/env
|
||||
ln -s /bin/clang /bin/cc
|
||||
mkdir /usr/lib/nodejs-mozilla/
|
||||
ln -s /usr/bin/ /usr/lib/nodejs-mozilla/bin
|
||||
mkdir /usr/lib/nasm-mozilla
|
||||
ln -s /usr/bin/ /usr/lib/nasm-mozilla/bin
|
||||
ln -s /usr/bin/make /usr/bin/gmake
|
||||
|
|
|
@ -9,11 +9,12 @@ if [[ -z ${pkgver} || -z ${pkgrel} ]]; then
|
|||
fi
|
||||
# Setup Script Variables
|
||||
SOURCE_FOLDER=$1;
|
||||
_SOURCE_CODE_URL="https://archive.mozilla.org/pub/firefox/releases/$pkgver/source/firefox-$pkgver.source.tar.xz";
|
||||
#_SOURCE_CODE_URL="https://archive.mozilla.org/pub/firefox/releases/$pkgver/source/firefox-$pkgver.source.tar.xz";
|
||||
_SOURCE_CODE_URL="https://f.sakamoto.pl/firefox-$pkgver.source.tar.xz";
|
||||
_SOURCE_TAR="firefox-${pkgver}.tar.xz"
|
||||
|
||||
# Downloading and Extracting Firefox Source Code
|
||||
printf "\nDownloading Firefox Source Code\n";
|
||||
wget -O $_SOURCE_TAR $_SOURCE_CODE_URL
|
||||
wget -O $_SOURCE_TAR $_SOURCE_CODE_URL 2>&1 > /dev/null
|
||||
mkdir -p $SOURCE_FOLDER
|
||||
tar -x --strip-components=1 -C $SOURCE_FOLDER -f $_SOURCE_TAR
|
||||
|
|
|
@ -6,16 +6,38 @@ set -e
|
|||
# Setup Script Variables
|
||||
srcdir=$1;
|
||||
CI_PROJECT_DIR=${CI_PROJECT_DIR:-$(realpath $(dirname $0)/../)}
|
||||
_COMMON_REPO='https://gitlab.com/librewolf-community/browser/common.git';
|
||||
#_COMMON_REPO='https://gitlab.com/librewolf-community/browser/common.git';
|
||||
_COMMON_REPO='https://git.sakamoto.pl/domi/foxgirl-common.git';
|
||||
_PKGVER_TAG="v${pkgver}-${pkgrel}"
|
||||
_COMMON_TAG=${COMMON_TAG:-${_PKGVER_TAG}}
|
||||
_COMMON_DIR="${CI_PROJECT_DIR}"/common
|
||||
_PATCHES_DIR="${_COMMON_DIR}"/patches
|
||||
_MOZBUILD=$srcdir/../mozbuild
|
||||
|
||||
mkdir -p ${_MOZBUILD}
|
||||
|
||||
# Copy Source Code Changes to Source Code
|
||||
printf "\nCopying branding and source code changes to firefox source code\n";
|
||||
git clone $_COMMON_REPO common;
|
||||
cp -r common/source_files/* $srcdir/;
|
||||
rm -rf common;
|
||||
git clone $_COMMON_REPO ${_COMMON_DIR}
|
||||
cd ${_COMMON_DIR}
|
||||
#git checkout ${_COMMON_TAG}
|
||||
cd ..
|
||||
cp -r ${_COMMON_DIR}/source_files/* $srcdir/;
|
||||
|
||||
# get foxgirl branding (ff3.6)
|
||||
wget "https://web.archive.org/web/0/http://people.mozilla.com/~faaborg/files/shiretoko/firefoxIcon/firefoxIcon.zip"
|
||||
mkdir -p icons icons/content
|
||||
pushd icons
|
||||
|
||||
unzip ../firefoxIcon.zip
|
||||
for i in firefox*noshadow.png; do
|
||||
mv "$i" "default$(grep -Poh "[0-9]+" <<< "$i").png"
|
||||
done
|
||||
mv firefox-256.png content/about-logo.png
|
||||
mv firefox-512.png "content/about-logo@2x.png"
|
||||
popd
|
||||
|
||||
cp -rlf icons/* $srcdir/browser/branding/librewolf/
|
||||
|
||||
cd $srcdir
|
||||
|
||||
|
@ -25,7 +47,6 @@ mk_add_options MOZ_OBJDIR=${srcdir}/firefox-${pkgver}/obj
|
|||
|
||||
# to build on ubuntu and pick up clang
|
||||
ac_add_options NODEJS=/usr/lib/nodejs-mozilla/bin/node
|
||||
ac_add_options NASM=/usr/lib/nasm-mozilla/bin/nasm
|
||||
|
||||
# This supposedly speeds up compilation (We test through dogfooding anyway)
|
||||
ac_add_options --disable-tests
|
||||
|
@ -38,13 +59,12 @@ ac_add_options --enable-rust-simd
|
|||
|
||||
# Branding
|
||||
ac_add_options --enable-update-channel=release
|
||||
ac_add_options --with-app-name=librewolf
|
||||
ac_add_options --with-app-basename=LibreWolf
|
||||
ac_add_options --with-app-name=foxgirl
|
||||
ac_add_options --with-app-basename=Foxgirl
|
||||
ac_add_options --with-branding=browser/branding/librewolf
|
||||
ac_add_options --with-distribution-id=io.gitlab.librewolf-community
|
||||
ac_add_options --with-unsigned-addon-scopes=app,system
|
||||
ac_add_options --allow-addon-sideload
|
||||
export MOZ_REQUIRE_SIGNING=0
|
||||
|
||||
# System libraries
|
||||
# ac_add_options --with-system-nspr
|
||||
|
@ -68,20 +88,28 @@ mk_add_options MOZ_TELEMETRY_REPORTING=0
|
|||
# ac_add_options --enable-linker=gold
|
||||
END
|
||||
|
||||
if [[ "$(/lib/libc.so 2>&1)" == *"musl libc"* ]]; then
|
||||
echo "ac_add_options --disable-jemalloc" >> ${CI_PROJECT_DIR}/mozconfig
|
||||
echo "ac_add_options --disable-gold" >> ${CI_PROJECT_DIR}/mozconfig
|
||||
echo "ac_add_options --disable-webrtc" >> ${CI_PROJECT_DIR}/mozconfig
|
||||
fi
|
||||
|
||||
# allow setting limited resource usage via ENV / CI:
|
||||
|
||||
if [[ ! -z ${CORES_TO_USE} ]]; then
|
||||
echo "mk_add_options MOZ_MAKE_FLAGS=\"-j${CORES_TO_USE}\"" >> ${CI_PROJECT_DIR}/mozconfig
|
||||
fi
|
||||
|
||||
if [[ $CARCH == 'aarch64' ]]; then
|
||||
cat >>${CI_PROJECT_DIR}/mozconfig <<END
|
||||
# taken from manjaro build:
|
||||
ac_add_options --enable-optimize="-g0 -O2"
|
||||
|
||||
# from ALARM
|
||||
# should only fail on armv7x
|
||||
# ac_add_options --disable-webrtc
|
||||
|
||||
export CC='clang-8'
|
||||
export CXX='clang++-8'
|
||||
export AR=llvm-ar-8
|
||||
export NM=llvm-nm-8
|
||||
export RANLIB=llvm-ranlib-8
|
||||
export CC='clang'
|
||||
export CXX='clang++'
|
||||
export AR=llvm-ar
|
||||
export NM=llvm-nm
|
||||
export RANLIB=llvm-ranlib
|
||||
END
|
||||
|
||||
export MOZ_DEBUG_FLAGS=" "
|
||||
|
@ -90,79 +118,96 @@ END
|
|||
export RUSTFLAGS="-Cdebuginfo=0"
|
||||
|
||||
export LDFLAGS+=" -Wl,--no-keep-memory -Wl"
|
||||
patch -p1 -i ${CI_PROJECT_DIR}/arm.patch
|
||||
wget https://raw.githubusercontent.com/archlinuxarm/PKGBUILDs/master/extra/firefox/build-arm-libopus.patch -O ${CI_PROJECT_DIR}/build-arm-libopus.patch
|
||||
patch -p1 -i ${CI_PROJECT_DIR}/build-arm-libopus.patch
|
||||
# patch -Np1 -i ${_PATCHES_DIR}/arm.patch # not required anymore?
|
||||
wget https://raw.githubusercontent.com/archlinuxarm/PKGBUILDs/master/extra/firefox/build-arm-libopus.patch -O ${_PATCHES_DIR}/build-arm-libopus.patch
|
||||
patch -Np1 -i ${_PATCHES_DIR}/build-arm-libopus.patch
|
||||
|
||||
else
|
||||
cat >>${CI_PROJECT_DIR}/mozconfig <<END
|
||||
# ubuntu seems to recommend this
|
||||
ac_add_options --disable-elf-hack
|
||||
|
||||
export CC='clang-11'
|
||||
export CXX='clang++-11'
|
||||
export AR=llvm-ar-11
|
||||
export NM=llvm-nm-11
|
||||
export RANLIB=llvm-ranlib-11
|
||||
export CC='clang'
|
||||
export CXX='clang++'
|
||||
export AR=llvm-ar
|
||||
export NM=llvm-nm
|
||||
export RANLIB=llvm-ranlib
|
||||
|
||||
# probably not needed, enabled by default?
|
||||
ac_add_options --enable-optimize
|
||||
|
||||
# unavailable option when (on ubuntu at least(?)) building on aarch64
|
||||
ac_add_options NASM=/usr/lib/nasm-mozilla/bin/nasm
|
||||
END
|
||||
|
||||
fi
|
||||
|
||||
# hopefully the magic sauce that makes things build on 16.04 and later on work "everywhere":
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/lower-python3-requirement.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/armhf-reduce-linker-memory-use.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/build-with-libstdc++-7.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/fix-armhf-webrtc-build.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/webrtc-fix-compiler-flags-for-armhf.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/reduce-rust-debuginfo.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/relax-cargo-dep.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/use-system-icupkg.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/python3-remove-variable-annotations.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/python3-remove-fstrings.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/python3-remove-pep487.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/silence-gtk-style-assertions.patch"
|
||||
patch -p1 -i "${CI_PROJECT_DIR}/deb_patches/sandbox-update-arm-syscall-numbers.patch"
|
||||
patch -Np1 -i "${CI_PROJECT_DIR}/deb_patches/armhf-reduce-linker-memory-use.patch"
|
||||
patch -Np1 -i "${CI_PROJECT_DIR}/deb_patches/fix-armhf-webrtc-build.patch"
|
||||
patch -Np1 -i "${CI_PROJECT_DIR}/deb_patches/webrtc-fix-compiler-flags-for-armhf.patch"
|
||||
patch -Np1 -i "${CI_PROJECT_DIR}/deb_patches/reduce-rust-debuginfo.patch"
|
||||
patch -Np1 -i "${CI_PROJECT_DIR}/deb_patches/use-system-icupkg.patch"
|
||||
|
||||
# Remove some pre-installed addons that might be questionable
|
||||
patch -p1 -i ${CI_PROJECT_DIR}/remove_addons.patch
|
||||
patch -Np1 -i ${_PATCHES_DIR}/remove_addons.patch
|
||||
|
||||
# Disable (some) megabar functionality
|
||||
# Adapted from https://github.com/WesleyBranton/userChrome.css-Customizations
|
||||
patch -p1 -i ${CI_PROJECT_DIR}/megabar.patch
|
||||
patch -Np1 -i ${_PATCHES_DIR}/megabar.patch
|
||||
|
||||
# remove mozilla vpn ads
|
||||
patch -p1 -i ${CI_PROJECT_DIR}/mozilla-vpn-ad.patch
|
||||
patch -Np1 -i ${_PATCHES_DIR}/mozilla-vpn-ad.patch
|
||||
|
||||
# Debian patch to enable global menubar
|
||||
if [[ ! -z "${GLOBAL_MENUBAR}" ]];then
|
||||
patch -p1 -i ${CI_PROJECT_DIR}/unity-menubar.patch
|
||||
patch -Np1 -i ${_PATCHES_DIR}/unity-menubar.patch
|
||||
fi
|
||||
|
||||
# Disabling Pocket
|
||||
printf "\nDisabling Pocket\n";
|
||||
sed -i "s/'pocket'/#'pocket'/g" browser/components/moz.build
|
||||
patch -Np1 -i "${_PATCHES_DIR}/sed-patches/disable-pocket.patch"
|
||||
|
||||
patch -Np1 -i "${CI_PROJECT_DIR}/context-menu.patch"
|
||||
# More patches
|
||||
patch -Np1 -i "${_PATCHES_DIR}/context-menu.patch"
|
||||
|
||||
# this one only to remove an annoying error message:
|
||||
sed -i 's#SaveToPocket.init();#// SaveToPocket.init();#g' browser/components/BrowserGlue.jsm
|
||||
patch -Np1 -i "${_PATCHES_DIR}/browser-confvars.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/urlbarprovider-interventions.patch"
|
||||
|
||||
# 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'
|
||||
sed -z "$_cert_sed" -i toolkit/mozapps/extensions/internal/XPIInstall.jsm
|
||||
patch -Np1 -i "${_PATCHES_DIR}/sed-patches/remove-internal-plugin-certs.patch"
|
||||
|
||||
# allow SearchEngines option in non-ESR builds
|
||||
sed -i 's#"enterprise_only": true,#"enterprise_only": false,#g' browser/components/enterprisepolicies/schemas/policies-schema.json
|
||||
patch -Np1 -i "${_PATCHES_DIR}/sed-patches/allow-searchengines-non-esr.patch"
|
||||
|
||||
# remove search extensions (experimental)
|
||||
patch -Np1 -i "${_PATCHES_DIR}/search-config.patch"
|
||||
|
||||
# stop some undesired requests (https://gitlab.com/librewolf-community/browser/common/-/issues/10)
|
||||
_settings_services_sed='s#firefox.settings.services.mozilla.com#f.s.s.m.c.qjz9zk#g'
|
||||
sed "$_settings_services_sed" -i browser/components/newtab/data/content/activity-stream.bundle.js
|
||||
sed "$_settings_services_sed" -i modules/libpref/init/all.js
|
||||
sed "$_settings_services_sed" -i services/settings/Utils.jsm
|
||||
sed "$_settings_services_sed" -i toolkit/components/search/SearchUtils.jsm
|
||||
patch -Np1 -i "${_PATCHES_DIR}/sed-patches/stop-undesired-requests.patch"
|
||||
|
||||
# allow overriding the color scheme light/dark preference with RFP
|
||||
patch -Np1 -i ${_PATCHES_DIR}/allow_dark_preference_with_rfp.patch
|
||||
|
||||
# fix an URL in 'about' dialog
|
||||
patch -Np1 -i ${_PATCHES_DIR}/about-dialog.patch
|
||||
|
||||
# change some hardcoded directory strings that could lead to unnecessarily
|
||||
# created directories
|
||||
patch -Np1 -i ${_PATCHES_DIR}/mozilla_dirs.patch
|
||||
|
||||
# Foxgirl-specific patches
|
||||
patch -Np1 -i "${_PATCHES_DIR}/urlbar.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/icons.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/wordmark.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/css.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/defsites.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/bookmarksbar.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/smile.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/strings.patch"
|
||||
patch -Np1 -i "${_PATCHES_DIR}/view-page-info.patch"
|
||||
#patch -Np1 -i "${_PATCHES_DIR}/useragent-override.patch"
|
||||
|
||||
echo '[]' > browser/components/newtab/data/content/tippytop/top_sites.json
|
||||
echo '[]' > browser/components/urlbar/content/preloaded-top-urls.json
|
||||
rm -rf common
|
||||
|
|
|
@ -7,7 +7,7 @@ set -e
|
|||
srcdir=$1;
|
||||
OUTPUT_TARBALL=$2;
|
||||
CI_PROJECT_DIR=${CI_PROJECT_DIR:-$(realpath $(dirname $0)/../)}
|
||||
_SOURCE_CODE_BINARY_TARBALL_LOCATION="${srcdir}/firefox-${pkgver}/obj/dist/librewolf*.tar.bz2";
|
||||
_SOURCE_CODE_BINARY_TARBALL_LOCATION="${srcdir}/firefox-${pkgver}/obj/dist/foxgirl*.tar.bz2";
|
||||
_MOZBUILD=$srcdir/../mozbuild
|
||||
export DEB_BUILD_HARDENING=1
|
||||
export DEB_BUILD_HARDENING_STACKPROTECTOR=1
|
||||
|
@ -16,7 +16,8 @@ export DEB_BUILD_HARDENING_FORMAT=1
|
|||
export DEB_BUILD_HARDENING_PIE=1
|
||||
# export PATH=/usr/lib/nasm-mozilla/bin:$PATH
|
||||
|
||||
source /root/.cargo/env
|
||||
# add cargo binary to path
|
||||
# source /root/.cargo/env
|
||||
|
||||
# we do change / unset some of them later, but setting them as set by Arch
|
||||
# might make it easier to maintain changes in build scripts on both sides
|
||||
|
@ -62,11 +63,10 @@ cd $srcdir;
|
|||
|
||||
rm -f mozconfig
|
||||
|
||||
# add cargo binary to path
|
||||
# source /root/.cargo/env
|
||||
|
||||
# install cbindgen
|
||||
cargo install --version 0.18.0 cbindgen
|
||||
#if [[ "$(/lib/libc.so)" != *"musl libc"* ]]; then
|
||||
# cargo install --version 0.20.0 cbindgen
|
||||
#fi
|
||||
|
||||
if [[ $CARCH == 'aarch64' ]]; then
|
||||
|
||||
|
@ -92,7 +92,7 @@ echo "Building symbol archive..."
|
|||
# End "build()" equivalent.
|
||||
|
||||
# Packages the build into a binary tarball
|
||||
printf "\nPackaging LibreWolf\n";
|
||||
printf "\nPackaging\n";
|
||||
./mach package;
|
||||
|
||||
# Moves the packaged tarball to the specified location
|
||||
|
|
|
@ -10,9 +10,9 @@ TOGGLE_SETTINGS_SCRIPT=$2;
|
|||
LAUNCHER_SCRIPT=$3;
|
||||
CI_PROJECT_DIR=${CI_PROJECT_DIR:-$(realpath $(dirname $0)/../)}
|
||||
_SCRIPT_FOLDER=$(realpath $(dirname $0));
|
||||
_EXTRACTED_TARBALL_FOLDER=$_SCRIPT_FOLDER/librewolf;
|
||||
_SETTINGS_COMMIT=241e6f4d73e6f2de37537cf4473612ae9f8ad81e
|
||||
_SETTINGS_REPO='https://gitlab.com/librewolf-community/settings.git';
|
||||
_EXTRACTED_TARBALL_FOLDER=$_SCRIPT_FOLDER/foxgirl;
|
||||
_SETTINGS_TAG=${SETTINGS_TAG:-'2.0'}
|
||||
_SETTINGS_REPO='https://git.sakamoto.pl/domi/foxgirl-settings';
|
||||
|
||||
# Extracts the binary tarball
|
||||
printf "\nExtracting librewolf binary tarball\n";
|
||||
|
@ -24,7 +24,7 @@ printf "\nCopying librewolf settings to extracted binary tarball\n";
|
|||
|
||||
git clone $_SETTINGS_REPO $_EXTRACTED_TARBALL_FOLDER/settings;
|
||||
cd $_EXTRACTED_TARBALL_FOLDER/settings
|
||||
git checkout $_SETTINGS_COMMIT
|
||||
#git checkout $_SETTINGS_TAG
|
||||
cd -
|
||||
# no need to keep that in there:
|
||||
rm -rf "${_EXTRACTED_TARBALL_FOLDER}/settings/.git";
|
||||
|
@ -44,12 +44,12 @@ install -Dvm644 /dev/stdin "$distini" <<END
|
|||
[Global]
|
||||
id=io.gitlab.librewolf-community
|
||||
version=1.0
|
||||
about=LibreWolf
|
||||
about=Foxgirl
|
||||
|
||||
[Preferences]
|
||||
app.distributor="LibreWolf Community"
|
||||
app.distributor.channel=librewolf
|
||||
app.partner.librewolf=librewolf
|
||||
app.distributor="idk lmao"
|
||||
app.distributor.channel=foxgirl
|
||||
app.partner.librewolf=foxgirl
|
||||
END
|
||||
|
||||
# Create Appstream metadate file
|
||||
|
|
Loading…
Reference in a new issue