From 4a8f068ba559ceb597fb8b417a08c8fc96088aa4 Mon Sep 17 00:00:00 2001 From: Mounir IDRASSI Date: Sun, 8 Sep 2024 17:14:31 +0200 Subject: Windows: Add support for x86 and x64 build for driver and binaries using Visual Studio 2019 We also enable Control Flow Guard and Spectre Mitigation --- src/Setup/Portable_vs2019.vcxproj | 328 +++++++++++++++++++++++++++++ src/Setup/Portable_vs2019.vcxproj.filters | 154 ++++++++++++++ src/Setup/Portable_vs2019.vcxproj.user | 3 + src/Setup/Setup_vs2019.vcxproj | 331 ++++++++++++++++++++++++++++++ src/Setup/Setup_vs2019.vcxproj.filters | 162 +++++++++++++++ src/Setup/Setup_vs2019.vcxproj.user | 3 + 6 files changed, 981 insertions(+) create mode 100644 src/Setup/Portable_vs2019.vcxproj create mode 100644 src/Setup/Portable_vs2019.vcxproj.filters create mode 100644 src/Setup/Portable_vs2019.vcxproj.user create mode 100644 src/Setup/Setup_vs2019.vcxproj create mode 100644 src/Setup/Setup_vs2019.vcxproj.filters create mode 100644 src/Setup/Setup_vs2019.vcxproj.user (limited to 'src/Setup') diff --git a/src/Setup/Portable_vs2019.vcxproj b/src/Setup/Portable_vs2019.vcxproj new file mode 100644 index 00000000..8b2e4cf5 --- /dev/null +++ b/src/Setup/Portable_vs2019.vcxproj @@ -0,0 +1,328 @@ + + + + + Debug + Win32 + + + ReleaseCustomEFI + Win32 + + + Release_SkipOsDriverReqCheck + Win32 + + + Release + Win32 + + + + {60698D56-DB83-4D19-9C87-9DFB6A6F8C87} + Portable + Win32Proj + Portable + 10.0 + + + + Application + Unicode + v142 + + + Application + Unicode + v142 + + + Application + Unicode + v142 + + + Application + Unicode + v142 + + + + + + + + + + + + + + + + + + + + + + + <_ProjectFileVersion>10.0.40219.1 + $(ProjectDir)PortableDebug\ + $(ProjectDir)PortableDebug\ + true + true + true + $(ProjectDir)PortableRelease\ + $(ProjectDir)PortableRelease\ + $(ProjectDir)PortableRelease\ + $(ProjectDir)PortableRelease\ + $(ProjectDir)PortableRelease\ + $(ProjectDir)PortableRelease\ + false + false + false + true + true + true + VeraCryptPortable + VeraCryptPortable + VeraCryptPortable + VeraCryptPortable + + + + Disabled + ..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories) + SETUP;PORTABLE;WIN32;HAVE_CONFIG_H;ZIP_STATIC;DEBUG;_DEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_ATL_NO_DEFAULT_LIBS;%(PreprocessorDefinitions) + true + EnableFastChecks + MultiThreadedDebug + true + + + Level4 + EditAndContinue + 4057;4100;4127;4201;4505;4701;4706;4131;%(DisableSpecificWarnings) + + + /NODEFAULTLIB:LIBCMTD %(AdditionalOptions) + libcmtd.lib;atls.lib;mpr.lib;..\Common\Debug\Zip.lib;..\Crypto\Debug\crypto.lib;..\Common\Debug\lzma.lib;%(AdditionalDependencies) + $(OutDir)VeraCryptPortable.exe + AsInvoker + mpr.dll;bcrypt.dll;user32.dll;gdi32.dll;comdlg32.dll;advapi32.dll;shell32.dll;ole32.dll;oleaut32.dll;shlwapi.dll;setupapi.dll;wintrust.dll;comctl32.dll;%(DelayLoadDLLs) + true + $(OutDir)Portable.pdb + Windows + false + true + MachineX86 + true + + + Portable.manifest;%(AdditionalManifestFiles) + + + md "..\Debug\Setup Files" 2>NUL: +copy PortableDebug\VeraCryptPortable.exe "..\Debug\Setup Files\VeraCrypt Portable.exe" >NUL: + + + + + + /w34189 %(AdditionalOptions) + MaxSpeed + ..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories) + SETUP;PORTABLE;WIN32;HAVE_CONFIG_H;ZIP_STATIC;NDEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_ATL_NO_DEFAULT_LIBS;%(PreprocessorDefinitions) + MultiThreaded + true + + + All + $(IntDir) + Level4 + ProgramDatabase + 4057;4100;4127;4201;4505;4701;4706;4131;%(DisableSpecificWarnings) + Guard + + + /IGNORE:4089 %(AdditionalOptions) + atls.lib;mpr.lib;..\Common\Release\Zip.lib;..\Crypto\Release\crypto.lib;..\Common\Release\lzma.lib;%(AdditionalDependencies) + $(OutDir)VeraCryptPortable.exe + AsInvoker + mpr.dll;bcrypt.dll;user32.dll;gdi32.dll;comdlg32.dll;advapi32.dll;shell32.dll;ole32.dll;oleaut32.dll;shlwapi.dll;setupapi.dll;wintrust.dll;comctl32.dll;%(DelayLoadDLLs) + true + true + Windows + true + true + true + true + MachineX86 + + + Portable.manifest;%(AdditionalManifestFiles) + + + copy PortableRelease\VeraCryptPortable.exe "..\Release\Setup Files\VeraCrypt Portable.exe" + + + + + /w34189 %(AdditionalOptions) + MaxSpeed + ..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories) + SETUP;PORTABLE;VC_SKIP_OS_DRIVER_REQ_CHECK;WIN32;HAVE_CONFIG_H;ZIP_STATIC;NDEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_ATL_NO_DEFAULT_LIBS;%(PreprocessorDefinitions) + MultiThreaded + true + + + All + $(IntDir) + Level4 + ProgramDatabase + 4057;4100;4127;4201;4505;4701;4706;4131;%(DisableSpecificWarnings) + + + /IGNORE:4089 %(AdditionalOptions) + mpr.lib;..\Common\Release\Zip.lib;..\Crypto\Release\crypto.lib;..\Common\Release\lzma.lib;%(AdditionalDependencies) + $(OutDir)VeraCryptPortable.exe + AsInvoker + mpr.dll;bcrypt.dll;user32.dll;gdi32.dll;comdlg32.dll;advapi32.dll;shell32.dll;ole32.dll;oleaut32.dll;shlwapi.dll;setupapi.dll;wintrust.dll;comctl32.dll;%(DelayLoadDLLs) + true + true + Windows + true + true + true + true + MachineX86 + + + Portable.manifest;%(AdditionalManifestFiles) + + + copy PortableRelease\VeraCryptPortable.exe "..\Release\Setup Files\VeraCrypt Portable.exe" + + + + + /w34189 %(AdditionalOptions) + MaxSpeed + ..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories) + SETUP;PORTABLE;VC_EFI_CUSTOM_MODE;WIN32;HAVE_CONFIG_H;ZIP_STATIC;NDEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_ATL_NO_DEFAULT_LIBS;%(PreprocessorDefinitions) + MultiThreaded + true + + + All + $(IntDir) + Level4 + ProgramDatabase + 4057;4100;4127;4201;4505;4701;4706;4131;%(DisableSpecificWarnings) + + + /IGNORE:4089 %(AdditionalOptions) + mpr.lib;..\Common\Release\Zip.lib;..\Crypto\Release\crypto.lib;..\Common\Release\lzma.lib;%(AdditionalDependencies) + $(OutDir)VeraCryptPortable.exe + AsInvoker + mpr.dll;bcrypt.dll;user32.dll;gdi32.dll;comdlg32.dll;advapi32.dll;shell32.dll;ole32.dll;oleaut32.dll;shlwapi.dll;setupapi.dll;wintrust.dll;comctl32.dll;%(DelayLoadDLLs) + true + true + Windows + true + true + true + true + MachineX86 + + + Portable.manifest;%(AdditionalManifestFiles) + + + copy PortableRelease\VeraCryptPortable.exe "..\Release\Setup Files\VeraCrypt Portable.exe" + + + VC_EFI_CUSTOM_MODE;%(PreprocessorDefinitions) + + + + + + + CompileAsCpp + CompileAsCpp + CompileAsCpp + CompileAsCpp + + + CompileAsCpp + CompileAsCpp + CompileAsCpp + CompileAsCpp + + + + + + CompileAsCpp + CompileAsCpp + CompileAsCpp + CompileAsCpp + + + CompileAsCpp + CompileAsCpp + CompileAsCpp + CompileAsCpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + true + true + true + true + + + + + + + \ No newline at end of file diff --git a/src/Setup/Portable_vs2019.vcxproj.filters b/src/Setup/Portable_vs2019.vcxproj.filters new file mode 100644 index 00000000..855ecc00 --- /dev/null +++ b/src/Setup/Portable_vs2019.vcxproj.filters @@ -0,0 +1,154 @@ + + + + + {4FC737F1-C7A5-4376-A066-2A32D752A2FF} + cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx + + + {876C2050-1694-4F32-AF5D-491C6A43A799} + + + {93995380-89BD-4b04-88EB-625FBE52EBFB} + h;hpp;hxx;hm;inl;inc;xsd + + + {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} + rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx + + + {17370B4B-2D76-41A9-9828-015FB30054F6} + + + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files\Common + + + Source Files\Common + + + Source Files\Common + + + Source Files\Common + + + Source Files\Common + + + Source Files\Common + + + Source Files + + + + + Resource Files + + + Resource Files + + + Resource Files + + + Resource Files + + + Resource Files + + + Resource Files\Common + + + Resource Files\Common + + + Resource Files\Common + + + Resource Files\Common + + + Resource Files\Common + + + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + + + + + + Resource Files\Common + + + Resource Files + + + \ No newline at end of file diff --git a/src/Setup/Portable_vs2019.vcxproj.user b/src/Setup/Portable_vs2019.vcxproj.user new file mode 100644 index 00000000..ace9a86a --- /dev/null +++ b/src/Setup/Portable_vs2019.vcxproj.user @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/src/Setup/Setup_vs2019.vcxproj b/src/Setup/Setup_vs2019.vcxproj new file mode 100644 index 00000000..0c329156 --- /dev/null +++ b/src/Setup/Setup_vs2019.vcxproj @@ -0,0 +1,331 @@ + + + + + Debug + Win32 + + + ReleaseCustomEFI + Win32 + + + Release_SkipOsDriverReqCheck + Win32 + + + Release + Win32 + + + + {DF5F654D-BD44-4E31-B92E-B68074DC37A8} + Setup + Win32Proj + Setup + 10.0 + + + + Application + Unicode + v142 + + + Application + Unicode + v142 + + + Application + Unicode + v142 + + + Application + Unicode + v142 + + + + + + + + + + + + + + + + + + + + + + + <_ProjectFileVersion>10.0.40219.1 + $(ProjectDir)Debug\ + $(ProjectDir)Debug\ + true + true + true + $(ProjectDir)Release\ + $(ProjectDir)Release\ + $(ProjectDir)Release\ + $(ProjectDir)Release\ + $(ProjectDir)Release\ + $(ProjectDir)Release\ + false + false + false + true + true + true + VeraCryptSetup + VeraCryptSetup + VeraCryptSetup + VeraCryptSetup + + + + Disabled + ..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories) + SETUP;WIN32;HAVE_CONFIG_H;ZIP_STATIC;DEBUG;_DEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_ATL_NO_DEFAULT_LIBS;%(PreprocessorDefinitions) + true + EnableFastChecks + MultiThreadedDebug + true + + + Level4 + EditAndContinue + 4057;4100;4127;4201;4505;4701;4706;4131;%(DisableSpecificWarnings) + + + /NODEFAULTLIB:LIBCMTD %(AdditionalOptions) + libcmtd.lib;atls.lib;mpr.lib;..\Common\Debug\Zip.lib;..\Crypto\Debug\crypto.lib;..\Common\Debug\lzma.lib;%(AdditionalDependencies) + $(OutDir)VeraCryptSetup.exe + RequireAdministrator + mpr.dll;bcrypt.dll;user32.dll;gdi32.dll;comdlg32.dll;advapi32.dll;shell32.dll;ole32.dll;oleaut32.dll;shlwapi.dll;setupapi.dll;wintrust.dll;comctl32.dll;%(DelayLoadDLLs) + true + $(OutDir)Setup.pdb + Windows + false + true + MachineX86 + true + + + Setup.manifest;%(AdditionalManifestFiles) + + + md "..\Debug\Setup Files" 2>NUL: +copy Debug\VeraCryptSetup.exe "..\Debug\Setup Files\VeraCrypt Setup.exe" >NUL: + + + + + + + /w34189 %(AdditionalOptions) + MaxSpeed + ..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories) + SETUP;WIN32;HAVE_CONFIG_H;ZIP_STATIC;NDEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_ATL_NO_DEFAULT_LIBS;%(PreprocessorDefinitions) + MultiThreaded + true + + + All + $(IntDir) + Level4 + ProgramDatabase + 4057;4100;4127;4201;4505;4701;4706;4131;%(DisableSpecificWarnings) + Guard + + + /IGNORE:4089 %(AdditionalOptions) + atls.lib;mpr.lib;..\Common\Release\Zip.lib;..\Crypto\Release\crypto.lib;..\Common\Release\lzma.lib;%(AdditionalDependencies) + $(OutDir)VeraCryptSetup.exe + RequireAdministrator + mpr.dll;bcrypt.dll;user32.dll;gdi32.dll;comdlg32.dll;advapi32.dll;shell32.dll;ole32.dll;oleaut32.dll;shlwapi.dll;setupapi.dll;wintrust.dll;comctl32.dll;%(DelayLoadDLLs) + true + true + Windows + true + true + true + true + MachineX86 + + + Setup.manifest;%(AdditionalManifestFiles) + + + copy Release\VeraCryptSetup.exe "..\Release\Setup Files\VeraCrypt Setup.exe" && copy Release\VeraCryptSetup.exe "..\Release\Setup Files\VeraCrypt COMReg.exe" + + + + + /w34189 %(AdditionalOptions) + MaxSpeed + ..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories) + SETUP;VC_SKIP_OS_DRIVER_REQ_CHECK;WIN32;HAVE_CONFIG_H;ZIP_STATIC;NDEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_ATL_NO_DEFAULT_LIBS;%(PreprocessorDefinitions) + MultiThreaded + true + + + All + $(IntDir) + Level4 + ProgramDatabase + 4057;4100;4127;4201;4505;4701;4706;4131;%(DisableSpecificWarnings) + + + /IGNORE:4089 %(AdditionalOptions) + mpr.lib;..\Common\Release\Zip.lib;..\Crypto\Release\crypto.lib;..\Common\Release\lzma.lib;%(AdditionalDependencies) + $(OutDir)VeraCryptSetup.exe + RequireAdministrator + mpr.dll;bcrypt.dll;user32.dll;gdi32.dll;comdlg32.dll;advapi32.dll;shell32.dll;ole32.dll;oleaut32.dll;shlwapi.dll;setupapi.dll;wintrust.dll;comctl32.dll;%(DelayLoadDLLs) + true + true + Windows + true + true + true + true + MachineX86 + + + Setup.manifest;%(AdditionalManifestFiles) + + + copy Release\VeraCryptSetup.exe "..\Release\Setup Files\VeraCrypt Setup.exe" + + + + + /w34189 %(AdditionalOptions) + MaxSpeed + ..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories) + SETUP;VC_EFI_CUSTOM_MODE;WIN32;HAVE_CONFIG_H;ZIP_STATIC;NDEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_ATL_NO_DEFAULT_LIBS;%(PreprocessorDefinitions) + MultiThreaded + true + + + All + $(IntDir) + Level4 + ProgramDatabase + 4057;4100;4127;4201;4505;4701;4706;4131;%(DisableSpecificWarnings) + + + /IGNORE:4089 %(AdditionalOptions) + mpr.lib;..\Common\Release\Zip.lib;..\Crypto\Release\crypto.lib;..\Common\Release\lzma.lib;%(AdditionalDependencies) + $(OutDir)VeraCryptSetup.exe + RequireAdministrator + mpr.dll;bcrypt.dll;user32.dll;gdi32.dll;comdlg32.dll;advapi32.dll;shell32.dll;ole32.dll;oleaut32.dll;shlwapi.dll;setupapi.dll;wintrust.dll;comctl32.dll;%(DelayLoadDLLs) + true + true + Windows + true + true + true + true + MachineX86 + + + Setup.manifest;%(AdditionalManifestFiles) + + + copy Release\VeraCryptSetup.exe "..\Release\Setup Files\VeraCrypt Setup.exe" + + + VC_EFI_CUSTOM_MODE;%(PreprocessorDefinitions) + + + + + + + + CompileAsCpp + CompileAsCpp + CompileAsCpp + CompileAsCpp + + + CompileAsCpp + CompileAsCpp + CompileAsCpp + CompileAsCpp + + + + + + CompileAsCpp + CompileAsCpp + CompileAsCpp + CompileAsCpp + + + CompileAsCpp + CompileAsCpp + CompileAsCpp + CompileAsCpp + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + true + true + true + true + + + + + + \ No newline at end of file diff --git a/src/Setup/Setup_vs2019.vcxproj.filters b/src/Setup/Setup_vs2019.vcxproj.filters new file mode 100644 index 00000000..d747363f --- /dev/null +++ b/src/Setup/Setup_vs2019.vcxproj.filters @@ -0,0 +1,162 @@ + + + + + {4FC737F1-C7A5-4376-A066-2A32D752A2FF} + cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx + + + {6073052c-2d95-47a0-95d8-5960d4c1d1c0} + + + {93995380-89BD-4b04-88EB-625FBE52EBFB} + h;hpp;hxx;hm;inl;inc;xsd + + + {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} + rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx + + + {a540fb0a-850b-4cb9-85f9-ade0112ebb50} + + + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files\Common + + + Source Files\Common + + + Source Files\Common + + + Source Files\Common + + + Source Files\Common + + + Source Files\Common + + + Source Files + + + + + Source Files + + + Resource Files + + + Resource Files + + + Resource Files + + + Resource Files + + + Resource Files + + + Resource Files\Common + + + Resource Files\Common + + + Resource Files\Common + + + Resource Files\Common + + + Resource Files\Common + + + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + + + Resource Files + + + + + Resource Files + + + Resource Files\Common + + + \ No newline at end of file diff --git a/src/Setup/Setup_vs2019.vcxproj.user b/src/Setup/Setup_vs2019.vcxproj.user new file mode 100644 index 00000000..ace9a86a --- /dev/null +++ b/src/Setup/Setup_vs2019.vcxproj.user @@ -0,0 +1,3 @@ + + + \ No newline at end of file -- cgit v1.2.3