Fingerprinting needs to work even if OpenSSL isn't installed yet.
authorBen Laurie <ben@openssl.org>
Sat, 4 Oct 2003 14:11:45 +0000 (14:11 +0000)
committerBen Laurie <ben@openssl.org>
Sat, 4 Oct 2003 14:11:45 +0000 (14:11 +0000)
fips/aes/Makefile.ssl
fips/des/Makefile.ssl
fips/dsa/Makefile.ssl
fips/openssl_fips_fingerprint
fips/sha1/Makefile.ssl
test/Makefile.ssl

index b3101a2d0eedcf0485d803f5bc65441d25bced80..192912cee1e7413cbd7349aabe5730cd18c8a446 100644 (file)
@@ -74,7 +74,7 @@ top_fips_aesavs:
 
 fips_aesavs: fips_aesavs.o $(TOP)/libcrypto.a
        $(CC) $(CFLAGS) -o fips_aesavs fips_aesavs.o $(TOP)/libcrypto.a
-       $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a fips_aesavs
+       TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a fips_aesavs
 
 fips_test: top top_fips_aesavs
        find ../testvectors/aes/req -name '*.req' > testlist
index 72562c804a853345be8aeac016cb8f5caa83fa1e..6f753585b01c98de204c2bb2f077102416da6a21 100644 (file)
@@ -72,7 +72,7 @@ top_fips_desmovs:
 
 fips_desmovs: fips_desmovs.o $(TOP)/libcrypto.a
        $(CC) $(CFLAGS) -o fips_desmovs fips_desmovs.o $(TOP)/libcrypto.a
-       $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a fips_desmovs
+       TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a fips_desmovs
 
 fips_test: top_fips_desmovs
        find ../testvectors/des/req -name '*.req' > testlist
index 11d23bcc3e9026718437d3798756676634af43d7..4aabe5553a6153ac2f8f37c2058364995b0b4731 100644 (file)
@@ -72,7 +72,7 @@ top_fips_dssvs:
 
 fips_dssvs: fips_dssvs.o $(TOP)/libcrypto.a
        $(CC) $(CFLAGS) -o fips_dssvs fips_dssvs.o $(TOP)/libcrypto.a
-       $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a fips_dssvs
+       TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a fips_dssvs
 
 Q=../testvectors/dsa/req
 A=../testvectors/dsa/rsp
index 98f69f2c4ddcc1fbca31d132eb847dc3f4f8ee07..6d86c900334115c3fc1585a2e4132d9b3e51eddc 100755 (executable)
@@ -6,6 +6,13 @@
 lib=$1
 exe=$2
 
+# deal with the case where we're run from within the build and OpenSSL is
+# not yet installed
+if [ "X$TOP" != "X" ]
+then
+    PATH=$PATH:$TOP/apps
+fi
+
 elib=`echo $lib| sed 's/\//\\\\\//g'`
 echo "Checking library fingerprint for $lib"
 openssl sha1 $lib | sed "s/$elib/libcrypto.a/" | diff -u ${lib%.a}.sha1 - || { echo "$libs fingerprint mismatch"; exit 1; }
index 18657c913665594dfccd6d6ae4de0243a22621a9..00ce6d15fa28af9d4bdcca255e4168e5682651c4 100644 (file)
@@ -82,7 +82,7 @@ top_fips_sha1test:
 
 fips_sha1test: fips_sha1test.o $(TOP)/libcrypto.a
        $(CC) $(CFLAGS) -o fips_sha1test fips_sha1test.o $(TOP)/libcrypto.a
-       $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a fips_sha1test
+       TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a fips_sha1test
 
 fips_test: top_fips_sha1test
        -rm -rf ../testvectors/sha1/rsp
index 83a86964c0bc529e701604ed8d72dd7283d2e55e..ca247529f796e202685f0b29fd93e67edad04956 100644 (file)
@@ -322,7 +322,7 @@ $(FIPS_AESTEST): $(FIPS_AESTEST).o $(DLIBCRYPTO)
          $(CC) -o $(FIPS_AESTEST) $(CFLAGS) $(FIPS_AESTEST).o $(PEX_LIBS) $(LIBCRYPTO) $(EX_LIBS) ; \
        fi
        if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
-         $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_AESTEST); \
+         TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_AESTEST); \
        fi
 
 $(RSATEST): $(RSATEST).o $(DLIBCRYPTO)
@@ -396,7 +396,7 @@ $(FIPS_SHA1TEST): $(FIPS_SHA1TEST).o $(DLIBCRYPTO)
          $(CC) -o $(FIPS_SHA1TEST) $(CFLAGS) $(FIPS_SHA1TEST).o $(PEX_LIBS) $(LIBCRYPTO) $(EX_LIBS) ; \
        fi
        if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
-         $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_SHA1TEST); \
+         TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_SHA1TEST); \
        fi
 
 $(RMDTEST): $(RMDTEST).o $(DLIBCRYPTO)
@@ -495,7 +495,7 @@ $(FIPS_DESTEST): $(FIPS_DESTEST).o $(DLIBCRYPTO)
          $(CC) -o $(FIPS_DESTEST) $(CFLAGS) $(FIPS_DESTEST).o $(PEX_LIBS) $(LIBCRYPTO) $(EX_LIBS) ; \
        fi
        if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
-         $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_DESTEST); \
+         TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_DESTEST); \
        fi
 
 $(RANDTEST): $(RANDTEST).o $(DLIBCRYPTO)
@@ -513,7 +513,7 @@ $(FIPS_RANDTEST): $(FIPS_RANDTEST).o $(DLIBCRYPTO)
          $(CC) -o $(FIPS_RANDTEST) $(CFLAGS) $(FIPS_RANDTEST).o $(PEX_LIBS) $(LIBCRYPTO) $(EX_LIBS) ; \
        fi
        if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
-         $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_RANDTEST); \
+         TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_RANDTEST); \
        fi
 
 $(DHTEST): $(DHTEST).o $(DLIBCRYPTO)
@@ -539,7 +539,7 @@ $(FIPS_DSATEST): $(FIPS_DSATEST).o $(DLIBCRYPTO)
          $(CC) -o $(FIPS_DSATEST) $(CFLAGS) $(FIPS_DSATEST).o $(PEX_LIBS) $(LIBCRYPTO) $(EX_LIBS) ; \
        fi
        if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
-         $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_DSATEST); \
+         TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(FIPS_DSATEST); \
        fi
 
 $(METHTEST): $(METHTEST).o $(DLIBCRYPTO)
@@ -558,7 +558,7 @@ $(SSLTEST): $(SSLTEST).o $(DLIBSSL) $(DLIBCRYPTO)
          $(CC) -o $(SSLTEST) $(CFLAGS) $(SSLTEST).o $(PEX_LIBS) $(LIBSSL) $(LIBKRB5) $(LIBCRYPTO) $(EX_LIBS) ; \
        fi
        if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
-         $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(SSLTEST); \
+         TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(SSLTEST); \
        fi
 
 $(ENGINETEST): $(ENGINETEST).o $(DLIBCRYPTO)