New Configure option --openssldir to replace ssldir.pl.
authorUlf Möller <ulf@openssl.org>
Sat, 24 Apr 1999 23:01:36 +0000 (23:01 +0000)
committerUlf Möller <ulf@openssl.org>
Sat, 24 Apr 1999 23:01:36 +0000 (23:01 +0000)
CHANGES
apps/Makefile.ssl
crypto/cryptlib.h
crypto/opensslconf.h.in
util/ssldir.pl [deleted file]

diff --git a/CHANGES b/CHANGES
index 4a0d597d769698e3161a9dd1bb22d67513f56f41..28c4c2cd222ba07170ceca49b92d01f00d3145ff 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -5,6 +5,8 @@
 
  Changes between 0.9.2b and 0.9.3
 
+  *) New Configure options --prefix=DIR and --openssldir=DIR.
+
   *) Complete rewrite of the error code script(s). It is all now handled
      by one script at the top level which handles error code gathering,
      header rewriting and C source file generation. It should be much better
index dbc6db0fde6cf9b6fc2f6cb83d3f09e77d601005..83c19aad14032ff772354c19e55695066d93637d 100644 (file)
@@ -8,6 +8,7 @@ CC=             cc
 INCLUDES=      -I../include
 CFLAG=         -g -static
 INSTALLTOP=    /usr/local/ssl
+OPENSSLDIR=    /usr/local/ssl
 MAKE=          make -f Makefile.ssl
 MAKEDEPEND=    $(TOP)/util/domd $(TOP)
 MAKEFILE=      Makefile.ssl
@@ -93,8 +94,8 @@ install:
         cp $$i $(INSTALLTOP)/bin/$$i; \
         chmod 755 $(INSTALLTOP)/bin/$$i ); \
         done; \
-       cp openssl.cnf $(INSTALLTOP)/lib; \
-       chmod 644 $(INSTALLTOP)/lib/openssl.cnf
+       cp openssl.cnf $(OPENSSLDIR)/lib; \
+       chmod 644 $(OPENSSLDIR)/lib/openssl.cnf
 
 tags:
        ctags $(SRC)
index 8671bea9ff823dba93a638aaae9e77f337409405..990411eb424e12497ff7150083789f51443a0234 100644 (file)
 extern "C" {
 #endif
 
-/* #ifdef FLAT_INC */
-
 #include <openssl/e_os.h>
 #include <openssl/crypto.h>
 #include <openssl/buffer.h> 
 #include <openssl/bio.h> 
 #include <openssl/err.h>
+#include <openssl/opensslconf.h>
 
-/*
-#else
-
-#include "../e_os.h"
-#include <openssl/crypto.h>
-#include "buffer/buffer.h"
-#include "bio/bio.h"
-#include "err/err.h"
-#endif
-*/
-
-#define X509_CERT_AREA         "/usr/local/ssl"
-#define X509_CERT_DIR          "/usr/local/ssl/certs"
-#define X509_CERT_FILE         "/usr/local/ssl/cert.pem"
-#define X509_PRIVATE_DIR       "/usr/local/ssl/private"
+#define X509_CERT_AREA         OPENSSLDIR
+#define X509_CERT_DIR          OPENSSLDIR "/certs"
+#define X509_CERT_FILE         OPENSSLDIR "/cert.pem"
+#define X509_PRIVATE_DIR       OPENSSLDIR "/private"
 
 #define X509_CERT_DIR_EVP        "SSL_CERT_DIR"
 #define X509_CERT_FILE_EVP       "SSL_CERT_FILE"
index c8585133ecb25615fe5d42f9a1d1a09e858e2f01..f5e6c92f2802f01a9afeed23c9eefdab43651089 100644 (file)
@@ -1,6 +1,10 @@
 /* crypto/opensslconf.h */
 /* WARNING: This file is autogenerated by Configure */
 
+#if defined(HEADER_CRYPTLIB_H) && !defined(OPENSSLDIR)
+#define OPENSSLDIR "/usr/local/ssl"
+#endif
+
 #if defined(HEADER_IDEA_H) && !defined(IDEA_INT)
 #define IDEA_INT unsigned int
 #endif
diff --git a/util/ssldir.pl b/util/ssldir.pl
deleted file mode 100755 (executable)
index 1d977c9..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-#!/usr/local/bin/perl
-
-$#ARGV == 0 || die "usage: ssldir.pl /new/path\n";
-@files=('crypto/cryptlib.h',
-       'Makefile.ssl',
-       'tools/c_rehash',
-       'util/mk1mf.pl',
-       );
-
-%cryptlib=(
-       '\sX509_CERT_AREA\s',"#define X509_CERT_AREA\t\t".'"%s"',
-       '\sX509_CERT_DIR\s', "#define X509_CERT_DIR\t\t".'"%s/certs"',
-       '\sX509_CERT_FILE\s', "#define X509_CERT_FILE\t\t".'"%s/cert.pem"',
-       '\sX509_PRIVATE_DIR\s',"#define X509_PRIVATE_DIR\t".'"%s/private"',
-       );
-
-%Makefile_ssl=(
-       '^INSTALLTOP=','INSTALLTOP=%s',
-       );
-
-%c_rehash=(
-       '^DIR=',        'DIR=%s',
-       );
-
-%mk1mf=(
-       '^\$INSTALLTOP=','$INSTALLTOP="%s";',
-       );
-
-&dofile("crypto/cryptlib.h",$ARGV[0],%cryptlib);
-&dofile("Makefile.ssl",$ARGV[0],%Makefile_ssl);
-&dofile("tools/c_rehash",$ARGV[0],%c_rehash);
-&dofile("util/mk1mf.pl",$ARGV[0],%mk1mf);
-
-sub dofile
-       {
-       ($f,$p,%m)=@_;
-
-       open(IN,"<$f") || die "unable to open $f:$!\n";
-       @a=<IN>;
-       close(IN);
-       foreach $k (keys %m)
-               {
-               grep(/$k/ && ($_=sprintf($m{$k}."\n",$p)),@a);
-               }
-       ($ff=$f) =~ s/\..*$//;
-       open(OUT,">$ff.new") || die "unable to open $f:$!\n";
-       print OUT @a;
-       close(OUT);
-       rename($f,"$ff.bak") || die "unable to rename $f\n";
-       rename("$ff.new",$f) || die "unable to rename $ff.new\n";
-       }
-