diff --git a/Patches/Common/android_packages_apps_Trebuchet/default_workspace/default_workspace_4x4.xml b/Patches/Common/android_packages_apps_Trebuchet/default_workspace/default_workspace_4x4.xml
index bf111ea8..fca97b26 100644
--- a/Patches/Common/android_packages_apps_Trebuchet/default_workspace/default_workspace_4x4.xml
+++ b/Patches/Common/android_packages_apps_Trebuchet/default_workspace/default_workspace_4x4.xml
@@ -57,7 +57,7 @@
launcher:packageName="org.lineageos.snap"
launcher:className="com.android.camera.CameraLauncher" />
> rootdir/etc/hosts; fi; #Merge in our HOSTS file
+if [ "$DOS_HOSTS_BLOCKING" = true ]; then cat "$DOS_HOSTS_FILE" >> rootdir/etc/hosts; fi; #Merge in our HOSTS file
git revert 0217dddeb5c16903c13ff6c75213619b79ea622b d7aa1231b6a0631f506c0c23816f2cd81645b15f; #Always update recovery XXX: This doesn't seem to work
patch -p1 < "$DOS_PATCHES/android_system_core/0001-Harden_Mounts.patch"; #Harden mounts with nodev/noexec/nosuid (CopperheadOS-13.0)
diff --git a/Scripts/LineageOS-15.1/Patch.sh b/Scripts/LineageOS-15.1/Patch.sh
index 7d994a46..1a30ab74 100755
--- a/Scripts/LineageOS-15.1/Patch.sh
+++ b/Scripts/LineageOS-15.1/Patch.sh
@@ -40,8 +40,7 @@
#START OF PREPRATION
#
#Download some (non-executable) out-of-tree files for use later on
-mkdir /tmp/ar;
-cd /tmp/ar;
+cd "$DOS_TMP_DIR";
if [ "$DOS_HOSTS_BLOCKING" = true ]; then wget "$DOS_HOSTS_BLOCKING_LIST" -N; fi;
cd "$DOS_BUILD_BASE";
@@ -180,7 +179,7 @@ enterAndClear "packages/services/Telephony";
if [ "$DOS_NON_COMMERCIAL_USE_PATCHES" = true ]; then patch -p1 < "$DOS_PATCHES/android_packages_services_Telephony/Copperhead/0001-LTE_Only.patch"; fi; #LTE only preferred network mode choice (Copperhead CC BY-NC-SA)
enterAndClear "system/core";
-cat /tmp/ar/hosts >> rootdir/etc/hosts; #Merge in our HOSTS file
+if [ "$DOS_HOSTS_BLOCKING" = true ]; then cat "$DOS_HOSTS_FILE" >> rootdir/etc/hosts; fi; #Merge in our HOSTS file
git revert a6a4ce8e9a6d63014047a447c6bb3ac1fa90b3f4; #Always update recovery
patch -p1 < "$DOS_PATCHES/android_system_core/0001-Harden_Mounts.patch"; #Harden mounts with nodev/noexec/nosuid (CopperheadOS-13.0)
if [ "$DOS_NON_COMMERCIAL_USE_PATCHES" = true ]; then patch -p1 < "$DOS_PATCHES/android_system_core/Copperhead/0002-Deny_USB.patch"; fi; #Deny USB support (Copperhead CC BY-NC-SA)
diff --git a/Scripts/init.sh b/Scripts/init.sh
index 9e64ac45..53de3360 100644
--- a/Scripts/init.sh
+++ b/Scripts/init.sh
@@ -20,7 +20,7 @@
#START OF USER CONFIGURABLE OPTIONS
export DOS_WORKSPACE_ROOT="/mnt/Drive-3/"; #XXX: THIS MUST BE CORRECT TO BUILD!
export DOS_SIGNING_KEYS=$DOS_WORKSPACE_ROOT"Signing_Keys";
-#export DOS_PATCHER_BINARY="";
+#export DOS_BINARY_PATCHER="";
export ANDROID_HOME="/home/$USER/Android/Sdk";
export DOS_DEBLOBBER_REMOVE_ACCESSORIES=true; #Set false to allow use of external accessories
@@ -36,7 +36,7 @@ export DOS_MALWARE_SCAN_ENABLED=true; #Set true to perform a fast scan on patchW
export DOS_MALWARE_SCAN_SETTING="quick"; #buildAll() scan speed. Options: quick, extra, slow, full
export DOS_MICROG_INCLUDED="NLP"; #Determines inclusion of microG. Options: NONE, NLP, FULL
export DOS_HOSTS_BLOCKING=true; #Switch to false to prevent inclusion of our HOSTS file
-export DOS_HOSTS_BLOCKING_LIST="https://spotco.us/hosts"; #Must be in the format "127.0.0.0 bad.domain.tld". XXX: /hosts is built from non-commercial use files, switch to /hsc for release
+export DOS_HOSTS_BLOCKING_LIST="https://divestos.xyz/hosts"; #Must be in the format "127.0.0.1 bad.domain.tld"
export DOS_OVERCLOCKS_ENABLED=true; #Switch to false to disable overclocks
export DOS_STRONG_ENCRYPTION_ENABLED=false; #Switch to true to enable AES-256bit encryption XXX: THIS WILL **DESTROY** EXISTING INSTALLS!
export DOS_NON_COMMERCIAL_USE_PATCHES=false; #Switch to false to prevent inclusion of non-commercial use patches
@@ -73,6 +73,10 @@ if [ ! -d "$DOS_BUILD_BASE" ]; then
return 1;
fi;
+export DOS_TMP_DIR="/tmp/dos_tmp";
+mkdir "$DOS_TMP_DIR";
+export DOS_HOSTS_FILE="$DOS_TMP_DIR/hosts";
+
export DOS_PREBUILT_APPS=$DOS_WORKSPACE_ROOT"PrebuiltApps/";
export DOS_PATCHES_COMMON=$DOS_WORKSPACE_ROOT"Patches/Common/";
export DOS_PATCHES=$DOS_WORKSPACE_ROOT"Patches/$BUILD_WORKING_DIR/";