[openssl-dev] [openssl.org #4083] possible fix to make test failure with openssl-1.0.2d on MinGW...

christian fafard via RT rt at openssl.org
Fri Oct 9 03:11:53 UTC 2015


With version 'openssl-1.0.2d',in file 'test/Makefile',at line 244 shown above,
	@<tmp.bntest sh -c "`sh ./bctest ignore`" | $(PERL) -e '$$i=0; while (<STDIN>) {if (/^test (.*)/) {print STDERR "\nverify $$1";} elsif (!/^0$$/) {die "\nFailed! bc: $$_";} else {print STDERR "."; $$i++;}} print STDERR "\n$$i tests passed\n"'
Make test fail because you use this snippet of perl's code '(!/^0$$/)' to match any lines not containing only a single zero.It doesn't work as expected with the version 5.8.8 of perl distributed with mingw32, as you can see from the message above.
verify BN_addFailed! bc: 0make[1]: *** [test_bn] Error 255
I use this equivalent line to avoid the problematic negation of regex match '!//',
	@<tmp.bntest sh -c "`sh ./bctest ignore`" | $(PERL) -e '$$i=0; while (<STDIN>) {if (/^test (.*)/) {print STDERR "\nverify $$1";} elsif (/^0$$/) {print STDERR "."; $$i++;} else {die "\nFailed! bc: $$_";}} print STDERR "\n$$i tests passed\n"'
I'm not expert enough to know if this code is more portable on every platforms and versions of perl, i'll leave it to you.
ThanksChristian Fafard 		 	   		  
-------------- next part --------------
_______________________________________________
openssl-bugs-mod mailing list
openssl-bugs-mod at openssl.org
https://mta.openssl.org/mailman/listinfo/openssl-bugs-mod


More information about the openssl-dev mailing list