diff options
author | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2024-07-06 13:56:29 +0200 |
---|---|---|
committer | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2024-07-06 13:56:29 +0200 |
commit | d8369c266f23fd7054a3a1e3d071cb5fadc27ecd (patch) | |
tree | 8843f8e2937eae8c918373110399d7c147bf507d /src/Build/build_veracrypt_linux_no_sse2.sh | |
parent | 519b787914ebfc5cf31c2eab384b5f075a47138e (diff) | |
download | VeraCrypt-d8369c266f23fd7054a3a1e3d071cb5fadc27ecd.tar.gz VeraCrypt-d8369c266f23fd7054a3a1e3d071cb5fadc27ecd.zip |
Linux: optimize Github workflow by caching wxBuildConsole and wxBuildGUI folders
We also modify build script to detect the presence of wxBuildConsole and wxBuildGUI folders and reuse them
Diffstat (limited to 'src/Build/build_veracrypt_linux_no_sse2.sh')
-rwxr-xr-x | src/Build/build_veracrypt_linux_no_sse2.sh | 26 |
1 files changed, 18 insertions, 8 deletions
diff --git a/src/Build/build_veracrypt_linux_no_sse2.sh b/src/Build/build_veracrypt_linux_no_sse2.sh index 7162ecd4..e5e46252 100755 --- a/src/Build/build_veracrypt_linux_no_sse2.sh +++ b/src/Build/build_veracrypt_linux_no_sse2.sh @@ -43,17 +43,27 @@ echo "Building GUI version of VeraCrypt" # this will be the temporary wxWidgets directory export WX_BUILD_DIR=$PARENTDIR/wxBuildGuiNoSSE2 -make WXSTATIC=1 NOSSE2=1 wxbuild && make WXSTATIC=1 NOSSE2=1 clean && make WXSTATIC=1 NOSSE2=1 && make WXSTATIC=1 NOSSE2=1 package - -# Uncomment below and comment line above to reuse existing wxWidgets build -# make WXSTATIC=1 NOSSE2=1 clean && make WXSTATIC=1 NOSSE2=1 && make WXSTATIC=1 NOSSE2=1 package +# Check if wx-config exists in WX_BUILD_DIR +if [ -L "${WX_BUILD_DIR}/wx-config" ]; then + echo "wx-config already exists in ${WX_BUILD_DIR}. Skipping wxbuild." +else + make WXSTATIC=1 NOSSE2=1 wxbuild || exit 1 +fi +make WXSTATIC=1 NOSSE2=1 clean || exit 1 +make WXSTATIC=1 NOSSE2=1 || exit 1 +make WXSTATIC=1 NOSSE2=1 package || exit 1 echo "Building console version of VeraCrypt" # this will be the temporary wxWidgets directory export WX_BUILD_DIR=$PARENTDIR/wxBuildConsoleNoSSE2 -make WXSTATIC=1 NOGUI=1 NOSSE2=1 wxbuild && make WXSTATIC=1 NOGUI=1 NOSSE2=1 clean && make WXSTATIC=1 NOGUI=1 NOSSE2=1 && make WXSTATIC=1 NOGUI=1 NOSSE2=1 package - -# Uncomment below and comment line above to reuse existing wxWidgets build -# make WXSTATIC=1 NOGUI=1 NOSSE2=1 clean && make WXSTATIC=1 NOGUI=1 NOSSE2=1 && make WXSTATIC=1 NOGUI=1 NOSSE2=1 package +# Check if wx-config exists in WX_BUILD_DIR +if [ -L "${WX_BUILD_DIR}/wx-config" ]; then + echo "wx-config already exists in ${WX_BUILD_DIR}. Skipping wxbuild." +else + make WXSTATIC=1 NOGUI=1 NOSSE2=1 wxbuild || exit 1 +fi +make WXSTATIC=1 NOGUI=1 NOSSE2=1 clean || exit 1 +make WXSTATIC=1 NOGUI=1 NOSSE2=1 || exit 1 +make WXSTATIC=1 NOGUI=1 NOSSE2=1 package || exit |