Hi all!
I have just successfully built openssl-0.9.5beta1 on NT 4 with VC++ 6.0 and
MASM 6.14. I had to "tweak" two thing to get it through.
My setup is this:
> perl Configure VC-WIN32
> ms\do_masm
> nmake -f ms\ntdll.mak
I'm not on this list, so you may CC any comments to me.
First one, short version
========================
I need this patch to make openssl-0.9.5beta1 compile clean with MASM 6:
--- crypto/perlasm/x86ms.pl.orig Mon Jul 12 20:12:40 1999
+++ crypto/perlasm/x86ms.pl Fri Feb 25 10:27:27 2000
@@ -341,7 +341,7 @@
$label{$_[0]}="${label}${_[0]}";
$label++;
}
- push(@out,"$label{$_[0]}:\n");
+ push(@out,"$label{$_[0]}::\n");
}
sub main'data_word
Why?
====
I get this error:
ml /Cp /coff /c /Cx /Focrypto\sha\asm\s1-win32.obj
.\crypto\sha\asm\s1-win32.asm
Microsoft (R) Macro Assembler Version 6.14.8444
Copyright (C) Microsoft Corp 1981-1997. All rights reserved.
Assembling: .\crypto\sha\asm\s1-win32.asm
.\crypto\sha\asm\s1-win32.asm(1711) : error A2006: undefined symbol :
L001shortcut
NMAKE : fatal error U1077: 'ml' : return code '0x1'
Stop.
This is (hopefully) the interesting parts of crypto\sha\asm\s1-win32.asm:
TITLE sha1-586.asm
.486
.model FLAT
_TEXT SEGMENT
PUBLIC _sha1_block_asm_data_order
_sha1_block_asm_data_order PROC NEAR
<snip>
mov DWORD PTR 132[esp],esi
L001shortcut:
;
<snip>
ret
_TEXT SEGMENT
PUBLIC _sha1_block_asm_host_order
_sha1_block_asm_host_order PROC NEAR
<snip>
jmp L001shortcut
_sha1_block_asm_host_order ENDP
_TEXT ENDS
_sha1_block_asm_data_order ENDP
_TEXT ENDS
END
Now, I'm by no means a MASM expert, but it seems that labels with a single
colon, ":", is scope dependent. So the "L001shortcut:" label isn't visible
in the scope of "_sha1_block_asm_host_order PROC NEAR". To make labels
"global", they should be suffixed with double colons, "::", like
"L001shortcut::".
Cheers,
- Peter
----------------------------------------------------------------
Peter "Luna" Runestig (fd. Altberg), Sweden <[EMAIL PROTECTED]>
PGP Key ID: 0x33BE83E0
Fingerprint: 05DB BFF0 4F9D 1FFA 8441 E859 7F7B E52E 33BE 83E0
Gubben Movitz ler och nickar, / men fr�n Charons m�rka sund
d�dens blund / i dina blickar / b�dar snart din sista stund.
Carl Michael Bellman, Fredmans epistel nr 34
______________________________________________________________________
OpenSSL Project http://www.openssl.org
Development Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]