Commit 1970bc27 authored by Dr. Stephen Henson's avatar Dr. Stephen Henson
Browse files

For Unix fips builds...

1. Make shared library build default.
2. Fix libcrypto build to work with shared builds.
3. Link fips utilities to fipscanister.o except for fipsdso builds.
parent 08debe11
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -903,6 +903,11 @@ print "Configuring for $target\n";

&usage if (!defined($table{$target}));

if ($fips && ($disabled{"shared"} eq "default"))
	{
	delete $disabled{"shared"};
	}


foreach (sort (keys %disabled))
	{
@@ -1179,7 +1184,7 @@ if ($zlib)
my $shared_mark = "";
if ($shared_target eq "")
	{
	$no_shared_warn = 1 if !$no_shared;
	$no_shared_warn = 1 if !$no_shared && !$fips;
	$no_shared = 1;
	}
if (!$no_shared)
+6 −1
Original line number Diff line number Diff line
@@ -354,7 +354,12 @@ libcrypto$(SHLIB_EXT): libcrypto.a $(SHARED_FIPS)
			$(MAKE) SHLIBDIRS='crypto' SHLIBDEPS='-lfips' build-shared; \
			$(AR) libcrypto.a fips-1.0/fipscanister.o ; \
		else \
			$(MAKE) SHLIBDIRS='crypto' build-shared; \
			if [ "$(FIPSCANLIB)" = "libcrypto" ]; then \
				FIPSLD_CC=$(CC); CC=fips-1.0/fipsld; \
				FIPSLD_NPT="y"; FIPSLD_LIBFIPS=y; \
				export CC FIPSLD_CC FIPSLD_NPT FIPSLD_LIBFIPS; \
			fi; \
			$(MAKE) -e SHLIBDIRS='crypto' build-shared; \
		fi \
	else \
		echo "There's no support for shared libraries on this platform" >&2; \
+1 −1
Original line number Diff line number Diff line
@@ -397,7 +397,7 @@ $(SHA512TEST)$(EXE_EXT): $(SHA512TEST).o $(DLIBCRYPTO)
FIPS_BUILD_CMD=shlib_target=; if [ -n "$(SHARED_LIBS)" ]; then \
		shlib_target="$(SHLIB_TARGET)"; \
	fi; \
	if [ -z "$(SHARED_LIBS)" -o "$${shlib_target}" = "darwin-shared" ] ; then \
	if [ "$(FIPSCANLIB)" != "libfips" -o -z "$(SHARED_LIBS)" -o "$${shlib_target}" = "darwin-shared" ] ; then \
		LIBRARIES=""; \
		if [ -n "$(FIPSCANLIB)" ]; then \
			FIPSLD_CC=$(CC); CC=$(TOP)/fips-1.0/fipsld; FIPSLD_NPT="y" \