Hi everybody,
I tried to compile OpenSSL v0.9.8 inside Windows with MingW environment inside MingW's MSYS environment (this is a small unix like environment like cygwin, but much smaller and native to windows). So I did it the usual Unix way: ./Configure no-engine mingw make PERL=$(which perl) links depend all (I needed to add the PERL setting because it seems to need a "make links" and the link making did not work without it). After a while it stops with this: -------------------------------------------------------------------------------- making all in crypto... make[1]: Entering directory `/c/Prog/openssl-0.9.8/crypto' gcc -I. -I.. -I../include -DOPENSSL_THREADS -DDSO_WIN32 -DPERL=C:/Programme/_Entwicklung/ActivePerl/bin/perl.exe -mno-cygwin -DL_EN DIAN -fomit-frame-pointer -O3 -march=i486 -Wall -D_WIN32_WINNT=0x333 -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_IA32_SSE2 -DSHA1_ASM -DMD 5_ASM -DRMD160_ASM -DAES_ASM -c -o cryptlib.o cryptlib.c . . . gcc -I. -I.. -I../include -DOPENSSL_THREADS -DDSO_WIN32 -DPERL=C:/Programme/_Entwicklung/ActivePerl/bin/perl.exe -mno-cygwin -DL_EN DIAN -fomit-frame-pointer -O3 -march=i486 -Wall -D_WIN32_WINNT=0x333 -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_IA32_SSE2 -DSHA1_ASM -DMD 5_ASM -DRMD160_ASM -DAES_ASM -c -o cversion.o cversion.c In file included from cversion.c:62: buildinf.h:6:4: #error "Windows builds (PLATFORM=mingw) use mk1mf.pl-created Makefiles" make[1]: *** [cversion.o] Error 1 make[1]: Leaving directory `/c/Prog/Projekt/openssl-0.9.8/crypto' make: *** [build_crypto] Error 1 -------------------------------------------------------------------------------- So it seems that this is a break on intend. But why? And what can I do against it? BTW, v0.9.7g worked without that problem! (I had some problems with certain newer binutils versions where the gas complained about some asm lines but I solved it by using older binutils versions). Could it be made that v0.9.8 compiles again in MingW+MSYS environment? with regards, Matthias ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [hidden email] Automated List Manager [hidden email] |
On Jul 8 22:08, Matthias Mohr wrote:
> Hi everybody, > > I tried to compile OpenSSL v0.9.8 inside Windows with > MingW environment inside MingW's MSYS environment > (this is a small unix like environment like cygwin, but much > smaller and native to windows). Just for the records. MSYS *is* Cygwin, a branch from a very old version of Cygwin. It's no way more or less "native" than Cygwin itself. Corinna -- Corinna Vinschen Cygwin Project Co-Leader Red Hat, Inc. ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [hidden email] Automated List Manager [hidden email] |
> Just for the records. MSYS *is* Cygwin, a branch from a very old
> version of Cygwin. It's no way more or less "native" than Cygwin > itself. Maybe - but without any cygwin.dll and the compiler chain and other tools also don't need any cygwin.dll. And they also don't need any special flags (like '-nocygwin') to compile native Win32 applications. So I think there is a difference between using cygwin environment and MSYS environment... And this all does not explain why OpenSSL v0.9.7 versions did compile inside the MingW/MSYS environment and the v0.9.8 version does not! with regards, Matthias ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [hidden email] Automated List Manager [hidden email] |
In reply to this post by Matthias Mohr-4
On Fri, 8 Jul 2005, Matthias Mohr wrote:
> I tried to compile OpenSSL v0.9.8 inside Windows with > MingW environment inside MingW's MSYS environment > (this is a small unix like environment like cygwin, but much > smaller and native to windows). > > So I did it the usual Unix way: > > ./Configure no-engine mingw > make PERL=$(which perl) links depend all > > (I needed to add the PERL setting because it seems to need > a "make links" and the link making did not work without it). > > After a while it stops with this: > -------------------------------------------------------------------------------- > gcc -I. -I.. -I../include -DOPENSSL_THREADS -DDSO_WIN32 -DPERL=C:/Programme/_Entwicklung/ActivePerl/bin/perl.exe -mno-cygwin -DL_EN > DIAN -fomit-frame-pointer -O3 -march=i486 -Wall -D_WIN32_WINNT=0x333 -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_IA32_SSE2 -DSHA1_ASM -DMD > 5_ASM -DRMD160_ASM -DAES_ASM -c -o cversion.o cversion.c > In file included from cversion.c:62: > buildinf.h:6:4: #error "Windows builds (PLATFORM=mingw) use mk1mf.pl-created Makefiles" > make[1]: *** [cversion.o] Error 1 > make[1]: Leaving directory `/c/Prog/Projekt/openssl-0.9.8/crypto' > make: *** [build_crypto] Error 1 I see how to get around this, but I am not sure why it is built into Configure this way. This occurs because you are using ActivePerl rather than the Cygwin perl. See line 910 in Configure: $IsMK1MF=1 if ($target eq "mingw" && ^O ne "cygwin"); What this does, if your version of perl was not built on cygwin, is to make buildinf.h into the version that you have, instead of the one generated by crypto/Makefile. If you either use cygwin perl, or delete the above line from Configure, you should be able to proceed with your attempt to compile OpenSSL. I am not sure I see when you would be using the Configure script with mingw and still want to do a MK1MF style build. Doug -- Doug Kaufman Internet: [hidden email] ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [hidden email] Automated List Manager [hidden email] |
Hi Doug,
> > In file included from cversion.c:62: > > buildinf.h:6:4: #error "Windows builds (PLATFORM=mingw) use mk1mf.pl-created Makefiles" > > make[1]: *** [cversion.o] Error 1 > > make[1]: Leaving directory `/c/Prog/Projekt/openssl-0.9.8/crypto' > > make: *** [build_crypto] Error 1 > > I see how to get around this, but I am not sure why it is built into > Configure this way. This occurs because you are using ActivePerl rather > than the Cygwin perl. See line 910 in Configure: > $IsMK1MF=1 if ($target eq "mingw" && ^O ne "cygwin"); > > What this does, if your version of perl was not built on cygwin, is to > make buildinf.h into the version that you have, instead of the one > generated by crypto/Makefile. If you either use cygwin perl, or delete > the above line from Configure, you should be able to proceed with your > attempt to compile OpenSSL. I am not sure I see when you would be using > the Configure script with mingw and still want to do a MK1MF style > build. I removed the above line and it really starts to build the beast. But then after a while, it stops with the following: -------------------------------------------------------------------------------------------------------- make[1]: Leaving directory `/c/Prog/openssl-0.9.8/ssl' making all in engines... make[1]: Entering directory `/c/Prog/openssl-0.9.8/engines' gcc -I../include -DOPENSSL_THREADS -DDSO_WIN32 -DPERL=C:/Programme/_Entwicklung/ActivePerl/bin/perl.exe -mno-cygwin -DL_ENDIAN -fom it-frame-pointer -O3 -march=i486 -Wall -D_WIN32_WINNT=0x333 -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_IA32_SSE2 -DSHA1_ASM -DMD5_ASM -DR MD160_ASM -DAES_ASM -I/mingw/include -I/mingw/mingw32/include -I/usr/include -L/mingw/include -L/mingw/mingw32/include -L/usr/lib - c -o e_4758cca.o e_4758cca.c e_4758cca.c:62:28: openssl/engine.h: No such file or directory e_4758cca.c:164: error: syntax error before "cca4758_cmd_defns" ... -------------------------------------------------------------------------------------------------------- Why does it even walk into the "engines" subdirectory? I said "no-engine" in the Configuration step...!??? I'm really confused... with regards, Matthias ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [hidden email] Automated List Manager [hidden email] |
On Mon, 11 Jul 2005, Matthias Mohr wrote:
> > $IsMK1MF=1 if ($target eq "mingw" && ^O ne "cygwin"); > > > > What this does, if your version of perl was not built on cygwin, is to > > make buildinf.h into the version that you have, instead of the one > > generated by crypto/Makefile. If you either use cygwin perl, or delete > > the above line from Configure, you should be able to proceed with your > > attempt to compile OpenSSL. I am not sure I see when you would be using > > the Configure script with mingw and still want to do a MK1MF style > > build. > Thanks this did help - a bit J > I removed the above line and it really starts to build the beast. > But then after a while, it stops with the following: > -------------------------------------------------------------------------------------------------------- > make[1]: Leaving directory `/c/Prog/openssl-0.9.8/ssl' > making all in engines... > make[1]: Entering directory `/c/Prog/openssl-0.9.8/engines' > gcc -I../include -DOPENSSL_THREADS -DDSO_WIN32 -DPERL=C:/Programme/_Entwicklung/ActivePerl/bin/perl.exe -mno-cygwin -DL_ENDIAN -fom > it-frame-pointer -O3 -march=i486 -Wall -D_WIN32_WINNT=0x333 -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_IA32_SSE2 -DSHA1_ASM -DMD5_ASM -DR > MD160_ASM -DAES_ASM -I/mingw/include -I/mingw/mingw32/include -I/usr/include -L/mingw/include -L/mingw/mingw32/include -L/usr/lib - > c -o e_4758cca.o e_4758cca.c > e_4758cca.c:62:28: openssl/engine.h: No such file or directory > e_4758cca.c:164: error: syntax error before "cca4758_cmd_defns" > ... > -------------------------------------------------------------------------------------------------------- > > Why does it even walk into the "engines" subdirectory? > I said "no-engine" in the Configuration step...!??? A "no-engine" directive to Configure is not one of the documented options, but looking at Configure, I think it will just cause OPENSSL_NO_ENGINE to be defined. It doesn't affect which files are compiled. The real question is why you don't have include/openssl/engine.h. This is created early in the build by "make links". Depending on the system, you should either have a link or copy of crypto/engine/engine.h in include/openssl. You need to look at your logs and figure out why you don't. Do all the other files that are supposed to be linked or copied to that directory exist? The file that does the linking or copying is util/mklink.pl. I know that this works for DJGPP, for cygwin, and for mingw compiled under cygwin. I don't know how the perl symlink function and the symlink tests work under ActivePerl compared to the more usual perl implementations. I only compile for mingw under cygwin with -mno-cygwin and don't have MSYS, so I don't know that I can help more here. Your build fails because it doesn't have the definintion of ENGINE_CMD_DEFN that it needs from engine.h, which apparently wasn't copied or linked into include/openssl/engine.h. Doug -- Doug Kaufman Internet: [hidden email] ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [hidden email] Automated List Manager [hidden email] |
Doug Kaufman writes:
> A "no-engine" directive to Configure is not one of the documented > options, but looking at Configure, I think it will just cause > OPENSSL_NO_ENGINE to be defined. It doesn't affect which files are > compiled. no-engine shouldn't be used. It doesn't work, and exactly for the reason you mention. I'm looking into it. > The real question is why you don't have include/openssl/engine.h. Because among others, no-engine means "engine" will not be part of the SDIRS makefile variable, and thereby means that the crypto/engine directory is utterly and completely ignored. At least with the Unixly Makefiles... Please do not try to use no-engine for now. Cheers, Richard ----- Please consider sponsoring my work on free software. See http://www.free.lp.se/sponsoring.html for details. -- Richard Levitte [hidden email] http://richard.levitte.org/ "When I became a man I put away childish things, including the fear of childishness and the desire to be very grown up." -- C.S. Lewis ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [hidden email] Automated List Manager [hidden email] |
On Tue, 12 Jul 2005, Richard Levitte wrote:
> Doug Kaufman writes: > > > A "no-engine" directive to Configure is not one of the documented > > options, but looking at Configure, I think it will just cause > > OPENSSL_NO_ENGINE to be defined. It doesn't affect which files are > > compiled. > > no-engine shouldn't be used. It doesn't work, and exactly for the reason > you mention. I'm looking into it. > > > The real question is why you don't have include/openssl/engine.h. > > Because among others, no-engine means "engine" will not be part of the SDIRS > makefile variable, and thereby means that the crypto/engine directory is > utterly and completely ignored. At least with the Unixly Makefiles... > > Please do not try to use no-engine for now. I looked again at Configure to see what I missed. When you use no-whatever, it adds "whatever" to @skip which causes "whatever" to be removed from the list of directories, so "make link" never gets run on "whatever". So with "no-engine", "make links" never gets run on the engine directory and engine.h isn't linked. Sorry I missed that in the earlier post. Doug -- Doug Kaufman Internet: [hidden email] ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [hidden email] Automated List Manager [hidden email] |
In reply to this post by Richard Levitte - VMS Whacker
Hi Doug,
Hi Richard, > > A "no-engine" directive to Configure is not one of the documented > > options, but looking at Configure, I think it will just cause > > OPENSSL_NO_ENGINE to be defined. It doesn't affect which files are > > compiled. You were right, it's no longer one of the documented options. I did use it in previous versions and did not remove it... No I tried with "no-hw" and after a bit tweaking it did work :-) Here's the complete patch which I needed for a succesful compilation for mingw32 in MSYS environment (if somebody's interested...) After the successful "make all" step I also do the following to create DLLs: -------------------------------------------------------------------------------------- echo EXPORTS > libcrypto.def nm libcrypto.a | grep ' T _' | sed 's,^.* T _,,' >> libcrypto.def dllwrap -o libcrypto.dll --def libcrypto.def libcrypto.a -lws2_32 -lgdi32 echo EXPORTS > libssl.def nm libssl.a | grep 'T _' | sed 's,^.* T _,,' >> libssl.def dllwrap -o libssl.dll --def libssl.def libssl.a libcrypto.dll -------------------------------------------------------------------------------------- with regards, Matthias |
Free forum by Nabble | Edit this page |