From c1b971d5b24e5d42f9fc2a063aefb7eb2829031b Mon Sep 17 00:00:00 2001 From: Richard Levitte Date: Thu, 15 Apr 2004 19:35:30 +0000 Subject: [PATCH] Make the Windows/DOS build system understand "fips". --- INSTALL.W32 | 13 +++++++++---- ms/do_masm.bat | 12 +++++++----- ms/do_ms.bat | 14 +++++++------- ms/do_nasm.bat | 13 +++++++------ ms/do_nt.bat | 4 ++-- util/pl/BC-16.pl | 2 +- util/pl/BC-32.pl | 2 +- util/pl/Mingw32.pl | 2 +- util/pl/OS2-EMX.pl | 2 +- util/pl/VC-16.pl | 2 +- util/pl/VC-32.pl | 2 +- util/pl/ultrix.pl | 2 +- 12 files changed, 39 insertions(+), 31 deletions(-) diff --git a/INSTALL.W32 b/INSTALL.W32 index 0f6c302f0d..c277efa18b 100644 --- a/INSTALL.W32 +++ b/INSTALL.W32 @@ -46,12 +46,13 @@ http://www.kernel.org/pub/software/devel/nasm/binaries/win32/ The NASM binary nasmw.exe needs to be installed anywhere on your PATH. - Firstly you should run Configure: + Firstly you should run Configure (to build a FIPS-certified variant of + OpenSSL, add the option "fips"): > perl Configure VC-WIN32 Next you need to build the Makefiles and optionally the assembly language - files: + files (to build a FIPS-certified variant of OpenSSL, add the argument "fips"): - If you are using MASM then run: @@ -100,10 +101,12 @@ Borland C++ builder 5 --------------------- - * Configure for building with Borland Builder: + * Configure for building with Borland Builder (to build a FIPS-certified + variant of OpenSSL, add the option "fips"): > perl Configure BC-32 - * Create the appropriate makefile + * Create the appropriate makefile (to build a FIPS-certified variant of + OpenSSL, add the argument "fips") > ms\do_nasm * Build @@ -194,6 +197,8 @@ occur, try > ms\mingw32 no-asm instead. + If you want to build a FIPS-certified variant of OpenSSL, add the argument + "fips" libcrypto.a and libssl.a are the static libraries. To use the DLLs, link with libeay32.a and libssl32.a instead. diff --git a/ms/do_masm.bat b/ms/do_masm.bat index f4c958c561..610505c614 100755 --- a/ms/do_masm.bat +++ b/ms/do_masm.bat @@ -1,3 +1,5 @@ +rem use "fips" as the first argument to make a proper FIPS build. + @echo off echo Generating x86 for MASM assember @@ -56,11 +58,11 @@ cd ..\..\.. echo on perl util\mkfiles.pl >MINFO -rem perl util\mk1mf.pl VC-MSDOS no-sock >ms\msdos.mak -rem perl util\mk1mf.pl VC-W31-32 >ms\w31.mak -perl util\mk1mf.pl dll VC-W31-32 >ms\w31dll.mak -perl util\mk1mf.pl VC-WIN32 >ms\nt.mak -perl util\mk1mf.pl dll VC-WIN32 >ms\ntdll.mak +rem perl util\mk1mf.pl no-sock %1 VC-MSDOS >ms\msdos.mak +rem perl util\mk1mf.pl %1 VC-W31-32 >ms\w31.mak +perl util\mk1mf.pl dll %1 VC-W31-32 >ms\w31dll.mak +perl util\mk1mf.pl %1 VC-WIN32 >ms\nt.mak +perl util\mk1mf.pl dll %1 VC-WIN32 >ms\ntdll.mak perl util\mkdef.pl 16 libeay > ms\libeay16.def perl util\mkdef.pl 32 libeay > ms\libeay32.def diff --git a/ms/do_ms.bat b/ms/do_ms.bat index a8cf515bac..f332cc4613 100755 --- a/ms/do_ms.bat +++ b/ms/do_ms.bat @@ -1,12 +1,12 @@ perl util\mkfiles.pl >MINFO -rem perl util\mk1mf.pl VC-MSDOS no-sock >ms\msdos.mak -rem perl util\mk1mf.pl VC-W31-32 >ms\w31.mak -perl util\mk1mf.pl dll VC-W31-32 >ms\w31dll.mak -perl util\mk1mf.pl no-asm VC-WIN32 >ms\nt.mak -perl util\mk1mf.pl dll no-asm VC-WIN32 >ms\ntdll.mak -perl util\mk1mf.pl no-asm VC-CE >ms\ce.mak -perl util\mk1mf.pl dll no-asm VC-CE >ms\cedll.mak +rem perl util\mk1mf.pl no-sock %1 VC-MSDOS >ms\msdos.mak +rem perl util\mk1mf.pl %1 VC-W31-32 >ms\w31.mak +perl util\mk1mf.pl dll %1 VC-W31-32 >ms\w31dll.mak +perl util\mk1mf.pl no-asm %1 VC-WIN32 >ms\nt.mak +perl util\mk1mf.pl dll no-asm %1 VC-WIN32 >ms\ntdll.mak +perl util\mk1mf.pl no-asm %1 VC-CE >ms\ce.mak +perl util\mk1mf.pl dll no-asm %1 VC-CE >ms\cedll.mak perl util\mkdef.pl 16 libeay > ms\libeay16.def perl util\mkdef.pl 32 libeay > ms\libeay32.def diff --git a/ms/do_nasm.bat b/ms/do_nasm.bat index 557f8a66d7..af637a38dc 100755 --- a/ms/do_nasm.bat +++ b/ms/do_nasm.bat @@ -1,3 +1,4 @@ +rem use "fips" as the first argument to make a proper FIPS build. @echo off echo Generating x86 for NASM assember @@ -57,12 +58,12 @@ cd ..\..\.. echo on perl util\mkfiles.pl >MINFO -rem perl util\mk1mf.pl VC-MSDOS no-sock >ms\msdos.mak -rem perl util\mk1mf.pl VC-W31-32 >ms\w31.mak -perl util\mk1mf.pl dll VC-W31-32 >ms\w31dll.mak -perl util\mk1mf.pl nasm VC-WIN32 >ms\nt.mak -perl util\mk1mf.pl dll nasm VC-WIN32 >ms\ntdll.mak -perl util\mk1mf.pl nasm BC-NT >ms\bcb.mak +rem perl util\mk1mf.pl no-sock %1 VC-MSDOS >ms\msdos.mak +rem perl util\mk1mf.pl %1 VC-W31-32 >ms\w31.mak +perl util\mk1mf.pl dll %1 VC-W31-32 >ms\w31dll.mak +perl util\mk1mf.pl nasm %1 VC-WIN32 >ms\nt.mak +perl util\mk1mf.pl dll nasm %1 VC-WIN32 >ms\ntdll.mak +perl util\mk1mf.pl nasm %1 BC-NT >ms\bcb.mak perl util\mkdef.pl 16 libeay > ms\libeay16.def perl util\mkdef.pl 32 libeay > ms\libeay32.def diff --git a/ms/do_nt.bat b/ms/do_nt.bat index 9c06c27caa..7a649171bc 100755 --- a/ms/do_nt.bat +++ b/ms/do_nt.bat @@ -1,7 +1,7 @@ perl util\mkfiles.pl >MINFO -perl util\mk1mf.pl no-asm VC-NT >ms\nt.mak -perl util\mk1mf.pl dll no-asm VC-NT >ms\ntdll.mak +perl util\mk1mf.pl no-asm %1 VC-NT >ms\nt.mak +perl util\mk1mf.pl dll no-asm %1 VC-NT >ms\ntdll.mak perl util\mkdef.pl libeay NT > ms\libeay32.def perl util\mkdef.pl ssleay NT > ms\ssleay32.def diff --git a/util/pl/BC-16.pl b/util/pl/BC-16.pl index 2033f524ca..7f4e0e7d5e 100644 --- a/util/pl/BC-16.pl +++ b/util/pl/BC-16.pl @@ -64,7 +64,7 @@ $lfile=''; $asm='bcc -c -B -Tml'; $afile='/o'; -if ($no_asm) +if ($no_asm || $fips) { $bn_asm_obj=''; $bn_asm_src=''; diff --git a/util/pl/BC-32.pl b/util/pl/BC-32.pl index e83b336190..fe9f4ca9e7 100644 --- a/util/pl/BC-32.pl +++ b/util/pl/BC-32.pl @@ -62,7 +62,7 @@ $des_enc_src=''; $bf_enc_obj=''; $bf_enc_src=''; -if (!$no_asm) +if (!$no_asm && !$fips) { $bn_mulw_obj='crypto\bn\asm\bn_win32.obj'; $bn_mulw_src='crypto\bn\asm\bn_win32.asm'; diff --git a/util/pl/Mingw32.pl b/util/pl/Mingw32.pl index 4bee638c4a..bfbcb58bf6 100644 --- a/util/pl/Mingw32.pl +++ b/util/pl/Mingw32.pl @@ -21,7 +21,7 @@ if ($debug) else { $cflags="-DL_ENDIAN -DDSO_WIN32 -fomit-frame-pointer -O3 -mcpu=i486 -Wall"; } -if ($gaswin and !$no_asm) +if ($gaswin and !$no_asm and !$fips) { $bn_asm_obj='$(OBJ_D)\bn-win32.o'; $bn_asm_src='crypto/bn/asm/bn-win32.s'; diff --git a/util/pl/OS2-EMX.pl b/util/pl/OS2-EMX.pl index ddb3524210..009417acc7 100644 --- a/util/pl/OS2-EMX.pl +++ b/util/pl/OS2-EMX.pl @@ -48,7 +48,7 @@ $des_enc_src=""; $bf_enc_obj=""; $bf_enc_src=""; -if (!$no_asm) +if (!$no_asm && !$fips) { $bn_asm_obj="crypto/bn/asm/bn-os2$obj crypto/bn/asm/co-os2$obj"; $bn_asm_src="crypto/bn/asm/bn-os2.asm crypto/bn/asm/co-os2.asm"; diff --git a/util/pl/VC-16.pl b/util/pl/VC-16.pl index 7cda5e67a9..b821902071 100644 --- a/util/pl/VC-16.pl +++ b/util/pl/VC-16.pl @@ -90,7 +90,7 @@ $des_enc_src=''; $bf_enc_obj=''; $bf_enc_src=''; -if (!$no_asm) +if (!$no_asm && !$fips) { if ($asmbits == 32) { diff --git a/util/pl/VC-32.pl b/util/pl/VC-32.pl index 285990c589..b5b66cc00f 100644 --- a/util/pl/VC-32.pl +++ b/util/pl/VC-32.pl @@ -64,7 +64,7 @@ $des_enc_src=''; $bf_enc_obj=''; $bf_enc_src=''; -if (!$no_asm) +if (!$no_asm && !$fips) { $bn_asm_obj='crypto\bn\asm\bn_win32.obj'; $bn_asm_src='crypto\bn\asm\bn_win32.asm'; diff --git a/util/pl/ultrix.pl b/util/pl/ultrix.pl index ea370c71f9..d88e8b9827 100644 --- a/util/pl/ultrix.pl +++ b/util/pl/ultrix.pl @@ -17,7 +17,7 @@ else $cflags.=" -std1 -DL_ENDIAN"; -if (!$no_asm) +if (!$no_asm && !$fips) { $bn_asm_obj='$(OBJ_D)/mips1.o'; $bn_asm_src='crypto/bn/asm/mips1.s'; -- 2.25.1