fixup previous by putting back the correct pathnames for ungoogled-chromium

This commit is contained in:
robert 2023-01-29 17:31:39 +00:00
parent 507baade66
commit f48f8d4057
3 changed files with 23 additions and 23 deletions

View File

@ -10,7 +10,7 @@ COMMENT= Chromium browser sans integration with Google
V= 109.0.5414.119
UGV= ${V}-1
REVISION= 2
REVISION= 3
DISTNAME= ungoogled-chromium-${V}

View File

@ -65,14 +65,14 @@ Index: sandbox/policy/freebsd/sandbox_freebsd.cc
+
+#define MAXTOKENS 3
+
+#define _UNVEIL_MAIN "/etc/chromium/unveil.main";
+#define _UNVEIL_RENDERER "/etc/chromium/unveil.renderer";
+#define _UNVEIL_GPU "/etc/chromium/unveil.gpu";
+#define _UNVEIL_PLUGIN "/etc/chromium/unveil.plugin";
+#define _UNVEIL_UTILITY "/etc/chromium/unveil.utility";
+#define _UNVEIL_UTILITY_NETWORK "/etc/chromium/unveil.utility_network";
+#define _UNVEIL_UTILITY_AUDIO "/etc/chromium/unveil.utility_audio";
+#define _UNVEIL_UTILITY_VIDEO "/etc/chromium/unveil.utility_video";
+#define _UNVEIL_MAIN "/etc/ungoogled-chromium/unveil.main";
+#define _UNVEIL_RENDERER "/etc/ungoogled-chromium/unveil.renderer";
+#define _UNVEIL_GPU "/etc/ungoogled-chromium/unveil.gpu";
+#define _UNVEIL_PLUGIN "/etc/ungoogled-chromium/unveil.plugin";
+#define _UNVEIL_UTILITY "/etc/ungoogled-chromium/unveil.utility";
+#define _UNVEIL_UTILITY_NETWORK "/etc/ungoogled-chromium/unveil.utility_network";
+#define _UNVEIL_UTILITY_AUDIO "/etc/ungoogled-chromium/unveil.utility_audio";
+#define _UNVEIL_UTILITY_VIDEO "/etc/ungoogled-chromium/unveil.utility_video";
+
+namespace sandbox {
+namespace policy {
@ -129,7 +129,7 @@ Index: sandbox/policy/freebsd/sandbox_freebsd.cc
+ base::PathService::Get(base::DIR_CACHE, &cache_directory);
+ base::PathService::Get(base::DIR_HOME, &local_directory);
+
+ cache_directory = cache_directory.AppendASCII("chromium");
+ cache_directory = cache_directory.AppendASCII("ungoogled-chromium");
+ local_directory = local_directory.AppendASCII(".local").AppendASCII("share").AppendASCII("applications");
+
+ if (!base::CreateDirectory(cache_directory)) {

View File

@ -68,14 +68,14 @@ Index: sandbox/policy/openbsd/sandbox_openbsd.cc
+
+#define MAXTOKENS 3
+
+#define _UNVEIL_MAIN "/etc/chromium/unveil.main";
+#define _UNVEIL_RENDERER "/etc/chromium/unveil.renderer";
+#define _UNVEIL_GPU "/etc/chromium/unveil.gpu";
+#define _UNVEIL_PLUGIN "/etc/chromium/unveil.plugin";
+#define _UNVEIL_UTILITY "/etc/chromium/unveil.utility";
+#define _UNVEIL_UTILITY_NETWORK "/etc/chromium/unveil.utility_network";
+#define _UNVEIL_UTILITY_AUDIO "/etc/chromium/unveil.utility_audio";
+#define _UNVEIL_UTILITY_VIDEO "/etc/chromium/unveil.utility_video";
+#define _UNVEIL_MAIN "/etc/ungoogled-chromium/unveil.main";
+#define _UNVEIL_RENDERER "/etc/ungoogled-chromium/unveil.renderer";
+#define _UNVEIL_GPU "/etc/ungoogled-chromium/unveil.gpu";
+#define _UNVEIL_PLUGIN "/etc/ungoogled-chromium/unveil.plugin";
+#define _UNVEIL_UTILITY "/etc/ungoogled-chromium/unveil.utility";
+#define _UNVEIL_UTILITY_NETWORK "/etc/ungoogled-chromium/unveil.utility_network";
+#define _UNVEIL_UTILITY_AUDIO "/etc/ungoogled-chromium/unveil.utility_audio";
+#define _UNVEIL_UTILITY_VIDEO "/etc/ungoogled-chromium/unveil.utility_video";
+
+namespace sandbox {
+namespace policy {
@ -137,7 +137,7 @@ Index: sandbox/policy/openbsd/sandbox_openbsd.cc
+ base::PathService::Get(base::DIR_CACHE, &cache_directory);
+ base::PathService::Get(base::DIR_HOME, &local_directory);
+
+ cache_directory = cache_directory.AppendASCII("chromium");
+ cache_directory = cache_directory.AppendASCII("ungoogled-chromium");
+ local_directory = local_directory.AppendASCII(".local").AppendASCII("share").AppendASCII("applications");
+
+ if (!base::CreateDirectory(cache_directory)) {
@ -313,7 +313,7 @@ Index: sandbox/policy/openbsd/sandbox_openbsd.cc
+ if (process_type.empty()) {
+ // XXX use a file for listing pledges of the main process for now
+ // XXX not having the file is not a fatal error
+ SetPledge(NULL, "/etc/chromium/pledge.main");
+ SetPledge(NULL, "/etc/ungoogled-chromium/pledge.main");
+ } else if (process_type == switches::kRendererProcess) {
+ // prot_exec needed by v8
+ // flock needed by sqlite3 locking
@ -325,11 +325,11 @@ Index: sandbox/policy/openbsd/sandbox_openbsd.cc
+ SetPledge("stdio rpath prot_exec recvfd sendfd", NULL);
+ } else if (process_type == switches::kUtilityProcess) {
+ if (sandbox_type == sandbox::mojom::Sandbox::kAudio)
+ SetPledge(NULL, "/etc/chromium/pledge.utility_audio");
+ SetPledge(NULL, "/etc/ungoogled-chromium/pledge.utility_audio");
+ else if (sandbox_type == sandbox::mojom::Sandbox::kNetwork)
+ SetPledge(NULL, "/etc/chromium/pledge.utility_network");
+ SetPledge(NULL, "/etc/ungoogled-chromium/pledge.utility_network");
+ else if (sandbox_type == sandbox::mojom::Sandbox::kVideoCapture)
+ SetPledge(NULL, "/etc/chromium/pledge.utility_video");
+ SetPledge(NULL, "/etc/ungoogled-chromium/pledge.utility_video");
+ else
+ SetPledge("stdio rpath cpath wpath fattr flock sendfd recvfd prot_exec", NULL);
+ } else {