openssl.patch (906df4f2) openssl.patch (ffb973fa)
1diff -ur misc/openssl-1.0.2t/Configure misc/build/openssl-1.0.2t/Configure
2--- misc/openssl-1.0.2t/Configure 2018-08-14 05:49:04.000000000 -0700
3+++ misc/build/openssl-1.0.2t/Configure 2018-08-26 14:51:25.397910000 -0700
1diff -ur misc/openssl-1.0.2u/Configure misc/build/openssl-1.0.2u/Configure
2--- misc/openssl-1.0.2u/Configure 2018-08-14 05:49:04.000000000 -0700
3+++ misc/build/openssl-1.0.2u/Configure 2018-08-26 14:51:25.397910000 -0700
4@@ -477,19 +477,20 @@
5 "android-mips","gcc:-mandroid -I\$(ANDROID_DEV)/include -B\$(ANDROID_DEV)/lib -O3 -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${mips32_asm}:o32:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
6
7 #### *BSD [do see comment about ${BSDthreads} above!]
8-"BSD-generic32","gcc:-O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
9-"BSD-x86", "gcc:-DL_ENDIAN -O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_asm}:a.out:dlfcn:bsd-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
10-"BSD-x86-elf", "gcc:-DL_ENDIAN -O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
11-"debug-BSD-x86-elf", "gcc:-DL_ENDIAN -O3 -Wall -g::${BSDthreads}:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",

--- 39 unchanged lines hidden (view full) ---

