diff --git a/setup/build_linux b/setup/build_linux index 37d0762d..ec6b4a9f 100755 --- a/setup/build_linux +++ b/setup/build_linux @@ -80,6 +80,10 @@ function copy_live_env() { mkdir -p "$PROFILE_DIR/airootfs/usr/local/bin" rsync -aI "$ROOT_DIR/scripts/" "$PROFILE_DIR/airootfs/usr/local/bin/" + # Pre-compile Python scripts + unset PYTHONPYCACHEPREFIX + python -m compileall "$PROFILE_DIR/airootfs/usr/local/bin/" + # Update profiledef.sh to set proper permissions for executable files for _file in $(find "$PROFILE_DIR/airootfs" -executable -type f | sed "s%$PROFILE_DIR/airootfs%%" | sort); do sed -i "\$i\ [\"$_file\"]=\"0:0:755\"" "$PROFILE_DIR/profiledef.sh"