update branding

This commit is contained in:
oneflux 2025-04-21 20:41:38 -07:00
parent e1fe519a7e
commit 9cda17c3f2
30 changed files with 118 additions and 118 deletions

2
.gitignore vendored
View file

@ -1,5 +1,5 @@
# Local builds
/camoufox-*
/omegafox-*
/firefox-*
/mozilla-unified
dist/

View file

@ -1,7 +1,7 @@
include upstream.sh
export
cf_source_dir := camoufox-$(version)-$(release)
cf_source_dir := omegafox-$(version)-$(release)
ff_source_tarball := firefox-$(version).source.tar.xz
debs := python3 python3-dev python3-pip p7zip-full golang-go msitools wget aria2
@ -31,7 +31,7 @@ help:
@echo " package-macos - Package Camoufox for macOS"
@echo " package-windows - Package Camoufox for Windows"
@echo " run - Run Camoufox"
@echo " edit-cfg - Edit camoufox.cfg"
@echo " edit-cfg - Edit omegafox.cfg"
@echo " ff-dbg - Setup vanilla Firefox with minimal patches"
@echo " patch - Apply a patch"
@echo " unpatch - Remove a patch"
@ -88,7 +88,7 @@ ff-dbg: setup
# Only apply patches to help debug vanilla Firefox
make patch ./patches/chromeutil.patch
make patch ./patches/browser-init.patch
echo "LOCAL_INCLUDES += ['/camoucfg']" >> $(cf_source_dir)/dom/base/moz.build
echo "LOCAL_INCLUDES += ['/omegacfg']" >> $(cf_source_dir)/dom/base/moz.build
touch $(cf_source_dir)/_READY
make checkpoint
make build
@ -147,7 +147,7 @@ build-launcher: check-arch
package-linux:
python3 scripts/package.py linux \
--includes \
settings/camoucfg.jvv \
settings/omegacfg.jvv \
settings/properties.json \
bundle/fontconfigs \
--version $(version) \
@ -158,7 +158,7 @@ package-linux:
package-macos:
python3 scripts/package.py macos \
--includes \
settings/camoucfg.jvv \
settings/omegacfg.jvv \
settings/properties.json \
--version $(version) \
--release $(release) \
@ -168,7 +168,7 @@ package-macos:
package-windows:
python3 scripts/package.py windows \
--includes \
settings/camoucfg.jvv \
settings/omegacfg.jvv \
settings/properties.json \
~/.mozbuild/vs/VC/Redist/MSVC/14.38.33135/$(vcredist_arch)/Microsoft.VC143.CRT/*.dll \
--version $(version) \
@ -191,16 +191,16 @@ run-pw:
run:
cd $(cf_source_dir) \
&& rm -rf ~/.camoufox obj-x86_64-pc-linux-gnu/tmp/profile-default \
&& rm -rf ~/.omegafox obj-x86_64-pc-linux-gnu/tmp/profile-default \
&& CAMOU_CONFIG=$${CAMOU_CONFIG:-'{}'} \
&& CAMOU_CONFIG="$${CAMOU_CONFIG%?}, \"debug\": true}" ./mach run $(args)
edit-cfg:
@if [ ! -f $(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/camoufox.cfg ]; then \
echo "Error: camoufox.cfg not found. Apply config.patch first."; \
@if [ ! -f $(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/omegafox.cfg ]; then \
echo "Error: omegafox.cfg not found. Apply config.patch first."; \
exit 1; \
fi
$(EDITOR) $(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/camoufox.cfg
$(EDITOR) $(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/omegafox.cfg
check-arg:
@if [ -z "$(_ARGS)" ]; then \
@ -231,12 +231,12 @@ workspace:
make patch $(_ARGS)
unbusy:
rm -rf $(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/camoufox-bin \
$(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/camoufox \
rm -rf $(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/omegafox-bin \
$(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/omegafox \
$(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/launch
path:
@realpath $(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/camoufox-bin
@realpath $(cf_source_dir)/obj-x86_64-pc-linux-gnu/dist/bin/omegafox-bin
upload:
# ===============================
@ -244,8 +244,8 @@ upload:
# ===============================
@test -f .passwd || { echo "Error: .passwd file not found"; exit 1; }
@mkdir -p ../camoufox-web/internal
@rm -rf ../camoufox-web/pipeline/rev-$(closedsrc_rev).7z
7z a "-p$$(cat ./.passwd)" -mhe=on ../camoufox-web/pipeline/rev-$(closedsrc_rev).7z "./patches/private/*.patch"
@mkdir -p ../omegafox-web/internal
@rm -rf ../omegafox-web/pipeline/rev-$(closedsrc_rev).7z
7z a "-p$$(cat ./.passwd)" -mhe=on ../omegafox-web/pipeline/rev-$(closedsrc_rev).7z "./patches/private/*.patch"
vcredist_arch := $(shell echo $(arch) | sed 's/x86_64/x64/' | sed 's/i686/x86/')

View file

@ -12,7 +12,7 @@ EXPORTS += [
]
LOCAL_INCLUDES += [
"/camoucfg",
"/omegacfg",
]
FINAL_LIBRARY = "xul"

View file

@ -1,5 +1,5 @@
"""
Easy build CLI for Camoufox
Easy build CLI for Omegafox
options:
-h, --help show this help message and exit
@ -13,7 +13,7 @@ options:
Example:
$ python3 multibuild.py --target linux windows macos --arch x86_64 arm64
Since Camoufox is NOT meant to be used as a daily driver, no installers are provided.
Since Omegafox is NOT meant to be used as a daily driver, no installers are provided.
"""
import argparse
@ -49,12 +49,12 @@ class BSYS:
run('make bootstrap')
def build(self):
"""Build the Camoufox source code"""
"""Build the Omegafox source code"""
os.environ['BUILD_TARGET'] = f'{self.target},{self.arch}'
run('make build')
def package(self):
"""Package the Camoufox source code"""
"""Package the Omegafox source code"""
run(f'make package-{self.target} arch={self.arch}')
def update_target(self):
@ -65,12 +65,12 @@ class BSYS:
@property
def assets(self) -> List[str]:
"""Get the list of assets"""
package_pattern = f'camoufox-*-{self.target[:3]}.{self.arch}.zip'
package_pattern = f'omegafox-*-{self.target[:3]}.{self.arch}.zip'
return glob.glob(package_pattern)
@staticmethod
def clean():
"""Clean the Camoufox directory"""
"""Clean the Omegafox directory"""
run('make clean')
@ -91,7 +91,7 @@ def run_build(target, arch):
def main():
parser = argparse.ArgumentParser(description="Easy build CLI for Camoufox")
parser = argparse.ArgumentParser(description="Easy build CLI for Omegafox")
parser.add_argument(
"--target",
choices=AVAILABLE_TARGETS,

View file

@ -28,7 +28,7 @@ index 21063575d7..9e7c9f3e84 100644
FINAL_LIBRARY = "xul"
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/dom/media/webaudio/AudioContext.cpp b/dom/media/webaudio/AudioContext.cpp
index 66184b683b..daf30882ea 100644
@ -70,5 +70,5 @@ index 3ee8c0aa76..c0f1df8cf6 100644
LOCAL_INCLUDES += [".."]
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file

View file

@ -162,7 +162,7 @@ index 6a99703db1..82415eba19 100644
boolean isDarkBackground(Element element);
+ /**
+ * Camoufox debug commands
+ * Omegafox debug commands
+ */
+ undefined camouDebug(DOMString varName);
+
@ -176,27 +176,27 @@ index 6a99703db1..82415eba19 100644
readonly attribute unsigned long aliveUtilityProcesses;
+ /**
+ * Get an int value from Camoufox MaskConfig.
+ * Get an int value from Omegafox MaskConfig.
+ */
+ long camouGetInt(DOMString varName);
+
+ /**
+ * Get a double value from Camoufox MaskConfig.
+ * Get a double value from Omegafox MaskConfig.
+ */
+ double camouGetDouble(DOMString varName, double defaultValue);
+
+ /**
+ * Get a bool value from Camoufox MaskConfig.
+ * Get a bool value from Omegafox MaskConfig.
+ */
+ boolean camouGetBool(DOMString varName, boolean defaultValue);
+
+ /**
+ * Get a string value from Camoufox MaskConfig.
+ * Get a string value from Omegafox MaskConfig.
+ */
+ DOMString camouGetString(DOMString varName);
+
+ /**
+ * Get a list of strings from Camoufox MaskConfig.
+ * Get a list of strings from Omegafox MaskConfig.
+ */
+ sequence<DOMString> camouGetStringList(DOMString varName);
+