51 } else {
52 # No path for Perl known ...
53 &dofile("tools/c_rehash",'/usr/local/bin/perl','^#!/', '#!%s','^my \$dir;$', 'my $dir = "' . $openssldir . '";', '^my \$prefix;$', 'my $prefix = "' . $prefix . '";');
54 &dofile("apps/CA.pl",'/usr/local/bin/perl','^#!/', '#!%s');
55+ &dofile("apps/tsget",'/usr/local/bin/perl',,'^#!/', '#!%s');
56 }
57 if ($depflags ne $default_depflags && !$make_depend) {
58 $warn_make_depend++;
4@@ -477,19 +477,20 @@
5 "android-mips","gcc:-mandroid -I\$(ANDROID_DEV)/include -B\$(ANDROID_DEV)/lib -O3 -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${mips32_asm}:o32:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
6
7 #### *BSD [do see comment about ${BSDthreads} above!]
8-"BSD-generic32","gcc:-O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
9-"BSD-x86", "gcc:-DL_ENDIAN -O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_asm}:a.out:dlfcn:bsd-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
10-"BSD-x86-elf", "gcc:-DL_ENDIAN -O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
11-"debug-BSD-x86-elf", "gcc:-DL_ENDIAN -O3 -Wall -g::${BSDthreads}:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",

--- 39 unchanged lines hidden (view full) ---

51 } else {
52 # No path for Perl known ...
53 &dofile("tools/c_rehash",'/usr/local/bin/perl','^#!/', '#!%s','^my \$dir;$', 'my $dir = "' . $openssldir . '";', '^my \$prefix;$', 'my $prefix = "' . $prefix . '";');
54 &dofile("apps/CA.pl",'/usr/local/bin/perl','^#!/', '#!%s');
55+ &dofile("apps/tsget",'/usr/local/bin/perl',,'^#!/', '#!%s');
56 }
57 if ($depflags ne $default_depflags && !$make_depend) {
58 $warn_make_depend++;
59diff -ur misc/openssl-1.0.2t/config misc/build/openssl-1.0.2t/config
60--- misc/openssl-1.0.2t/config 2018-08-14 05:48:56.000000000 -0700
61+++ misc/build/openssl-1.0.2t/config 2018-08-26 14:49:34.431584000 -0700
59diff -ur misc/openssl-1.0.2u/config misc/build/openssl-1.0.2u/config
60--- misc/openssl-1.0.2u/config 2018-08-14 05:48:56.000000000 -0700
61+++ misc/build/openssl-1.0.2u/config 2018-08-26 14:49:34.431584000 -0700
62@@ -762,14 +762,8 @@
63 sparc64-*-*bsd*) OUT="BSD-sparc64" ;;
64 ia64-*-*bsd*) OUT="BSD-ia64" ;;
65 amd64-*-*bsd*) OUT="BSD-x86_64" ;;
66- *86*-*-*bsd*) # mimic ld behaviour when it's looking for libc...
67- if [ -L /usr/lib/libc.so ]; then # [Free|Net]BSD
68- libc=/usr/lib/libc.so
69- else # OpenBSD
70- # ld searches for highest libc.so.* and so do we
71- libc=`(ls /usr/lib/libc.so.* /lib/libc.so.* | tail -1) 2>/dev/null`
72- fi
73- case "`(file -L $libc) 2>/dev/null`" in
74+ *86*-*-*bsd*)
75+ case "`(file -L /bin/sh) 2>/dev/null`" in
76 *ELF*) OUT="BSD-x86-elf" ;;
77 *) OUT="BSD-x86"; options="$options no-sse2" ;;
78 esac ;;
62@@ -762,14 +762,8 @@
63 sparc64-*-*bsd*) OUT="BSD-sparc64" ;;
64 ia64-*-*bsd*) OUT="BSD-ia64" ;;
65 amd64-*-*bsd*) OUT="BSD-x86_64" ;;
66- *86*-*-*bsd*) # mimic ld behaviour when it's looking for libc...
67- if [ -L /usr/lib/libc.so ]; then # [Free|Net]BSD
68- libc=/usr/lib/libc.so
69- else # OpenBSD
70- # ld searches for highest libc.so.* and so do we
71- libc=`(ls /usr/lib/libc.so.* /lib/libc.so.* | tail -1) 2>/dev/null`
72- fi
73- case "`(file -L $libc) 2>/dev/null`" in
74+ *86*-*-*bsd*)
75+ case "`(file -L /bin/sh) 2>/dev/null`" in
76 *ELF*) OUT="BSD-x86-elf" ;;
77 *) OUT="BSD-x86"; options="$options no-sse2" ;;
78 esac ;;
79diff -ur misc/openssl-1.0.2t/ms/do_ms.bat misc/build/openssl-1.0.2t/ms/do_ms.bat
80--- misc/openssl-1.0.2t/ms/do_ms.bat 2018-08-14 05:48:59.000000000 -0700
81+++ misc/build/openssl-1.0.2t/ms/do_ms.bat 2018-08-26 14:49:34.432106000 -0700
79diff -ur misc/openssl-1.0.2u/ms/do_ms.bat misc/build/openssl-1.0.2u/ms/do_ms.bat
80--- misc/openssl-1.0.2u/ms/do_ms.bat 2018-08-14 05:48:59.000000000 -0700
81+++ misc/build/openssl-1.0.2u/ms/do_ms.bat 2018-08-26 14:49:34.432106000 -0700
82@@ -1,11 +1,11 @@
83
84-perl util\mkfiles.pl >MINFO
85-perl util\mk1mf.pl no-asm VC-WIN32 >ms\nt.mak
86-perl util\mk1mf.pl dll no-asm VC-WIN32 >ms\ntdll.mak
87+%1 util\mkfiles.pl >MINFO
88+%1 util\mk1mf.pl no-asm VC-WIN32 >ms\nt.mak
89+%1 util\mk1mf.pl dll no-asm VC-WIN32 >ms\ntdll.mak
90 if x%OSVERSION% == x goto skipce
91-perl util\mk1mf.pl no-asm VC-CE >ms\ce.mak
92-perl util\mk1mf.pl dll no-asm VC-CE >ms\cedll.mak
93+%1 util\mk1mf.pl no-asm VC-CE >ms\ce.mak
94+%1 util\mk1mf.pl dll no-asm VC-CE >ms\cedll.mak
95 :skipce
96
97-perl util\mkdef.pl 32 libeay > ms\libeay32.def
98-perl util\mkdef.pl 32 ssleay > ms\ssleay32.def
99+%1 util\mkdef.pl 32 libeay > ms\libeay32.def
100+%1 util\mkdef.pl 32 ssleay > ms\ssleay32.def
82@@ -1,11 +1,11 @@
83
84-perl util\mkfiles.pl >MINFO
85-perl util\mk1mf.pl no-asm VC-WIN32 >ms\nt.mak
86-perl util\mk1mf.pl dll no-asm VC-WIN32 >ms\ntdll.mak
87+%1 util\mkfiles.pl >MINFO
88+%1 util\mk1mf.pl no-asm VC-WIN32 >ms\nt.mak
89+%1 util\mk1mf.pl dll no-asm VC-WIN32 >ms\ntdll.mak
90 if x%OSVERSION% == x goto skipce
91-perl util\mk1mf.pl no-asm VC-CE >ms\ce.mak
92-perl util\mk1mf.pl dll no-asm VC-CE >ms\cedll.mak
93+%1 util\mk1mf.pl no-asm VC-CE >ms\ce.mak
94+%1 util\mk1mf.pl dll no-asm VC-CE >ms\cedll.mak
95 :skipce
96
97-perl util\mkdef.pl 32 libeay > ms\libeay32.def
98-perl util\mkdef.pl 32 ssleay > ms\ssleay32.def
99+%1 util\mkdef.pl 32 libeay > ms\libeay32.def
100+%1 util\mkdef.pl 32 ssleay > ms\ssleay32.def
101diff -ur misc/openssl-1.0.2t/ms/do_win64a.bat misc/build/openssl-1.0.2t/ms/do_win64a.bat
102--- misc/openssl-1.0.2t/ms/do_win64a.bat 2018-08-14 05:48:59.000000000 -0700
103+++ misc/build/openssl-1.0.2t/ms/do_win64a.bat 2018-08-26 14:49:34.432647000 -0700
101diff -ur misc/openssl-1.0.2u/ms/do_win64a.bat misc/build/openssl-1.0.2u/ms/do_win64a.bat
102--- misc/openssl-1.0.2u/ms/do_win64a.bat 2018-08-14 05:48:59.000000000 -0700
103+++ misc/build/openssl-1.0.2u/ms/do_win64a.bat 2018-08-26 14:49:34.432647000 -0700
104@@ -1,19 +1,19 @@
105-perl util\mkfiles.pl >MINFO
106+%1 util\mkfiles.pl >MINFO
107
108 cmd /c "nasm -f win64 -v" >NUL 2>&1
109 if %errorlevel% neq 0 goto ml64
110
111-perl ms\uplink-x86_64.pl nasm > ms\uptable.asm

