summaryrefslogtreecommitdiffstats
path: root/Configurations
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2018-09-14 15:28:39 +0200
committerRichard Levitte <levitte@openssl.org>2018-10-04 12:45:40 +0200
commit30699aa1943b10b265c52334d9f582c04c4eccba (patch)
treec820264486045952cfb0d3734e08684afd964ec0 /Configurations
parent15ba109631254b98d3ef2611a1765e75442314a6 (diff)
Refactor util/mknum.pl for clearer separation of functionality
Rewrite util/mknum.pl to become cleaner, and to use the separate generic C header parsing module, as well as the separate ordinals manipulation module. Adapt the build files. Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7191)
Diffstat (limited to 'Configurations')
-rw-r--r--Configurations/unix-Makefile.tmpl42
1 files changed, 40 insertions, 2 deletions
diff --git a/Configurations/unix-Makefile.tmpl b/Configurations/unix-Makefile.tmpl
index 153d5cc40e..662fb05229 100644
--- a/Configurations/unix-Makefile.tmpl
+++ b/Configurations/unix-Makefile.tmpl
@@ -809,9 +809,47 @@ errors:
-conf $$E `basename $$E .ec`.c ; \
done )
+{- use File::Basename;
+
+ our @sslheaders =
+ qw( include/openssl/ssl.h
+ include/openssl/ssl2.h
+ include/openssl/ssl3.h
+ include/openssl/sslerr.h
+ include/openssl/tls1.h
+ include/openssl/dtls1.h
+ include/openssl/srtp.h );
+ our @cryptoheaders =
+ qw( include/internal/dso.h
+ include/internal/o_dir.h
+ include/internal/o_str.h
+ include/internal/err.h
+ include/internal/sslconf.h );
+ our @cryptoskipheaders = ( @sslheaders,
+ qw( include/openssl/conf_api.h
+ include/openssl/ebcdic.h
+ include/openssl/opensslconf.h
+ include/openssl/symhacks.h ) );
+ foreach my $f ( glob(catfile($config{sourcedir},
+ 'include','openssl','*.h')) ) {
+ my $fn = "include/openssl/" . basename($f);
+ push @cryptoheaders, $fn unless grep { $_ eq $fn } @cryptoskipheaders;
+ }
+ "";
+-}
+CRYPTOHEADERS={- join(" \\\n\t", sort @cryptoheaders) -}
+SSLHEADERS={- join(" \\\n\t", sort @sslheaders) -}
ordinals:
- ( b=`pwd`; cd $(SRCDIR); $(PERL) -I$$b util/mknum.pl crypto update )
- ( b=`pwd`; cd $(SRCDIR); $(PERL) -I$$b util/mknum.pl ssl update )
+ ( cd $(SRCDIR); \
+ $(PERL) util/mknum.pl --version $(VERSION) --no-warnings \
+ --ordinals util/libcrypto.num \
+ --symhacks include/openssl/symhacks.h \
+ $(CRYPTOHEADERS) )
+ ( cd $(SRCDIR); \
+ $(PERL) util/mknum.pl --version $(VERSION) --no-warnings \
+ --ordinals util/libssl.num \
+ --symhacks include/openssl/symhacks.h \
+ $(SSLHEADERS))
test_ordinals:
( cd test; \