Michal, I apologize. It was late night and I should have waited till morning to write the report. Note that I read that link for the first time years ago, and I still do once in a while :)
Mostly, you figured out the issue. I use the mingw.mak recipe included in the src directory to compile my own stunnel with mingw32. However, there was a change in stunnel 5.25 affecting stunnel.c that breaks compilation with this makefile. See attached diff. I know you don't compile under windows, but please consider reverting that change to retain backward compatibility.
Thanks a lot for sharing your build scripts on Linux. Regards,Jose
On Thursday, November 5, 2015 4:14 AM, Michal Trojnara Michal.Trojnara@mirt.net wrote:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256
On 05.11.2015 05:17, Josealf.rm wrote:
I tested stunnel 5.26b1 with gcc 4.85 under Windows. All fine except that I had to change the #include <openssl/applink.c> to <../ms/applink.c> as it was on previous releases.
I'm not sure what you mean by "gcc 4.85 under Windows". I guess mingw, but it still doesn't give me enough information to reproduce and fix the issue. Please consider reading: http://www.chiark.greenend.org.uk/~sgtatham/bugs.html
Trying to reproduce the issue you reported I managed to build stunnel with Cygwin. See the attached file for details.
The stunnel/OpenSSL build procedure for Windows has recently changed. stunnel no longer uses the OpenSSL source tree, but rather the installed files. The problem is that OpenSSL does not install the applink.c file required for Windows targets. I guess this is an OpenSSL bug. My current script for cross-compiling OpenSSL on Debian/Ubuntu is:
#!/bin/bash set -e
case $1 in 32) TARGET=i686 MINGW=mingw ;; 64) TARGET=x86_64 MINGW=mingw64 ;; *) echo "Usage: $0 {32|64}" exit 1 esac
./Configure \ --cross-compile-prefix=${TARGET}-w64-mingw32- \ --openssldir=/opt/openssl-${MINGW} \ ${MINGW} shared make sudo make install sudo cp ms/applink.c /opt/openssl-${MINGW}/include/openssl/
Best regards, Mike
_______________________________________________ stunnel-users mailing list stunnel-users@stunnel.org https://www.stunnel.org/cgi-bin/mailman/listinfo/stunnel-users