Update err.h to use the new lhash generation code
authorMatt Caswell <matt@openssl.org>
Fri, 11 Sep 2020 12:51:58 +0000 (13:51 +0100)
committerMatt Caswell <matt@openssl.org>
Fri, 18 Sep 2020 12:30:44 +0000 (13:30 +0100)
Generate the lhash macros for the ERR_STRING_DATA type

Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/12860)

.gitignore
build.info
include/openssl/err.h.in [moved from include/openssl/err.h with 99% similarity]

index 8f4bc6af85b549bccd10a3acd2f994b19d9863bf..a463fc3c96a1b442c02ecdede75253623917f577 100644 (file)
@@ -32,6 +32,7 @@
 /include/openssl/crmf.h
 /include/openssl/crypto.h
 /include/openssl/ct.h
+/include/openssl/err.h
 /include/openssl/ess.h
 /include/openssl/fipskey.h
 /include/openssl/ocsp.h
index 8aa668e9139b1dbc8c6a89f4e2ee6538a7f09763..dc239a706d1ed1f57984de0eac6dd1ca9219dd59 100644 (file)
@@ -23,6 +23,7 @@ DEPEND[]=include/openssl/asn1.h \
          include/openssl/crmf.h \
          include/openssl/crypto.h \
          include/openssl/ct.h \
+         include/openssl/err.h \
          include/openssl/ess.h \
          include/openssl/fipskey.h \
          include/openssl/opensslv.h \
@@ -49,6 +50,7 @@ GENERATE[include/openssl/configuration.h]=include/openssl/configuration.h.in
 GENERATE[include/openssl/crmf.h]=include/openssl/crmf.h.in
 GENERATE[include/openssl/crypto.h]=include/openssl/crypto.h.in
 GENERATE[include/openssl/ct.h]=include/openssl/ct.h.in
+GENERATE[include/openssl/err.h]=include/openssl/err.h.in
 GENERATE[include/openssl/ess.h]=include/openssl/ess.h.in
 GENERATE[include/openssl/fipskey.h]=include/openssl/fipskey.h.in
 GENERATE[include/openssl/ocsp.h]=include/openssl/ocsp.h.in
similarity index 99%
rename from include/openssl/err.h
rename to include/openssl/err.h.in
index 8e76b812df45d5fc3f13a53fe90a597711066ab7..b916f436e33ed32fe5c3370c86d6a7afc3a5ae4a 100644 (file)
@@ -7,6 +7,10 @@
  * https://www.openssl.org/source/license.html
  */
 
+{-
+use OpenSSL::stackhash qw(generate_lhash_macros);
+-}
+
 #ifndef OPENSSL_ERR_H
 # define OPENSSL_ERR_H
 # pragma once
@@ -337,7 +341,9 @@ typedef struct ERR_string_data_st {
     const char *string;
 } ERR_STRING_DATA;
 
-DEFINE_LHASH_OF(ERR_STRING_DATA);
+{-
+    generate_lhash_macros("ERR_STRING_DATA");
+-}
 
 /* 12 lines and some on an 80 column terminal */
 #define ERR_MAX_DATA_SIZE       1024