@@ -205,7 +205,8 @@ set CUDA_ARCH_NAME=All
205
205
206
206
call :cmake || goto cmake_error
207
207
call :build || goto build_error
208
- call :zip_file || goto zip_file_error
208
+ call :zip_cc_file || goto zip_cc_file_error
209
+ call :zip_c_file || goto zip_c_file_error
209
210
goto :success
210
211
211
212
rem "Other configurations are added here"
@@ -671,7 +672,7 @@ goto:eof
671
672
exit /b 1
672
673
673
674
rem ---------------------------------------------------------------------------------------------
674
- :zip_file
675
+ :zip_cc_file
675
676
tree /F %cd% \paddle_inference_install_dir\paddle
676
677
if exist paddle_inference.zip del paddle_inference.zip
677
678
python -c " import shutil;shutil.make_archive('paddle_inference', 'zip', root_dir='paddle_inference_install_dir')"
@@ -683,10 +684,27 @@ for /F %%i in ("%libsize%") do (
683
684
)
684
685
goto :eof
685
686
686
- :zip_file_error
687
+ :zip_cc_file_error
687
688
echo Tar inference library failed!
688
689
exit /b 1
689
690
691
+ rem ---------------------------------------------------------------------------------------------
692
+ :zip_c_file
693
+ tree /F %cd% \paddle_inference_c_install_dir\paddle
694
+ if exist paddle_inference_c.zip del paddle_inference_c.zip
695
+ python -c " import shutil;shutil.make_archive('paddle_inference_c', 'zip', root_dir='paddle_inference_c_install_dir')"
696
+ %cache_dir% \tools\busybox64.exe du -h -k paddle_inference_c.zip > lib_size.txt
697
+ set /p libsize = < lib_size.txt
698
+ for /F %%i in (" %libsize% " ) do (
699
+ set /a libsize_m = %%i / 1024
700
+ echo " Windows Paddle_Inference CAPI ZIP Size: !libsize_m! M"
701
+ )
702
+ goto :eof
703
+
704
+ :zip_c_file_error
705
+ echo Tar inference capi library failed!
706
+ exit /b 1
707
+
690
708
:timestamp
691
709
setlocal enabledelayedexpansion
692
710
@ ECHO OFF
0 commit comments