summaryrefslogtreecommitdiffstats
path: root/lib/libssl/src/util
diff options
context:
space:
mode:
authormarkus <markus@openbsd.org>2002-09-10 16:31:53 +0000
committermarkus <markus@openbsd.org>2002-09-10 16:31:53 +0000
commit1f9308f95cf5f2eb77b454500c9bb49d76673ef3 (patch)
treec6825952eba2bd0bea9ff46656b25ab7eea8284b /lib/libssl/src/util
parentUpdate list of supported CMD and Promise devices. (diff)
downloadwireguard-openbsd-1f9308f95cf5f2eb77b454500c9bb49d76673ef3.tar.xz
wireguard-openbsd-1f9308f95cf5f2eb77b454500c9bb49d76673ef3.zip
merge openssl-0.9.7-beta3, tested on vax by miod@
Diffstat (limited to 'lib/libssl/src/util')
-rw-r--r--lib/libssl/src/util/domd4
-rw-r--r--lib/libssl/src/util/libeay.num24
-rw-r--r--lib/libssl/src/util/mk1mf.pl2
-rw-r--r--lib/libssl/src/util/mkdef.pl46
-rw-r--r--lib/libssl/src/util/mklink.pl15
-rw-r--r--lib/libssl/src/util/pl/BC-32.pl42
-rw-r--r--lib/libssl/src/util/pl/VC-32.pl36
-rw-r--r--lib/libssl/src/util/point.sh6
8 files changed, 111 insertions, 64 deletions
diff --git a/lib/libssl/src/util/domd b/lib/libssl/src/util/domd
index aa99cb05236..8cbe383c165 100644
--- a/lib/libssl/src/util/domd
+++ b/lib/libssl/src/util/domd
@@ -18,11 +18,11 @@ if [ "$MAKEDEPEND" = "gcc" ]; then
sed -e '/^# DO NOT DELETE.*/,$d' < Makefile.ssl > Makefile.tmp
echo '# DO NOT DELETE THIS LINE -- make depend depends on it.' >> Makefile.tmp
gcc -D OPENSSL_DOING_MAKEDEPEND -M $@ >> Makefile.tmp
- perl $TOP/util/clean-depend.pl < Makefile.tmp > Makefile.new
+ ${PERL} $TOP/util/clean-depend.pl < Makefile.tmp > Makefile.new
rm -f Makefile.tmp
else
${MAKEDEPEND} -D OPENSSL_DOING_MAKEDEPEND -f Makefile.ssl $@
- perl $TOP/util/clean-depend.pl < Makefile.ssl > Makefile.new
+ ${PERL} $TOP/util/clean-depend.pl < Makefile.ssl > Makefile.new
fi
mv Makefile.new Makefile.ssl
# unfake the presence of Kerberos
diff --git a/lib/libssl/src/util/libeay.num b/lib/libssl/src/util/libeay.num
index 4845158158f..512185e2573 100644
--- a/lib/libssl/src/util/libeay.num
+++ b/lib/libssl/src/util/libeay.num
@@ -701,7 +701,7 @@ bn_mul_words 707 EXIST::FUNCTION:
BN_uadd 708 EXIST::FUNCTION:
BN_usub 709 EXIST::FUNCTION:
bn_sqr_words 710 EXIST::FUNCTION:
-_ossl_old_crypt 711 EXIST:!NeXT,!PERL5,!__FreeBSD__:FUNCTION:DES
+_ossl_old_crypt 711 EXIST:!NeXT,!PERL5:FUNCTION:DES
d2i_ASN1_BIT_STRING 712 EXIST::FUNCTION:
d2i_ASN1_BOOLEAN 713 EXIST::FUNCTION:
d2i_ASN1_HEADER 714 EXIST::FUNCTION:
@@ -984,8 +984,8 @@ BIO_ghbn_ctrl 1003 EXIST::FUNCTION:
CRYPTO_free_ex_data 1004 EXIST::FUNCTION:
CRYPTO_get_ex_data 1005 EXIST::FUNCTION:
CRYPTO_set_ex_data 1007 EXIST::FUNCTION:
-ERR_load_CRYPTO_strings 1009 EXIST:!VMS,!WIN16:FUNCTION:
-ERR_load_CRYPTOlib_strings 1009 EXIST:VMS,WIN16:FUNCTION:
+ERR_load_CRYPTO_strings 1009 EXIST:!OS2,!VMS,!WIN16:FUNCTION:
+ERR_load_CRYPTOlib_strings 1009 EXIST:OS2,VMS,WIN16:FUNCTION:
EVP_PKEY_bits 1010 EXIST::FUNCTION:
MD5_Transform 1011 EXIST::FUNCTION:MD5
SHA1_Transform 1012 EXIST::FUNCTION:SHA,SHA1
@@ -1216,7 +1216,7 @@ name_cmp 1239 EXIST::FUNCTION:
str_dup 1240 NOEXIST::FUNCTION:
i2s_ASN1_ENUMERATED 1241 EXIST::FUNCTION:
i2s_ASN1_ENUMERATED_TABLE 1242 EXIST::FUNCTION:
-BIO_s_log 1243 EXIST:!WIN16,!WIN32,!macintosh:FUNCTION:
+BIO_s_log 1243 EXIST:!OS2,!WIN16,!WIN32,!macintosh:FUNCTION:
BIO_f_reliable 1244 EXIST::FUNCTION:BIO
PKCS7_dataFinal 1245 EXIST::FUNCTION:
PKCS7_dataDecode 1246 EXIST::FUNCTION:
@@ -2732,8 +2732,8 @@ EC_POINT_point2oct 3178 EXIST::FUNCTION:EC
KRB5_APREQ_free 3179 EXIST::FUNCTION:
ASN1_OBJECT_it 3180 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
ASN1_OBJECT_it 3180 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
-OCSP_crlID_new 3181 EXIST:!VMS,!WIN16:FUNCTION:
-OCSP_crlID2_new 3181 EXIST:VMS,WIN16:FUNCTION:
+OCSP_crlID_new 3181 EXIST:!OS2,!VMS,!WIN16:FUNCTION:
+OCSP_crlID2_new 3181 EXIST:OS2,VMS,WIN16:FUNCTION:
CONF_modules_load_file 3182 EXIST::FUNCTION:
CONF_imodule_set_usr_data 3183 EXIST::FUNCTION:
ENGINE_set_default_string 3184 EXIST::FUNCTION:
@@ -2780,3 +2780,15 @@ EVP_aes_128_cfb 3222 EXIST::FUNCTION:AES
EVP_aes_256_cfb 3223 EXIST::FUNCTION:AES
EVP_aes_128_ofb 3224 EXIST::FUNCTION:AES
EVP_aes_192_cfb 3225 EXIST::FUNCTION:AES
+CONF_modules_free 3226 EXIST::FUNCTION:
+NCONF_default 3227 EXIST::FUNCTION:
+OPENSSL_no_config 3228 EXIST::FUNCTION:
+NCONF_WIN32 3229 EXIST::FUNCTION:
+ASN1_UNIVERSALSTRING_new 3230 EXIST::FUNCTION:
+EVP_des_ede_ecb 3231 EXIST::FUNCTION:DES
+i2d_ASN1_UNIVERSALSTRING 3232 EXIST::FUNCTION:
+ASN1_UNIVERSALSTRING_free 3233 EXIST::FUNCTION:
+ASN1_UNIVERSALSTRING_it 3234 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
+ASN1_UNIVERSALSTRING_it 3234 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
+d2i_ASN1_UNIVERSALSTRING 3235 EXIST::FUNCTION:
+EVP_des_ede3_ecb 3236 EXIST::FUNCTION:DES
diff --git a/lib/libssl/src/util/mk1mf.pl b/lib/libssl/src/util/mk1mf.pl
index 8b6b2e668ae..c9271bbffee 100644
--- a/lib/libssl/src/util/mk1mf.pl
+++ b/lib/libssl/src/util/mk1mf.pl
@@ -100,7 +100,7 @@ $out_def="out";
$inc_def="outinc";
$tmp_def="tmp";
-$mkdir="mkdir";
+$mkdir="-mkdir";
($ssl,$crypto)=("ssl","crypto");
$ranlib="echo ranlib";
diff --git a/lib/libssl/src/util/mkdef.pl b/lib/libssl/src/util/mkdef.pl
index ecba93cd948..adfd447dd31 100644
--- a/lib/libssl/src/util/mkdef.pl
+++ b/lib/libssl/src/util/mkdef.pl
@@ -58,6 +58,7 @@ my $debug=0;
my $crypto_num= "util/libeay.num";
my $ssl_num= "util/ssleay.num";
+my $libname;
my $do_update = 0;
my $do_rewrite = 1;
@@ -73,12 +74,13 @@ my $VMS=0;
my $W32=0;
my $W16=0;
my $NT=0;
+my $OS2=0;
# Set this to make typesafe STACK definitions appear in DEF
my $safe_stack_def = 0;
my @known_platforms = ( "__FreeBSD__", "PERL5", "NeXT",
"EXPORT_VAR_AS_FUNCTION" );
-my @known_ossl_platforms = ( "VMS", "WIN16", "WIN32", "WINNT" );
+my @known_ossl_platforms = ( "VMS", "WIN16", "WIN32", "WINNT", "OS2" );
my @known_algorithms = ( "RC2", "RC4", "RC5", "IDEA", "DES", "BF",
"CAST", "MD2", "MD4", "MD5", "SHA", "SHA0", "SHA1",
"RIPEMD",
@@ -126,11 +128,18 @@ foreach (@ARGV, split(/ /, $options))
$VMSAlpha=1;
}
$VMS=1 if $_ eq "VMS";
+ $OS2=1 if $_ eq "OS2";
$do_ssl=1 if $_ eq "ssleay";
- $do_ssl=1 if $_ eq "ssl";
+ if ($_ eq "ssl") {
+ $do_ssl=1;
+ $libname=$_
+ }
$do_crypto=1 if $_ eq "libeay";
- $do_crypto=1 if $_ eq "crypto";
+ if ($_ eq "crypto") {
+ $do_crypto=1;
+ $libname=$_;
+ }
$do_update=1 if $_ eq "update";
$do_rewrite=1 if $_ eq "rewrite";
$do_ctest=1 if $_ eq "ctest";
@@ -170,8 +179,17 @@ foreach (@ARGV, split(/ /, $options))
}
+if (!$libname) {
+ if ($do_ssl) {
+ $libname="SSLEAY";
+ }
+ if ($do_crypto) {
+ $libname="LIBEAY";
+ }
+}
+
# If no platform is given, assume WIN32
-if ($W32 + $W16 + $VMS == 0) {
+if ($W32 + $W16 + $VMS + $OS2 == 0) {
$W32 = 1;
}
@@ -182,7 +200,7 @@ if ($W16) {
if (!$do_ssl && !$do_crypto)
{
- print STDERR "usage: $0 ( ssl | crypto ) [ 16 | 32 | NT ]\n";
+ print STDERR "usage: $0 ( ssl | crypto ) [ 16 | 32 | NT | OS2 ]\n";
exit(1);
}
@@ -305,10 +323,10 @@ EOF
} else {
- &print_def_file(*STDOUT,"SSLEAY",*ssl_list,@ssl_symbols)
+ &print_def_file(*STDOUT,$libname,*ssl_list,@ssl_symbols)
if $do_ssl == 1;
- &print_def_file(*STDOUT,"LIBEAY",*crypto_list,@crypto_symbols)
+ &print_def_file(*STDOUT,$libname,*crypto_list,@crypto_symbols)
if $do_crypto == 1;
}
@@ -995,6 +1013,7 @@ sub is_valid
if ($keyword eq "WIN32" && $W32) { return 1; }
if ($keyword eq "WIN16" && $W16) { return 1; }
if ($keyword eq "WINNT" && $NT) { return 1; }
+ if ($keyword eq "OS2" && $OS2) { return 1; }
# Special platforms:
# EXPORT_VAR_AS_FUNCTION means that global variables
# will be represented as functions. This currently
@@ -1092,24 +1111,27 @@ sub print_def_file
{
(*OUT,my $name,*nums,my @symbols)=@_;
my $n = 1; my @e; my @r; my @v; my $prev="";
+ my $liboptions="";
if ($W32)
{ $name.="32"; }
- else
+ elsif ($W16)
{ $name.="16"; }
+ elsif ($OS2)
+ { $liboptions = "INITINSTANCE\nDATA NONSHARED"; }
print OUT <<"EOF";
;
; Definition file for the DLL version of the $name library from OpenSSL
;
-LIBRARY $name
+LIBRARY $name $liboptions
DESCRIPTION 'OpenSSL $name - http://www.openssl.org/'
EOF
- if (!$W32) {
+ if ($W16) {
print <<"EOF";
CODE PRELOAD MOVEABLE
DATA PRELOAD MOVEABLE SINGLE
@@ -1148,10 +1170,10 @@ EOF
print STDERR "Warning: Symbol '",$s2,"' redefined. old=",($nums{$prev} =~ /^(.*?)\\/,$1),", new=",($nums{$s2} =~ /^(.*?)\\/,$1),"\n";
}
$prev = $s2; # To warn about duplicates...
- if($v) {
+ if($v && !$OS2) {
printf OUT " %s%-39s @%-8d DATA\n",($W32)?"":"_",$s2,$n;
} else {
- printf OUT " %s%-39s @%d\n",($W32)?"":"_",$s2,$n;
+ printf OUT " %s%-39s @%d\n",($W32||$OS2)?"":"_",$s2,$n;
}
}
}
diff --git a/lib/libssl/src/util/mklink.pl b/lib/libssl/src/util/mklink.pl
index 9e9c9a51467..9386da7aa4c 100644
--- a/lib/libssl/src/util/mklink.pl
+++ b/lib/libssl/src/util/mklink.pl
@@ -18,10 +18,10 @@
my $from = shift;
my @files = @ARGV;
-my @from_path = split(/\//, $from);
+my @from_path = split(/[\\\/]/, $from);
my $pwd = `pwd`;
chop($pwd);
-my @pwd_path = split(/\//, $pwd);
+my @pwd_path = split(/[\\\/]/, $pwd);
my @to_path = ();
@@ -54,7 +54,16 @@ foreach $file (@files) {
if ($symlink_exists) {
symlink("$to/$file", "$from/$file") or $err = " [$!]";
} else {
- system ("cp", "$file", "$from/$file") and $err = " [$!]";
+ unlink "$from/$file";
+ open (OLD, "<$file") or die "Can't open $file: $!";
+ open (NEW, ">$from/$file") or die "Can't open $from/$file: $!";
+ binmode(OLD);
+ binmode(NEW);
+ while (<OLD>) {
+ print NEW $_;
+ }
+ close (OLD) or die "Can't close $file: $!";
+ close (NEW) or die "Can't close $from/$file: $!";
}
print $file . " => $from/$file$err\n";
}
diff --git a/lib/libssl/src/util/pl/BC-32.pl b/lib/libssl/src/util/pl/BC-32.pl
index 78d60616a6b..bd7a9d93014 100644
--- a/lib/libssl/src/util/pl/BC-32.pl
+++ b/lib/libssl/src/util/pl/BC-32.pl
@@ -18,7 +18,7 @@ $out_def="out32";
$tmp_def="tmp32";
$inc_def="inc32";
#enable max error messages, disable most common warnings
-$cflags="-DWIN32_LEAN_AND_MEAN -q -w-aus -w-par -w-inl -c -tWC -tWM -DOPENSSL_SYSNAME_WIN32 -DL_ENDIAN -DDSO_WIN32 ";
+$cflags="-DWIN32_LEAN_AND_MEAN -q -w-aus -w-par -w-inl -c -tWC -tWM -DOPENSSL_SYSNAME_WIN32 -DL_ENDIAN -DDSO_WIN32 -D_stricmp=stricmp ";
if ($debug)
{
$cflags.="-Od -y -v -vi- -D_DEBUG";
@@ -51,9 +51,9 @@ $lfile='';
$shlib_ex_obj="";
$app_ex_obj="c0x32.obj";
-$asm='n_o_T_a_s_m';
+$asm='nasmw';
$asm.=" /Zi" if $debug;
-$afile='/Fo';
+$afile='-f obj -o';
$bn_mulw_obj='';
$bn_mulw_src='';
@@ -64,24 +64,24 @@ $bf_enc_src='';
if (!$no_asm)
{
- $bn_mulw_obj='crypto\bn\asm\bn-win32.obj';
- $bn_mulw_src='crypto\bn\asm\bn-win32.asm';
- $des_enc_obj='crypto\des\asm\d-win32.obj crypto\des\asm\y-win32.obj';
- $des_enc_src='crypto\des\asm\d-win32.asm crypto\des\asm\y-win32.asm';
- $bf_enc_obj='crypto\bf\asm\b-win32.obj';
- $bf_enc_src='crypto\bf\asm\b-win32.asm';
- $cast_enc_obj='crypto\cast\asm\c-win32.obj';
- $cast_enc_src='crypto\cast\asm\c-win32.asm';
- $rc4_enc_obj='crypto\rc4\asm\r4-win32.obj';
- $rc4_enc_src='crypto\rc4\asm\r4-win32.asm';
- $rc5_enc_obj='crypto\rc5\asm\r5-win32.obj';
- $rc5_enc_src='crypto\rc5\asm\r5-win32.asm';
- $md5_asm_obj='crypto\md5\asm\m5-win32.obj';
- $md5_asm_src='crypto\md5\asm\m5-win32.asm';
- $sha1_asm_obj='crypto\sha\asm\s1-win32.obj';
- $sha1_asm_src='crypto\sha\asm\s1-win32.asm';
- $rmd160_asm_obj='crypto\ripemd\asm\rm-win32.obj';
- $rmd160_asm_src='crypto\ripemd\asm\rm-win32.asm';
+ $bn_mulw_obj='crypto\bn\asm\bn_win32.obj';
+ $bn_mulw_src='crypto\bn\asm\bn_win32.asm';
+ $des_enc_obj='crypto\des\asm\d_win32.obj crypto\des\asm\y_win32.obj';
+ $des_enc_src='crypto\des\asm\d_win32.asm crypto\des\asm\y_win32.asm';
+ $bf_enc_obj='crypto\bf\asm\b_win32.obj';
+ $bf_enc_src='crypto\bf\asm\b_win32.asm';
+ $cast_enc_obj='crypto\cast\asm\c_win32.obj';
+ $cast_enc_src='crypto\cast\asm\c_win32.asm';
+ $rc4_enc_obj='crypto\rc4\asm\r4_win32.obj';
+ $rc4_enc_src='crypto\rc4\asm\r4_win32.asm';
+ $rc5_enc_obj='crypto\rc5\asm\r5_win32.obj';
+ $rc5_enc_src='crypto\rc5\asm\r5_win32.asm';
+ $md5_asm_obj='crypto\md5\asm\m5_win32.obj';
+ $md5_asm_src='crypto\md5\asm\m5_win32.asm';
+ $sha1_asm_obj='crypto\sha\asm\s1_win32.obj';
+ $sha1_asm_src='crypto\sha\asm\s1_win32.asm';
+ $rmd160_asm_obj='crypto\ripemd\asm\rm_win32.obj';
+ $rmd160_asm_src='crypto\ripemd\asm\rm_win32.asm';
$cflags.=" -DBN_ASM -DMD5_ASM -DSHA1_ASM -DRMD160_ASM";
}
diff --git a/lib/libssl/src/util/pl/VC-32.pl b/lib/libssl/src/util/pl/VC-32.pl
index 50bfb343854..d6e3a11530f 100644
--- a/lib/libssl/src/util/pl/VC-32.pl
+++ b/lib/libssl/src/util/pl/VC-32.pl
@@ -66,24 +66,24 @@ $bf_enc_src='';
if (!$no_asm)
{
- $bn_asm_obj='crypto\bn\asm\bn-win32.obj';
- $bn_asm_src='crypto\bn\asm\bn-win32.asm';
- $des_enc_obj='crypto\des\asm\d-win32.obj crypto\des\asm\y-win32.obj';
- $des_enc_src='crypto\des\asm\d-win32.asm crypto\des\asm\y-win32.asm';
- $bf_enc_obj='crypto\bf\asm\b-win32.obj';
- $bf_enc_src='crypto\bf\asm\b-win32.asm';
- $cast_enc_obj='crypto\cast\asm\c-win32.obj';
- $cast_enc_src='crypto\cast\asm\c-win32.asm';
- $rc4_enc_obj='crypto\rc4\asm\r4-win32.obj';
- $rc4_enc_src='crypto\rc4\asm\r4-win32.asm';
- $rc5_enc_obj='crypto\rc5\asm\r5-win32.obj';
- $rc5_enc_src='crypto\rc5\asm\r5-win32.asm';
- $md5_asm_obj='crypto\md5\asm\m5-win32.obj';
- $md5_asm_src='crypto\md5\asm\m5-win32.asm';
- $sha1_asm_obj='crypto\sha\asm\s1-win32.obj';
- $sha1_asm_src='crypto\sha\asm\s1-win32.asm';
- $rmd160_asm_obj='crypto\ripemd\asm\rm-win32.obj';
- $rmd160_asm_src='crypto\ripemd\asm\rm-win32.asm';
+ $bn_asm_obj='crypto\bn\asm\bn_win32.obj';
+ $bn_asm_src='crypto\bn\asm\bn_win32.asm';
+ $des_enc_obj='crypto\des\asm\d_win32.obj crypto\des\asm\y_win32.obj';
+ $des_enc_src='crypto\des\asm\d_win32.asm crypto\des\asm\y_win32.asm';
+ $bf_enc_obj='crypto\bf\asm\b_win32.obj';
+ $bf_enc_src='crypto\bf\asm\b_win32.asm';
+ $cast_enc_obj='crypto\cast\asm\c_win32.obj';
+ $cast_enc_src='crypto\cast\asm\c_win32.asm';
+ $rc4_enc_obj='crypto\rc4\asm\r4_win32.obj';
+ $rc4_enc_src='crypto\rc4\asm\r4_win32.asm';
+ $rc5_enc_obj='crypto\rc5\asm\r5_win32.obj';
+ $rc5_enc_src='crypto\rc5\asm\r5_win32.asm';
+ $md5_asm_obj='crypto\md5\asm\m5_win32.obj';
+ $md5_asm_src='crypto\md5\asm\m5_win32.asm';
+ $sha1_asm_obj='crypto\sha\asm\s1_win32.obj';
+ $sha1_asm_src='crypto\sha\asm\s1_win32.asm';
+ $rmd160_asm_obj='crypto\ripemd\asm\rm_win32.obj';
+ $rmd160_asm_src='crypto\ripemd\asm\rm_win32.asm';
$cflags.=" -DBN_ASM -DMD5_ASM -DSHA1_ASM -DRMD160_ASM";
}
diff --git a/lib/libssl/src/util/point.sh b/lib/libssl/src/util/point.sh
index 47543c88e26..ce7dcc56dfa 100644
--- a/lib/libssl/src/util/point.sh
+++ b/lib/libssl/src/util/point.sh
@@ -1,6 +1,10 @@
#!/bin/sh
rm -f $2
-ln -s $1 $2
+if test "$OSTYPE" = msdosdjgpp; then
+ cp $1 $2
+else
+ ln -s $1 $2
+fi
echo "$2 => $1"