View file

@ -6,7 +6,7 @@ index bb0f71dd60..3ad3d84b82 100644
#endif
#endif
+; Camoufox specific files
+; Omegafox specific files
+@RESPATH@/defaults/pref/local-settings.js
+@RESPATH@/distribution/policies.json
+@RESPATH@/omegafox.cfg

View file

@ -8,7 +8,7 @@ index 434167c996..e18a16aee0 100644
)
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/dom/base/Element.cpp b/dom/base/Element.cpp
index 807cb4ec25..3df0e0f70f 100644
@ -235,7 +235,7 @@ index 114402c4a1..55daeabe7a 100644
)
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/dom/base/nsGlobalWindowInner.cpp b/dom/base/nsGlobalWindowInner.cpp
index 3678ebc59c..03a72fe242 100644
@ -461,7 +461,7 @@ index 3a90c93c01..91d673039b 100644
MOCHITEST_MANIFESTS += ["test/mochitest.toml"]
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/dom/workers/WorkerNavigator.cpp b/dom/workers/WorkerNavigator.cpp
index b05e409a84..8e0f7ea657 100644
@ -531,5 +531,5 @@ index c7818826d1..2e2e6526e7 100644
BROWSER_CHROME_MANIFESTS += ["test/browser.toml"]
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file

