More method functions for elliptic curves,
[openssl.git] / crypto / cversion.c
index 3933a0c37a1a8ed1f6febbbaa3ecdd2fcfaa12bc..8ecfba7b16bac1dac3dd368589a10fbf49b0b402 100644 (file)
 #include <stdio.h>
 #include <string.h>
 #include "cryptlib.h"
-#include "crypto.h"
-#include "date.h"
+#include <openssl/crypto.h>
 
-const char *SSLeay_version(t)
-int t;
+#include "buildinf.h"
+
+const char *SSLeay_version(int t)
        {
        if (t == SSLEAY_VERSION)
                return OPENSSL_VERSION_TEXT;
@@ -73,7 +73,7 @@ int t;
                static char buf[sizeof(DATE)+11];
 
                sprintf(buf,"built on: %s",DATE);
-               return(buf);
+               return(buf);
 #else
                return("built on: date not available");
 #endif
@@ -98,12 +98,20 @@ int t;
                return(buf);
 #else
                return("platform: information not available");
+#endif
+               }
+       if (t == SSLEAY_DIR)
+               {
+#ifdef OPENSSLDIR
+               return "OPENSSLDIR: \"" OPENSSLDIR "\"";
+#else
+               return "OPENSSLDIR: N/A";
 #endif
                }
        return("not available");
        }
 
-unsigned long SSLeay()
+unsigned long SSLeay(void)
        {
        return(SSLEAY_VERSION_NUMBER);
        }