libcrypto: Raise WARNS to 2 and remove HAVE_CRYPTODEV definition. master
authorRobin Hahling <robin.hahling@gw-computing.net>
Sat, 31 Jan 2015 10:06:38 +0000 (11:06 +0100)
committerSascha Wildner <saw@online.de>
Sat, 31 Jan 2015 20:17:46 +0000 (21:17 +0100)
Add DragonFly as supporting cryptodev to vendor sources instead of
using HAVE_CRYPTODEV for it (which led to a redefinition warning).

This patch will be submitted upstream.

crypto/openssl/crypto/engine/eng_all.c
crypto/openssl/crypto/engine/engine.h
crypto/openssl/crypto/evp/c_all.c
secure/lib/libcrypto/Makefile

index 6093376..45baae8 100644 (file)
@@ -70,7 +70,7 @@ void ENGINE_load_builtin_engines(void)
         * *no* builtin implementations). */
        ENGINE_load_openssl();
 #endif
-#if !defined(OPENSSL_NO_HW) && (defined(__OpenBSD__) || defined(__FreeBSD__) || defined(HAVE_CRYPTODEV))
+#if !defined(OPENSSL_NO_HW) && (defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(HAVE_CRYPTODEV))
        ENGINE_load_cryptodev();
 #endif
 #ifndef OPENSSL_NO_RSAX
@@ -123,7 +123,7 @@ void ENGINE_load_builtin_engines(void)
        ENGINE_register_all_complete();
        }
 
-#if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(HAVE_CRYPTODEV)
+#if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(HAVE_CRYPTODEV)
 void ENGINE_setup_bsd_cryptodev(void) {
        static int bsd_cryptodev_default_loaded = 0;
        if (!bsd_cryptodev_default_loaded) {
index f8be497..169a7b9 100644 (file)
@@ -740,7 +740,7 @@ typedef int (*dynamic_bind_engine)(ENGINE *e, const char *id,
  * values. */
 void *ENGINE_get_static_state(void);
 
-#if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(HAVE_CRYPTODEV)
+#if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(HAVE_CRYPTODEV)
 void ENGINE_setup_bsd_cryptodev(void);
 #endif
 
index 766c4ce..90174a7 100644 (file)
@@ -83,7 +83,7 @@ void OPENSSL_add_all_algorithms_noconf(void)
        OpenSSL_add_all_ciphers();
        OpenSSL_add_all_digests();
 #ifndef OPENSSL_NO_ENGINE
-# if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(HAVE_CRYPTODEV)
+# if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(HAVE_CRYPTODEV)
        ENGINE_setup_bsd_cryptodev();
 # endif
 #endif
index 804e293..fe3ae7f 100644 (file)
@@ -3,7 +3,7 @@
 LIB=           crypto
 SHLIB_MAJOR=   5
 SHLIBDIR?=     /lib
-WARNS?=                0
+WARNS?=                2
 
 SUBDIR=        engines
 
@@ -186,7 +186,6 @@ SRCS+=      ecs_lib.c ecs_asn1.c ecs_ossl.c ecs_sign.c ecs_vrf.c ecs_err.c
 INCS+= ecdsa.h
 
 # engine
-CFLAGS+=-DHAVE_CRYPTODEV
 SRCS+= eng_err.c eng_lib.c eng_list.c eng_init.c eng_ctrl.c \
        eng_table.c eng_pkey.c eng_fat.c eng_all.c \
        tb_rsa.c tb_dsa.c tb_ecdsa.c tb_dh.c tb_ecdh.c tb_rand.c tb_store.c \