View file

@ -37,7 +37,7 @@ index 3d99906827..a9d1191688 100644
include("/tools/fuzzing/libfuzzer-config.mozbuild")
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/layout/style/FontFace.cpp b/layout/style/FontFace.cpp
index f1a90334ea..47d3a881ac 100644
@ -155,5 +155,5 @@ index a14ab6a7ac..6e6a727abf 100644
]
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file

View file

@ -79,7 +79,7 @@ index 2d6b6b5fab..0c7ed74c6d 100644
CXXFLAGS += CONFIG["MOZ_GTK3_CFLAGS"]
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/dom/system/NetworkGeolocationProvider.sys.mjs b/dom/system/NetworkGeolocationProvider.sys.mjs
index 7edc62b4a6..19b77aa6b6 100644

View file

@ -7,7 +7,7 @@ index aad9d7054af8..a926d8b6abdc 100644
aDestinationName =
- nsPrintfCString("org.mozilla.%s.%s", aProgram, profileName.get());
+ nsPrintfCString("com.camoufox.%s.%s", aProgram, profileName.get());
+ nsPrintfCString("com.omegafox.%s.%s", aProgram, profileName.get());
if (aDestinationName.Length() > DBUS_MAXIMUM_NAME_LENGTH)
aDestinationName.Truncate(DBUS_MAXIMUM_NAME_LENGTH);
@ -16,7 +16,7 @@ index aad9d7054af8..a926d8b6abdc 100644
// We don't have a valid busName yet - try to create a default one.
aDestinationName =
- nsPrintfCString("org.mozilla.%s.%s", aProgram, "default");
+ nsPrintfCString("com.camoufox.%s.%s", aProgram, "default");
+ nsPrintfCString("com.omegafox.%s.%s", aProgram, "default");
if (!sDBusValidateBusName(aDestinationName.get(), nullptr)) {
// We failed completelly to get a valid bus name - just quit
// to prevent crash at dbus_bus_request_name().
@ -34,7 +34,7 @@ index aad9d7054af8..a926d8b6abdc 100644
nsAutoCString remoteInterfaceName;
- remoteInterfaceName = nsPrintfCString("org.mozilla.%s", appName.get());
+ remoteInterfaceName = nsPrintfCString("com.camoufox.%s", appName.get());
+ remoteInterfaceName = nsPrintfCString("com.omegafox.%s", appName.get());
LOG(" DBus destination: %s\n", destinationName.get());
LOG(" DBus path: %s\n", pathName.get());
@ -47,7 +47,7 @@ index 4afb8381d0bc..bd927334b817 100644
"\"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd\">\n"
"<node>\n"
- " <interface name=\"org.mozilla.%s\">\n"
+ " <interface name=\"com.camoufox.%s\">\n"
+ " <interface name=\"com.omegafox.%s\">\n"
" <method name=\"OpenURL\">\n"
" <arg name=\"url\" direction=\"in\" type=\"ay\"/>\n"
" </method>\n"
@ -56,7 +56,7 @@ index 4afb8381d0bc..bd927334b817 100644
const gchar* aMethodName,
Span<const gchar> aParam) {
- nsPrintfCString ourInterfaceName("org.mozilla.%s", mAppName.get());
+ nsPrintfCString ourInterfaceName("com.camoufox.%s", mAppName.get());
+ nsPrintfCString ourInterfaceName("com.omegafox.%s", mAppName.get());
if ((strcmp("OpenURL", aMethodName) != 0) ||
(strcmp(ourInterfaceName.get(), aInterfaceName) != 0)) {
@ -65,7 +65,7 @@ index 4afb8381d0bc..bd927334b817 100644
void nsDBusRemoteServer::OnBusAcquired(GDBusConnection* aConnection) {
- mPathName = nsPrintfCString("/org/mozilla/%s/Remote", mAppName.get());
+ mPathName = nsPrintfCString("/com/camoufox/%s/Remote", mAppName.get());
+ mPathName = nsPrintfCString("/com/omegafox/%s/Remote", mAppName.get());
static auto sDBusValidatePathName = (bool (*)(const char*, DBusError*))dlsym(
RTLD_DEFAULT, "dbus_validate_path");
if (!sDBusValidatePathName ||
@ -75,7 +75,7 @@ index 4afb8381d0bc..bd927334b817 100644
- nsPrintfCString busName("org.mozilla.%s.%s", mAppName.get(),
- profileName.get());
+ nsPrintfCString busName("com.camoufox.%s.%s", mAppName.get(), profileName.get());
+ nsPrintfCString busName("com.omegafox.%s.%s", mAppName.get(), profileName.get());
if (busName.Length() > DBUS_MAXIMUM_NAME_LENGTH) {
busName.Truncate(DBUS_MAXIMUM_NAME_LENGTH);
}
@ -84,7 +84,7 @@ index 4afb8381d0bc..bd927334b817 100644
// We don't have a valid busName yet - try to create a default one.
if (!sDBusValidateBusName(busName.get(), nullptr)) {
- busName = nsPrintfCString("org.mozilla.%s.%s", mAppName.get(), "default");
+ busName = nsPrintfCString("com.camoufox.%s.%s", mAppName.get(), "default");
+ busName = nsPrintfCString("com.omegafox.%s.%s", mAppName.get(), "default");
if (!sDBusValidateBusName(busName.get(), nullptr)) {
// We failed completelly to get a valid bus name - just quit
// to prevent crash at dbus_bus_request_name().

View file

@ -7,7 +7,7 @@ index d91f463..3c1ba5a 100644
// Note that the client avoids trying to call attach if already attached.
// But just in case, avoid any possible duplicate call to attach.
- if (this.alreadyAttached) {
+ let forceDetach = Services.prefs.getBoolPref("camoufox.debugger.force_detach", false);
+ let forceDetach = Services.prefs.getBoolPref("omegafox.debugger.force_detach", false);
+ if (this.alreadyAttached || forceDetach) {
return;
}
@ -21,7 +21,7 @@ index 3e5d0bc..8260e2b 100644
*/
onConsoleAPILogEvent(message) {
- if (!this.handler) {
+ let disableConsole = Services.prefs.getBoolPref("camoufox.console.logging_disabled", false);
+ let disableConsole = Services.prefs.getBoolPref("omegafox.console.logging_disabled", false);
+ if (!this.handler || disableConsole) {
return;
}

View file

@ -5,19 +5,19 @@
getter_AddRefs(localDir));
if (NS_SUCCEEDED(rv)) {
- rv = localDir->AppendNative("Mozilla"_ns);
+ rv = localDir->AppendNative("Camoufox"_ns);
+ rv = localDir->AppendNative("Omegafox"_ns);
}
# else
constexpr auto dirname =
# ifdef HAVE_USR_LIB64_DIR
- "/usr/lib64/mozilla"_ns
+ "/usr/lib64/camoufox"_ns
+ "/usr/lib64/omegafox"_ns
# elif defined(__OpenBSD__) || defined(__FreeBSD__)
- "/usr/local/lib/mozilla"_ns
+ "/usr/local/lib/camoufox"_ns
+ "/usr/local/lib/omegafox"_ns
# else
- "/usr/lib/mozilla"_ns
+ "/usr/lib/camoufox"_ns
+ "/usr/lib/omegafox"_ns
# endif
;
rv = NS_NewNativeLocalFile(dirname, false, getter_AddRefs(localDir));
@ -26,10 +26,10 @@
NS_ENSURE_SUCCESS(rv, rv);
# if defined(XP_MACOSX)
- rv = file->AppendNative("Mozilla"_ns);
+ rv = file->AppendNative("Camoufox"_ns);
+ rv = file->AppendNative("Omegafox"_ns);
# else // defined(XP_MACOSX)
- rv = file->AppendNative(".mozilla"_ns);
+ rv = file->AppendNative(".camoufox"_ns);
+ rv = file->AppendNative(".omegafox"_ns);
# endif // defined(XP_MACOSX)
}
#endif // defined(XP_UNIX) || defined(XP_MACOSX)
@ -38,10 +38,10 @@
# ifdef ENABLE_SYSTEM_EXTENSION_DIRS
# if defined(__OpenBSD__) || defined(__FreeBSD__)
- static const char* const sysLExtDir = "/usr/local/share/mozilla/extensions";
+ static const char* const sysLExtDir = "/usr/local/share/camoufox/extensions";
+ static const char* const sysLExtDir = "/usr/local/share/omegafox/extensions";
# else
- static const char* const sysLExtDir = "/usr/share/mozilla/extensions";
+ static const char* const sysLExtDir = "/usr/share/camoufox/extensions";
+ static const char* const sysLExtDir = "/usr/share/omegafox/extensions";
# endif
rv = NS_NewNativeLocalFile(nsDependentCString(sysLExtDir), false,
getter_AddRefs(file));
@ -50,7 +50,7 @@
return NS_ERROR_FAILURE;
}
- } else if (NS_FAILED(localDir->AppendNative("Mozilla"_ns))) {
+ } else if (NS_FAILED(localDir->AppendNative("Camoufox"_ns))) {
+ } else if (NS_FAILED(localDir->AppendNative("Omegafox"_ns))) {
return NS_ERROR_FAILURE;
}
@ -59,7 +59,7 @@
#if defined(XP_MACOSX) || defined(XP_WIN)
- static const char* const sXR = "Mozilla";
+ static const char* const sXR = "Camoufox";
+ static const char* const sXR = "Omegafox";
rv = aFile->AppendNative(nsDependentCString(sXR));
NS_ENSURE_SUCCESS(rv, rv);
@ -68,7 +68,7 @@
#elif defined(XP_UNIX)
- static const char* const sXR = ".mozilla";
+ static const char* const sXR = ".camoufox";
+ static const char* const sXR = ".omegafox";
rv = aFile->AppendNative(nsDependentCString(sXR));
NS_ENSURE_SUCCESS(rv, rv);

View file

@ -76,7 +76,7 @@ index 9a043518cf..a8d3733212 100644
+}
+
+const char* Locale::GetDefaultLocale() {
+ // In Camoufox, GetDefaultLocale is defined outside the header
+ // In Omegafox, GetDefaultLocale is defined outside the header
+ // to access MaskConfig.
+ if (auto value = GetCamouLocale())
+ return value;

View file

@ -8,7 +8,7 @@ index b090a56d88..9fe4a5e1e8 100644
include("/tools/fuzzing/libfuzzer-config.mozbuild")
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/netwerk/protocol/http/nsHttpHandler.cpp b/netwerk/protocol/http/nsHttpHandler.cpp
index d0aebdf965..01472ec205 100644

View file

@ -25,7 +25,7 @@ index a2b3e60fe5..faa0c113bc 100644
CXXFLAGS += CONFIG["MOZ_PANGO_CFLAGS"]
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/gfx/src/nsDeviceContext.cpp b/gfx/src/nsDeviceContext.cpp
index 7a4fa8d48f..408b754d92 100644

View file

@ -8,7 +8,7 @@ index b0af60b999..28c221136e 100644
Library("intlcomponents")
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file
diff --git a/intl/components/src/TimeZone.cpp b/intl/components/src/TimeZone.cpp
index 5b09dfdcc5..98a78b33cc 100644

View file

@ -8,7 +8,7 @@ index 2cf19982b2..dcdcdb5cbf 100644
]
+
+# DOM Mask
+LOCAL_INCLUDES += ['/camoucfg']
+LOCAL_INCLUDES += ['/omegacfg']
\ No newline at end of file
diff --git a/dom/media/webspeech/synth/nsSynthVoiceRegistry.cpp b/dom/media/webspeech/synth/nsSynthVoiceRegistry.cpp
index e5a1353d6b..4a4a5b080b 100644

View file

@ -390,5 +390,5 @@ index 3a533d36d1..41d74d9b3f 100644
include("/tools/fuzzing/libfuzzer-config.mozbuild")
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file

View file

@ -312,5 +312,5 @@ index 925190505a..878853f0f0 100644
FINAL_LIBRARY = "xul"
+
+# DOM Mask
+LOCAL_INCLUDES += ["/camoucfg"]
+LOCAL_INCLUDES += ["/omegacfg"]
\ No newline at end of file

View file

@ -25,12 +25,12 @@ index 54d6b43fe126..116410bb89d9 100644
endif
PROGRAMS_DEST = $(DIST)/bin
diff --git a/browser/app/firefox.exe.manifest b/browser/app/camoufox.manifest
diff --git a/browser/app/firefox.exe.manifest b/browser/app/omegafox.manifest
similarity index 96%
rename from browser/app/firefox.exe.manifest
rename to browser/app/camoufox.exe.manifest
rename to browser/app/omegafox.exe.manifest
--- a/browser/app/firefox.exe.manifest
+++ b/browser/app/camoufox.exe.manifest
+++ b/browser/app/omegafox.exe.manifest
@@ -3,10 +3,10 @@
<assemblyIdentity
version="1.0.0.0"

View file

@ -1,7 +1,7 @@
#!/usr/bin/env python3
"""
Common functions used across the Camoufox build system.
Common functions used across the Omegafox build system.
Not meant to be called directly.
"""
@ -43,14 +43,14 @@ def get_options():
def find_src_dir(root_dir='.', version=None, release=None):
"""Get the source directory"""
if version and release:
name = os.path.join(root_dir, f'camoufox-{version}-{release}')
name = os.path.join(root_dir, f'omegafox-{version}-{release}')
assert os.path.exists(name), f'{name} does not exist.'
return name
folders = os.listdir(root_dir)
for folder in folders:
if os.path.isdir(folder) and folder.startswith('camoufox-'):
if os.path.isdir(folder) and folder.startswith('omegafox-'):
return os.path.join(root_dir, folder)
raise FileNotFoundError('No camoufox-* folder found')
raise FileNotFoundError('No omegafox-* folder found')
def get_moz_target(target, arch):

View file

@ -1,7 +1,7 @@
#!/usr/bin/env python3
"""
GUI for managing Camoufox patches.
GUI for managing Omegafox patches.
"""
import os
import re
@ -11,16 +11,16 @@ import easygui
from _mixin import find_src_dir, is_bootstrap_patch, list_patches, patch, run, temp_cd
def into_camoufox_dir():
"""Cd to the camoufox-* folder"""
def into_omegafox_dir():
"""Cd to the omegafox-* folder"""
this_script = os.path.dirname(os.path.abspath(__file__))
# Go one directory up from the current script path
os.chdir(os.path.dirname(this_script))
os.chdir(find_src_dir('.', version=sys.argv[1], release=sys.argv[2]))
def reset_camoufox():
"""Reset the Camoufox source"""
def reset_omegafox():
"""Reset the Omegafox source"""
with temp_cd('..'):
run('make revert')
run('touch _READY')
@ -68,7 +68,7 @@ def open_patch_workspace(selected_patch, stop_at_patch=False):
Resets a workspace for editing a patch.
Process:
1. Resets Camoufox
1. Resets Omegafox
2. Patches all except the selected patch
3. Sets checkpoint
4. Reruns the selected patch, but reads rejects similar to "Find broken patches"
@ -77,7 +77,7 @@ def open_patch_workspace(selected_patch, stop_at_patch=False):
patch_files = list_patches()
# Reset workspace
reset_camoufox()
reset_omegafox()
skipped_patches = []
applied_patches = []
@ -186,20 +186,20 @@ def handle_choice(choice):
"""Handle UI choice"""
match choice:
case "Reset workspace":
reset_camoufox()
reset_omegafox()
easygui.msgbox(
"Reset. All patches & changes have been removed.",
"Reset Complete",
)
case "Create new patch":
# Reset camoufox, apply all patches, then create a checkpoint
reset_camoufox()
# Reset omegafox, apply all patches, then create a checkpoint
reset_omegafox()
with temp_cd('..'):
run('make dir')
run('make checkpoint')
easygui.msgbox(
"Created new patch workspace. You can test Camoufox with 'make run'.\n\n"
"Created new patch workspace. You can test Omegafox with 'make run'.\n\n"
"When you are finished, write your workspace back to a new patch.",
"New Patch Workspace",
)
@ -254,7 +254,7 @@ def handle_choice(choice):
easygui.msgbox("Unpatching completed.", "Unpatching Complete")
case "Find broken patches (resets workspace)":
reset_camoufox()
reset_omegafox()
get_all = None
@ -356,7 +356,7 @@ def handle_choice(choice):
if __name__ == "__main__":
into_camoufox_dir()
into_omegafox_dir()
while choice := easygui.choicebox("Select an option:", "Camoufox Dev Tools", choices):
while choice := easygui.choicebox("Select an option:", "Omegafox Dev Tools", choices):
handle_choice(choice)

View file

@ -5,9 +5,9 @@ add_includes_to_package() {
echo "Adding includes to package: $1"
temp_dir=$(mktemp -d)
7z x "$1" "-o$temp_dir"
if [ -d "$temp_dir/camoufox" ]; then
mv "$temp_dir/camoufox"/* "$temp_dir/"
rmdir "$temp_dir/camoufox"
if [ -d "$temp_dir/omegafox" ]; then
mv "$temp_dir/omegafox"/* "$temp_dir/"
rmdir "$temp_dir/omegafox"
fi
for include in "${@:2}"; do
if [ -e "$include" ]; then

View file

@ -31,27 +31,27 @@ def add_includes_to_package(package_file, includes, fonts, new_file, target):
)
if target == 'macos':
# Move Camoufox/Camoufox.app -> Camoufox.app
nightly_dir = os.path.join(temp_dir, 'Camoufox')
# Move Omegafox/Omegafox.app -> Omegafox.app
nightly_dir = os.path.join(temp_dir, 'Omegafox')
shutil.move(
os.path.join(nightly_dir, 'Camoufox.app'), os.path.join(temp_dir, 'Camoufox.app')
os.path.join(nightly_dir, 'Omegafox.app'), os.path.join(temp_dir, 'Omegafox.app')
)
# Remove old app dir and all content in it
shutil.rmtree(nightly_dir)
else:
# Move contents out of camoufox folder if it exists
old_camoufox_dir = os.path.join(temp_dir, 'camoufox')
camoufox_dir = os.path.join(temp_dir, 'camoufox-folder')
if os.path.exists(old_camoufox_dir):
# Rename camoufox_dir
os.rename(old_camoufox_dir, camoufox_dir)
for item in os.listdir(camoufox_dir):
shutil.move(os.path.join(camoufox_dir, item), temp_dir)
os.rmdir(camoufox_dir)
# Move contents out of omegafox folder if it exists
old_omegafox_dir = os.path.join(temp_dir, 'omegafox')
omegafox_dir = os.path.join(temp_dir, 'omegafox-folder')
if os.path.exists(old_omegafox_dir):
# Rename omegafox_dir
os.rename(old_omegafox_dir, omegafox_dir)
for item in os.listdir(omegafox_dir):
shutil.move(os.path.join(omegafox_dir, item), temp_dir)
os.rmdir(omegafox_dir)
# Create target_dir
if target == 'macos':
target_dir = os.path.join(temp_dir, 'Camoufox.app', 'Contents', 'Resources')
target_dir = os.path.join(temp_dir, 'Omegafox.app', 'Contents', 'Resources')
else:
target_dir = temp_dir
@ -98,14 +98,14 @@ def add_includes_to_package(package_file, includes, fonts, new_file, target):
def get_args():
"""Get CLI parameters"""
parser = argparse.ArgumentParser(
description='Package Camoufox for different operating systems.'
description='Package Omegafox for different operating systems.'
)
parser.add_argument('os', choices=['linux', 'macos', 'windows'], help='Target operating system')
parser.add_argument(
'--includes', nargs='+', help='List of files or directories to include in the package'
)
parser.add_argument('--version', required=True, help='Camoufox version')
parser.add_argument('--release', required=True, help='Camoufox release number')
parser.add_argument('--version', required=True, help='Omegafox version')
parser.add_argument('--release', required=True, help='Omegafox release number')
parser.add_argument(
'--arch', choices=['x86_64', 'i686', 'arm64'], help='Architecture for Windows build'
)
@ -129,7 +129,7 @@ def main():
run('./mach package')
# Find package files
search_path = os.path.abspath(
f'obj-{moz_target}/dist/camoufox-{args.version}-{args.release}.*.{file_ext}'
f'obj-{moz_target}/dist/omegafox-{args.version}-{args.release}.*.{file_ext}'
)
# Copy package files
@ -146,7 +146,7 @@ def main():
sys.exit(1)
# Find the package file
package_pattern = f'camoufox-{args.version}-{args.release}.en-US.*.{file_ext}'
package_pattern = f'omegafox-{args.version}-{args.release}.en-US.*.{file_ext}'
package_files = glob.glob(package_pattern)
if not package_files:
print(f"Error: No package file found matching pattern: {package_pattern}")
@ -154,7 +154,7 @@ def main():
package_file = package_files[0]
# Add includes to the package
new_name = f'camoufox-{args.version}-{args.release}-{args.os[:3]}.{args.arch}.zip'
new_name = f'omegafox-{args.version}-{args.release}-{args.os[:3]}.{args.arch}.zip'
add_includes_to_package(
package_file=package_file,
includes=args.includes,

View file

@ -1,7 +1,7 @@
#!/usr/bin/env python3
"""
The script that patches the Firefox source into the Camoufox source.
The script that patches the Firefox source into the Omegafox source.
Based on LibreWolf's patch script:
https://gitlab.com/librewolf-community/browser/source/-/blob/main/scripts/librewolf-patches.py
@ -34,12 +34,12 @@ Main patcher functions
@dataclass
class Patcher:
"""Patch and prepare the Camoufox source"""
"""Patch and prepare the Omegafox source"""
moz_target: str
target: str
def camoufox_patches(self):
def omegafox_patches(self):
"""
Apply all patches
"""
@ -122,7 +122,7 @@ Preparation
def extract_args():
"""Get version and release from args"""
if len(args) != 2:
sys.stderr.write('error: please specify version and release of camoufox source')
sys.stderr.write('error: please specify version and release of omegafox source')
sys.exit(1)
return args[0], args[1]
@ -156,12 +156,12 @@ if __name__ == "__main__":
_update_rustup(TARGET)
# Check if the folder exists
if not os.path.exists(f'camoufox-{VERSION}-{RELEASE}/configure.py'):
if not os.path.exists(f'omegafox-{VERSION}-{RELEASE}/configure.py'):
sys.stderr.write('error: folder doesn\'t look like a Firefox folder.')
sys.exit(1)
# Apply the patches
patcher = Patcher(MOZ_TARGET, TARGET)
patcher.camoufox_patches()
patcher.omegafox_patches()
sys.exit(0) # ensure 0 exit code