]> git.proxmox.com Git - mirror_ovs.git/commitdiff
dhparams: Fix .c file generation with OpenSSL >= 1.1.1-pre9
authorTimothy Redaelli <tredaelli@redhat.com>
Fri, 7 Sep 2018 13:14:53 +0000 (15:14 +0200)
committerBen Pfaff <blp@ovn.org>
Fri, 7 Sep 2018 16:57:43 +0000 (09:57 -0700)
Since OpenSSL upstream commit 201b305a2409
("apps/dsaparam.c generates code that is intended to be pasted or included into
an existing source file: the function is static, and the code doesn't include
dsa.h.  Match the generated C source style of dsaparam.") "openssl dhparam -C"
generates the get_dh functions as static, but the functions are used inside
stream-ssl.c and so the static keyword cannot be used.

This commit removes the static keyword from the get_dh functions during
dhparams.c file generation by restoring the current behaviour.

Signed-off-by: Timothy Redaelli <tredaelli@redhat.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
build-aux/generate-dhparams-c

index 5d5bba2133450610975199003a8a7ac987416cbd..dfbdb1f2e4393e6283e23c17e979e381184d1735 100755 (executable)
@@ -25,6 +25,7 @@ EOF
 (openssl dhparam -C -in lib/dh1024.pem -noout &&
 openssl dhparam -C -in lib/dh2048.pem -noout &&
 openssl dhparam -C -in lib/dh4096.pem -noout) | sed '
+    s/^static DH/DH/
     s/\(get_dh[0-9]*\)()/\1(void)/
     s/\(DH_set0_pqg\)/my_\1/
     s/[        ]*$//