Эх сурвалжийг харах

Initialize SCRIPT_LTO based on LTO input

Added logic to initialize SCRIPT_LTO based on LTO value.
jimsterino98 2 долоо хоног өмнө
parent
commit
58e6f29241

+ 8 - 0
.github/actions/build/action.yml

@@ -57,6 +57,14 @@ runs:
     run: |
     run: |
      set -e
      set -e
      set -x
      set -x
+     # 1. Initialize variables as empty (clears them out for "default")
+     SCRIPT_LTO=""
+
+     # 2. Only populate if explicit modifications are requested
+     if [[ "$LTO" == "thin" || "$LTO" == "full" ]]; then
+       SCRIPT_LTO="LTO=$LTO"
+     fi
+     
      cd "$CONFIG"
      cd "$CONFIG"
      if [[ -f build_kernel_GKI.sh ]]; then
      if [[ -f build_kernel_GKI.sh ]]; then
       chmod +x build_kernel_GKI.sh
       chmod +x build_kernel_GKI.sh