diff options
author | Brent Cook <busterb@gmail.com> | 2015-05-02 01:40:33 -0500 |
---|---|---|
committer | Brent Cook <busterb@gmail.com> | 2015-05-23 19:27:57 -0500 |
commit | 769d58e4946b35976c4da2ab54c56f6430a45d89 (patch) | |
tree | 5ff27229f208de7077c9e8f9894c32a1ef8f6f1f /update.sh | |
parent | d3771a41cb106c945e0f538073d0a6e7b35d145b (diff) | |
download | portable-769d58e4946b35976c4da2ab54c56f6430a45d89.tar.gz portable-769d58e4946b35976c4da2ab54c56f6430a45d89.tar.bz2 portable-769d58e4946b35976c4da2ab54c56f6430a45d89.zip |
further refactoring, working libtls-standalone
Diffstat (limited to 'update.sh')
-rwxr-xr-x | update.sh | 48 |
1 files changed, 34 insertions, 14 deletions
@@ -43,7 +43,7 @@ source $libtls_src/shlib_version | |||
43 | libtls_version=$major:$minor:0 | 43 | libtls_version=$major:$minor:0 |
44 | echo "libtls version $libtls_version" | 44 | echo "libtls version $libtls_version" |
45 | echo $libtls_version > tls/VERSION | 45 | echo $libtls_version > tls/VERSION |
46 | echo $libtls_version > libtls-standalone/VERSION | 46 | echo $major.$minor.0 > libtls-standalone/VERSION |
47 | 47 | ||
48 | do_mv() { | 48 | do_mv() { |
49 | if ! cmp -s "$1" "$2" | 49 | if ! cmp -s "$1" "$2" |
@@ -62,21 +62,35 @@ $CP $libcrypto_src/crypto/arch/amd64/opensslconf.h include/openssl | |||
62 | $CP $libssl_src/src/crypto/opensslfeatures.h include/openssl | 62 | $CP $libssl_src/src/crypto/opensslfeatures.h include/openssl |
63 | $CP $libssl_src/src/e_os2.h include/openssl | 63 | $CP $libssl_src/src/e_os2.h include/openssl |
64 | $CP $libssl_src/src/ssl/pqueue.h include | 64 | $CP $libssl_src/src/ssl/pqueue.h include |
65 | $CP $libtls_src/tls.h include | ||
66 | $CP $libtls_src/tls.h libtls-standalone/include | ||
67 | 65 | ||
68 | for i in explicit_bzero.c strlcpy.c strlcat.c strndup.c strnlen.c \ | 66 | sed -e "s/#define HEADER_TLS_H/#define HEADER_TLS_H\n#include <stddef.h>\n#include <stdint.h>/" \ |
69 | timingsafe_bcmp.c timingsafe_memcmp.c; do | 67 | $libtls_src/tls.h > include/tls.h |
70 | $CP $libc_src/string/$i crypto/compat | 68 | $CP include/tls.h libtls-standalone/include |
69 | |||
70 | for i in crypto/compat libtls-standalone/compat; do | ||
71 | $CP $libc_src/crypt/arc4random.c \ | ||
72 | $libc_src/crypt/chacha_private.h \ | ||
73 | $libc_src/string/explicit_bzero.c \ | ||
74 | $libc_src/stdlib/reallocarray.c \ | ||
75 | $libc_src/string/strlcpy.c \ | ||
76 | $libc_src/string/strlcat.c \ | ||
77 | $libc_src/string/strndup.c \ | ||
78 | $libc_src/string/strnlen.c \ | ||
79 | $libc_src/string/timingsafe_bcmp.c \ | ||
80 | $libc_src/string/timingsafe_memcmp.c \ | ||
81 | $libcrypto_src/crypto/getentropy_*.c \ | ||
82 | $libcrypto_src/crypto/arc4random_*.h \ | ||
83 | $i | ||
71 | done | 84 | done |
72 | $CP $libc_src/stdlib/reallocarray.c crypto/compat | ||
73 | $CP $libc_src/crypt/arc4random.c crypto/compat | ||
74 | $CP $libc_src/crypt/chacha_private.h crypto/compat | ||
75 | $CP $libcrypto_src/crypto/getentropy_*.c crypto/compat | ||
76 | $CP $libcrypto_src/crypto/arc4random_*.h crypto/compat | ||
77 | 85 | ||
78 | $CP $libcrypto_src/crypto/getentropy_*.c libtls-standalone/src/compat | 86 | $CP include/stdlib.h \ |
79 | $CP $libcrypto_src/crypto/arc4random_*.h libtls-standalone/src/compat | 87 | include/string.h \ |
88 | include/unistd.h \ | ||
89 | libtls-standalone/include | ||
90 | |||
91 | $CP crypto/compat/arc4random*.h \ | ||
92 | crypto/compat/bsd-asprintf.c \ | ||
93 | libtls-standalone/compat | ||
80 | 94 | ||
81 | (cd $libssl_src/src/crypto/objects/; | 95 | (cd $libssl_src/src/crypto/objects/; |
82 | perl objects.pl objects.txt obj_mac.num obj_mac.h; | 96 | perl objects.pl objects.txt obj_mac.num obj_mac.h; |
@@ -179,7 +193,13 @@ for i in `awk '/SOURCES|HEADERS/ { print $3 }' tls/Makefile.am` ; do | |||
179 | fi | 193 | fi |
180 | done | 194 | done |
181 | $CP $libc_src/string/strsep.c tls | 195 | $CP $libc_src/string/strsep.c tls |
182 | $CP $libc_src/string/strsep.c libtls-standalone/src/compat | 196 | $CP $libc_src/string/strsep.c libtls-standalone/compat |
197 | mkdir -p libtls-standalone/m4 | ||
198 | $CP m4/check*.m4 \ | ||
199 | m4/disable*.m4 \ | ||
200 | libtls-standalone/m4 | ||
201 | sed -e "s/compat\///" crypto/Makefile.am.arc4random > \ | ||
202 | libtls-standalone/compat/Makefile.am.arc4random | ||
183 | 203 | ||
184 | # copy openssl(1) source | 204 | # copy openssl(1) source |
185 | echo "copying openssl(1) source" | 205 | echo "copying openssl(1) source" |