--- 11 unchanged lines hidden (view full) ---

123-perl util\mk1mf.pl dll VC-WIN64A >ms\ntdll.mak
124+%1 util\mk1mf.pl VC-WIN64A >ms\nt.mak
125+%1 util\mk1mf.pl dll VC-WIN64A >ms\ntdll.mak
126
127-perl util\mkdef.pl 32 libeay > ms\libeay32.def
128-perl util\mkdef.pl 32 ssleay > ms\ssleay32.def
129+%1 util\mkdef.pl 32 libeay > ms\libeay32.def
130+%1 util\mkdef.pl 32 ssleay > ms\ssleay32.def
104@@ -1,19 +1,19 @@
105-perl util\mkfiles.pl >MINFO
106+%1 util\mkfiles.pl >MINFO
107
108 cmd /c "nasm -f win64 -v" >NUL 2>&1
109 if %errorlevel% neq 0 goto ml64
110
111-perl ms\uplink-x86_64.pl nasm > ms\uptable.asm

--- 11 unchanged lines hidden (view full) ---

123-perl util\mk1mf.pl dll VC-WIN64A >ms\ntdll.mak
124+%1 util\mk1mf.pl VC-WIN64A >ms\nt.mak
125+%1 util\mk1mf.pl dll VC-WIN64A >ms\ntdll.mak
126
127-perl util\mkdef.pl 32 libeay > ms\libeay32.def
128-perl util\mkdef.pl 32 ssleay > ms\ssleay32.def
129+%1 util\mkdef.pl 32 libeay > ms\libeay32.def
130+%1 util\mkdef.pl 32 ssleay > ms\ssleay32.def
131diff -ur misc/openssl-1.0.2t/util/mk1mf.pl misc/build/openssl-1.0.2t/util/mk1mf.pl
132--- misc/openssl-1.0.2t/util/mk1mf.pl 2018-08-14 05:48:59.000000000 -0700
133+++ misc/build/openssl-1.0.2t/util/mk1mf.pl 2018-08-26 14:49:34.433421000 -0700
131diff -ur misc/openssl-1.0.2u/util/mk1mf.pl misc/build/openssl-1.0.2u/util/mk1mf.pl
132--- misc/openssl-1.0.2u/util/mk1mf.pl 2018-08-14 05:48:59.000000000 -0700
133+++ misc/build/openssl-1.0.2u/util/mk1mf.pl 2018-08-26 14:49:34.433421000 -0700
134@@ -163,7 +163,7 @@
135 $inc_def="outinc";
136 $tmp_def="tmp";
137
138-$perl="perl" unless defined $perl;
139+$perl="$ENV{PERL}" unless defined $perl;
140 $mkdir="-mkdir" unless defined $mkdir;
141

