From fac1122b85a79574b0cdf920a636cb7710a2e07b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bence=20Sz=C3=A9pk=C3=BAti?= Date: Tue, 12 Mar 2024 16:38:23 +0100 Subject: [PATCH 1/5] Rename solution files to referece VS2017 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Bence Szépkúti --- Makefile | 14 +++++++------- ...emplate.vcxproj => vs2017-app-template.vcxproj} | 0 ...mplate.vcxproj => vs2017-main-template.vcxproj} | 0 ...13-sln-template.sln => vs2017-sln-template.sln} | 0 scripts/generate_visualc_files.pl | 8 ++++---- scripts/windows_msbuild.bat | 2 +- tests/scripts/check-generated-files.sh | 2 +- visualc/{VS2013 => VS2017}/.gitignore | 0 8 files changed, 13 insertions(+), 13 deletions(-) rename scripts/data_files/{vs2013-app-template.vcxproj => vs2017-app-template.vcxproj} (100%) rename scripts/data_files/{vs2013-main-template.vcxproj => vs2017-main-template.vcxproj} (100%) rename scripts/data_files/{vs2013-sln-template.sln => vs2017-sln-template.sln} (100%) rename visualc/{VS2013 => VS2017}/.gitignore (100%) diff --git a/Makefile b/Makefile index 885948c112..0c404bffaa 100644 --- a/Makefile +++ b/Makefile @@ -60,7 +60,7 @@ gen_file_dep = | endif .PHONY: visualc_files -VISUALC_FILES = visualc/VS2013/mbedTLS.sln visualc/VS2013/mbedTLS.vcxproj +VISUALC_FILES = visualc/VS2017/mbedTLS.sln visualc/VS2017/mbedTLS.vcxproj # TODO: $(app).vcxproj for each $(app) in programs/ visualc_files: $(VISUALC_FILES) @@ -69,9 +69,9 @@ visualc_files: $(VISUALC_FILES) # they just need to be present. $(VISUALC_FILES): | library/generated_files $(VISUALC_FILES): $(gen_file_dep) scripts/generate_visualc_files.pl -$(VISUALC_FILES): $(gen_file_dep) scripts/data_files/vs2013-app-template.vcxproj -$(VISUALC_FILES): $(gen_file_dep) scripts/data_files/vs2013-main-template.vcxproj -$(VISUALC_FILES): $(gen_file_dep) scripts/data_files/vs2013-sln-template.sln +$(VISUALC_FILES): $(gen_file_dep) scripts/data_files/vs2017-app-template.vcxproj +$(VISUALC_FILES): $(gen_file_dep) scripts/data_files/vs2017-main-template.vcxproj +$(VISUALC_FILES): $(gen_file_dep) scripts/data_files/vs2017-sln-template.sln # TODO: also the list of .c and .h source files, but not their content $(VISUALC_FILES): echo " Gen $@ ..." @@ -147,10 +147,10 @@ neat: clean_more_on_top $(MAKE) -C programs neat $(MAKE) -C tests neat ifndef WINDOWS - rm -f visualc/VS2013/*.vcxproj visualc/VS2013/mbedTLS.sln + rm -f visualc/VS2017/*.vcxproj visualc/VS2017/mbedTLS.sln else - if exist visualc\VS2013\*.vcxproj del /Q /F visualc\VS2013\*.vcxproj - if exist visualc\VS2013\mbedTLS.sln del /Q /F visualc\VS2013\mbedTLS.sln + if exist visualc\VS2017\*.vcxproj del /Q /F visualc\VS2017\*.vcxproj + if exist visualc\VS2017\mbedTLS.sln del /Q /F visualc\VS2017\mbedTLS.sln endif check: lib tests diff --git a/scripts/data_files/vs2013-app-template.vcxproj b/scripts/data_files/vs2017-app-template.vcxproj similarity index 100% rename from scripts/data_files/vs2013-app-template.vcxproj rename to scripts/data_files/vs2017-app-template.vcxproj diff --git a/scripts/data_files/vs2013-main-template.vcxproj b/scripts/data_files/vs2017-main-template.vcxproj similarity index 100% rename from scripts/data_files/vs2013-main-template.vcxproj rename to scripts/data_files/vs2017-main-template.vcxproj diff --git a/scripts/data_files/vs2013-sln-template.sln b/scripts/data_files/vs2017-sln-template.sln similarity index 100% rename from scripts/data_files/vs2013-sln-template.sln rename to scripts/data_files/vs2017-sln-template.sln diff --git a/scripts/generate_visualc_files.pl b/scripts/generate_visualc_files.pl index 96ade2fa76..272337c22d 100755 --- a/scripts/generate_visualc_files.pl +++ b/scripts/generate_visualc_files.pl @@ -13,12 +13,12 @@ use warnings; use strict; use Digest::MD5 'md5_hex'; -my $vsx_dir = "visualc/VS2013"; +my $vsx_dir = "visualc/VS2017"; my $vsx_ext = "vcxproj"; -my $vsx_app_tpl_file = "scripts/data_files/vs2013-app-template.$vsx_ext"; -my $vsx_main_tpl_file = "scripts/data_files/vs2013-main-template.$vsx_ext"; +my $vsx_app_tpl_file = "scripts/data_files/vs2017-app-template.$vsx_ext"; +my $vsx_main_tpl_file = "scripts/data_files/vs2017-main-template.$vsx_ext"; my $vsx_main_file = "$vsx_dir/mbedTLS.$vsx_ext"; -my $vsx_sln_tpl_file = "scripts/data_files/vs2013-sln-template.sln"; +my $vsx_sln_tpl_file = "scripts/data_files/vs2017-sln-template.sln"; my $vsx_sln_file = "$vsx_dir/mbedTLS.sln"; my $programs_dir = 'programs'; diff --git a/scripts/windows_msbuild.bat b/scripts/windows_msbuild.bat index ff2b9f2d1c..2bc6a51ce8 100644 --- a/scripts/windows_msbuild.bat +++ b/scripts/windows_msbuild.bat @@ -14,7 +14,7 @@ if not "%~1"=="" set "retarget=,PlatformToolset=%1" @rem vcvarsall.bat will silently change the directory to that directory. @rem Setting the VSCMD_START_DIR environment variable causes it to change @rem to that directory instead. -set "VSCMD_START_DIR=%~dp0\..\visualc\VS2013" +set "VSCMD_START_DIR=%~dp0\..\visualc\VS2017" "%vcvarsall%" x64 && ^ msbuild /t:Rebuild /p:Configuration=%cfg%%retarget% /m mbedTLS.sln diff --git a/tests/scripts/check-generated-files.sh b/tests/scripts/check-generated-files.sh index 3fe4e8c63a..792885fdf3 100755 --- a/tests/scripts/check-generated-files.sh +++ b/tests/scripts/check-generated-files.sh @@ -142,5 +142,5 @@ if in_mbedtls_repo; then # generate_visualc_files enumerates source files (library/*.c). It doesn't # care about their content, but the files must exist. So it must run after # the step that creates or updates these files. - check scripts/generate_visualc_files.pl visualc/VS2013 + check scripts/generate_visualc_files.pl visualc/VS2017 fi diff --git a/visualc/VS2013/.gitignore b/visualc/VS2017/.gitignore similarity index 100% rename from visualc/VS2013/.gitignore rename to visualc/VS2017/.gitignore From 0719d7c3d8e134b3d95f5f075fa31fd75f95736c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bence=20Sz=C3=A9pk=C3=BAti?= Date: Tue, 12 Mar 2024 16:45:55 +0100 Subject: [PATCH 2/5] Update the MSBuild toolset versions to VS2017 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Bence Szépkúti --- scripts/data_files/vs2017-app-template.vcxproj | 6 +++++- scripts/data_files/vs2017-main-template.vcxproj | 6 +++++- scripts/data_files/vs2017-sln-template.sln | 6 +++--- scripts/generate_visualc_files.pl | 2 +- 4 files changed, 14 insertions(+), 6 deletions(-) diff --git a/scripts/data_files/vs2017-app-template.vcxproj b/scripts/data_files/vs2017-app-template.vcxproj index 2fe9cf33b5..36ca317052 100644 --- a/scripts/data_files/vs2017-app-template.vcxproj +++ b/scripts/data_files/vs2017-app-template.vcxproj @@ -1,5 +1,5 @@  - + Debug @@ -37,23 +37,27 @@ Application true Unicode + v141 Application true Unicode + v141 Application false true Unicode + v141 Application false true Unicode + v141 diff --git a/scripts/data_files/vs2017-main-template.vcxproj b/scripts/data_files/vs2017-main-template.vcxproj index 51861e16c5..448f9cd956 100644 --- a/scripts/data_files/vs2017-main-template.vcxproj +++ b/scripts/data_files/vs2017-main-template.vcxproj @@ -1,5 +1,5 @@  - + Debug @@ -28,23 +28,27 @@ StaticLibrary true Unicode + v141 StaticLibrary true Unicode + v141 StaticLibrary false true Unicode + v141 StaticLibrary false true Unicode + v141 diff --git a/scripts/data_files/vs2017-sln-template.sln b/scripts/data_files/vs2017-sln-template.sln index 615ce04234..80efb10832 100644 --- a/scripts/data_files/vs2017-sln-template.sln +++ b/scripts/data_files/vs2017-sln-template.sln @@ -1,8 +1,8 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2013 -VisualStudioVersion = 12.0.31101.0 -MinimumVisualStudioVersion = 10.0.40219.1 +# Visual Studio 2017 +VisualStudioVersion = 15.0.26228.4 +MinimumVisualStudioVersion = 15.0.26228.4 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mbedTLS", "mbedTLS.vcxproj", "{46CF2D25-6A36-4189-B59C-E4815388E554}" EndProject APP_ENTRIES diff --git a/scripts/generate_visualc_files.pl b/scripts/generate_visualc_files.pl index 272337c22d..a0dfc57bff 100755 --- a/scripts/generate_visualc_files.pl +++ b/scripts/generate_visualc_files.pl @@ -1,7 +1,7 @@ #!/usr/bin/env perl # Generate main file, individual apps and solution files for -# MS Visual Studio 2013 +# MS Visual Studio 2017 # # Must be run from Mbed TLS root or scripts directory. # Takes no argument. From ae0d97ab8bedbfcc0bfd2f682287028e0fbdd443 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bence=20Sz=C3=A9pk=C3=BAti?= Date: Tue, 12 Mar 2024 17:23:01 +0100 Subject: [PATCH 3/5] Update compilers list in docs and changelog MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Drop support for MSVC 2013, 2015 and Arm Compiler 5 Signed-off-by: Bence Szépkúti --- ChangeLog.d/drop-msvc-2015-and-armcc-5.txt | 2 ++ README.md | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) create mode 100644 ChangeLog.d/drop-msvc-2015-and-armcc-5.txt diff --git a/ChangeLog.d/drop-msvc-2015-and-armcc-5.txt b/ChangeLog.d/drop-msvc-2015-and-armcc-5.txt new file mode 100644 index 0000000000..de37c2781d --- /dev/null +++ b/ChangeLog.d/drop-msvc-2015-and-armcc-5.txt @@ -0,0 +1,2 @@ +Requirement changes + * Drop support for MSVC 2013, 2015 and Arm Compiler 5. diff --git a/README.md b/README.md index 2505d8fd9c..f22a45348a 100644 --- a/README.md +++ b/README.md @@ -47,11 +47,11 @@ The Make and CMake build systems create three libraries: libmbedcrypto, libmbedx You need the following tools to build the library with the provided makefiles: * GNU Make 3.82 or a build tool that CMake supports. -* A C99 toolchain (compiler, linker, archiver). We actively test with GCC 5.4, Clang 3.8, IAR 8 and Visual Studio 2013. More recent versions should work. Slightly older versions may work. +* A C99 toolchain (compiler, linker, archiver). We actively test with GCC 5.4, Clang 3.8, Arm Compiler 6, IAR 8 and Visual Studio 2017. More recent versions should work. Slightly older versions may work. * Python 3.8 to generate the test code. Python is also needed to integrate PSA drivers and to build the development branch (see next section). * Perl to run the tests, and to generate some source files in the development branch. * CMake 3.10.2 or later (if using CMake). -* Microsoft Visual Studio 2013 or later (if using Visual Studio). +* Microsoft Visual Studio 2017 or later (if using Visual Studio). * Doxygen 1.8.11 or later (if building the documentation; slightly older versions should work). ### Generated source files in the development branch @@ -221,7 +221,7 @@ subproject. ### Microsoft Visual Studio -The build files for Microsoft Visual Studio are generated for Visual Studio 2013. +The build files for Microsoft Visual Studio are generated for Visual Studio 2017. The solution file `mbedTLS.sln` contains all the basic projects needed to build the library and all the programs. The files in tests are not generated and compiled, as these need Python and perl environments as well. However, the selftest program in `programs/test/` is still available. From a32546c96e5c12b8b4b28d22e5ec3f1c9e819368 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bence=20Sz=C3=A9pk=C3=BAti?= Date: Fri, 15 Mar 2024 12:14:39 +0100 Subject: [PATCH 4/5] Update changelog MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Expand MSVC to Visual Studio and announce the moving of the solution files. Signed-off-by: Bence Szépkúti --- ChangeLog.d/drop-msvc-2015-and-armcc-5.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ChangeLog.d/drop-msvc-2015-and-armcc-5.txt b/ChangeLog.d/drop-msvc-2015-and-armcc-5.txt index de37c2781d..435cc98492 100644 --- a/ChangeLog.d/drop-msvc-2015-and-armcc-5.txt +++ b/ChangeLog.d/drop-msvc-2015-and-armcc-5.txt @@ -1,2 +1,5 @@ Requirement changes - * Drop support for MSVC 2013, 2015 and Arm Compiler 5. + * Drop support for Visual Studio 2013 and 2015, and Arm Compiler 5. +Changes + * Rename directory containing Visual Studio files from visualc/VS2013 to + visualc/VS2017. From e05b54229f8fdffd7adab806790dd8a0b3486bbe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bence=20Sz=C3=A9pk=C3=BAti?= Date: Fri, 15 Mar 2024 12:18:04 +0100 Subject: [PATCH 5/5] Drop reference to Visual Studio 2013 from config MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit All supported versions of Visual Studio support AESNI, so drop the version number. Signed-off-by: Bence Szépkúti --- include/mbedtls/mbedtls_config.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/mbedtls/mbedtls_config.h b/include/mbedtls/mbedtls_config.h index 7cf4153b11..df9745a081 100644 --- a/include/mbedtls/mbedtls_config.h +++ b/include/mbedtls/mbedtls_config.h @@ -2211,7 +2211,7 @@ * Enable AES-NI support on x86-64 or x86-32. * * \note AESNI is only supported with certain compilers and target options: - * - Visual Studio 2013: supported. + * - Visual Studio: supported * - GCC, x86-64, target not explicitly supporting AESNI: * requires MBEDTLS_HAVE_ASM. * - GCC, x86-32, target not explicitly supporting AESNI: