]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/C/BrotliCompress/BrotliCompress.bat
BaseTools: resolve initialization order errors in VfrFormPkg.h
[mirror_edk2.git] / BaseTools / Source / C / BrotliCompress / BrotliCompress.bat
index b291ff07f89e6b252fc8df8441c017f1e370aaad..b1b4985816755d4e8a406a288c9234754c676f5b 100644 (file)
 \r
 set QLT=-q 9\r
 set INPUTFLAG=0\r
+set ARGS=\r
 \r
 :Begin\r
 if "%1"=="" goto End\r
 \r
 if "%1"=="-d" (\r
   set INPUTFLAG=1\r
+  set ARGS=%ARGS% %1\r
+  shift\r
+  goto Begin\r
 )\r
 \r
 if "%1"=="-e" (\r
@@ -51,17 +55,15 @@ if "%1"=="-q" (
   goto Begin\r
 )\r
 \r
-if %INPUTFLAG%==1 (\r
- if "%2"=="" (\r
-    set ARGS=%ARGS% %QLT% -i %1\r
-    goto End\r
-  )\r
+if %INPUTFLAG% == 1 (\r
+  set ARGS=%ARGS% -i %1\r
+  set INPUTFLAG=0\r
+) else (\r
+  set ARGS=%ARGS% %1\r
 )\r
-\r
-set ARGS=%ARGS% %1\r
 shift\r
 goto Begin\r
 \r
 :End\r
-Brotli %ARGS%\r
+Brotli %ARGS% %QLT%\r
 @echo on\r