--- 5 unchanged lines hidden (view full) ---

147+
148+ # On some Windows machines, $val has linefeeds at the end, which confuses
149+ # subsequent code in this file. So we strip all whitespace at the end.
150+ $val =~ s/\s+$//;
151+
152 if ($key eq "RELATIVE_DIRECTORY")
153 {
154 if ($lib ne "")
134@@ -163,7 +163,7 @@
135 $inc_def="outinc";
136 $tmp_def="tmp";
137
138-$perl="perl" unless defined $perl;
139+$perl="$ENV{PERL}" unless defined $perl;
140 $mkdir="-mkdir" unless defined $mkdir;
141

--- 5 unchanged lines hidden (view full) ---

147+
148+ # On some Windows machines, $val has linefeeds at the end, which confuses
149+ # subsequent code in this file. So we strip all whitespace at the end.
150+ $val =~ s/\s+$//;
151+
152 if ($key eq "RELATIVE_DIRECTORY")
153 {
154 if ($lib ne "")
155diff -ur misc/openssl-1.0.2t/util/pl/VC-32.pl misc/build/openssl-1.0.2t/util/pl/VC-32.pl
156--- misc/openssl-1.0.2t/util/pl/VC-32.pl 2018-08-14 05:48:59.000000000 -0700
157+++ misc/build/openssl-1.0.2t/util/pl/VC-32.pl 2018-08-26 14:49:57.553776000 -0700
155diff -ur misc/openssl-1.0.2u/util/pl/VC-32.pl misc/build/openssl-1.0.2u/util/pl/VC-32.pl
156--- misc/openssl-1.0.2u/util/pl/VC-32.pl 2018-08-14 05:48:59.000000000 -0700
157+++ misc/build/openssl-1.0.2u/util/pl/VC-32.pl 2018-08-26 14:49:57.553776000 -0700
158@@ -30,7 +30,7 @@
159 my $ff = "";
160
161 # C compiler stuff
162-$cc='cl';
163+$cc=$ENV{'CC'};
164 if ($FLAVOR =~ /WIN64/)
165 {
166 # Note that we currently don't have /WX on Win64! There is a lot of
158@@ -30,7 +30,7 @@
159 my $ff = "";
160
161 # C compiler stuff
162-$cc='cl';
163+$cc=$ENV{'CC'};
164 if ($FLAVOR =~ /WIN64/)
165 {
166 # Note that we currently don't have /WX on Win64! There is a lot of