Hi, I am having a bit of a trouble compiling the openSSL release 0.9.8e under WinXP SP2.
The version of minGW's the gcc compiler I am using is 3.4.5-20060117-1 and the minGW32-make is 3.80.0-1. For some reason the build tools use malformed file names such as ".\crypto\/cryptlib.h" (pay attention to the "\/" -- it's not V, but "\" and "/" concatenated) and the compilation fails with the final message being "mingw32-make: *** [tmp\cryptlib.o] Error 1". I included the compile log with my letter. Any ideas what might be the issue here? best regards, Maleamat88r ==================== C:\openssl-0.9.8e>ms\mingw32 C:\openssl-0.9.8e>perl Configure mingw Configuring for mingw no-camellia [default] OPENSSL_NO_CAMELLIA (skip dir) no-gmp [default] OPENSSL_NO_GMP (skip dir) no-krb5 [krb5-flavor not specified] OPENSSL_NO_KRB5 no-mdc2 [default] OPENSSL_NO_MDC2 (skip dir) no-rc5 [default] OPENSSL_NO_RC5 (skip dir) no-rfc3779 [default] OPENSSL_NO_RFC3779 (skip dir) no-shared [default] no-zlib [default] no-zlib-dynamic [default] IsMK1MF=1 CC =gcc CFLAG =-DOPENSSL_THREADS -DDSO_WIN32 -mno-cygwin -DL_ENDIAN -fomit-frame-pointer -O3 -march=i486 -Wall -D_WIN32_WINNT=0x333 -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_IA32_SSE2 -DSHA1_ASM -DM EX_LIBS =-lwsock32 -lgdi32 CPUID_OBJ =x86cpuid-cof.o BN_ASM =bn86-cof.o co86-cof.o DES_ENC =dx86-cof.o yx86-cof.o AES_ASM_OBJ =ax86-cof.o BF_ENC =bx86-cof.o CAST_ENC =cx86-cof.o RC4_ENC =rx86-cof.o RC5_ENC =r586-cof.o MD5_OBJ_ASM =mx86-cof.o SHA1_OBJ_ASM =sx86-cof.o s512sse2-cof.o RMD160_OBJ_ASM=rm86-cof.o PROCESSOR = RANLIB =true ARFLAGS = PERL =perl THIRTY_TWO_BIT mode DES_PTR used DES_RISC1 used DES_UNROLL used BN_LLONG mode RC4_INDEX mode RC4_CHUNK is undefined Configured for mingw. Generating x86 for GNU assember Bignum DES crypt Blowfish CAST5 RC4 MD5 SHA1 RIPEMD160 RC5\32 CPUID Generating makefile Generating DLL definition files Building the libraries Building OpenSSL copy .\crypto\buildinf.h tmp\buildinf.h 1 file(s) copied. copy .\crypto\opensslconf.h outinc\openssl\opensslconf.h 1 file(s) copied. gcc -o tmp\cryptlib.o -Ioutinc -Itmp -DL_ENDIAN -DDSO_WIN32 -fomit-frame-pointer -O3 -march=i486 -Wall -DBN_ASM -DMD5_ASM -DSHA1_ASM -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_NO_CAMELLIA -DOPENSSL_N In file included from .\crypto\cryptlib.c:117: .\crypto\/cryptlib.h:62:20: stdlib.h: No such file or directory .\crypto\/cryptlib.h:63:20: string.h: No such file or directory In file included from .\crypto\/cryptlib.h:65, from .\crypto\cryptlib.c:117: tmp/e_os.h:265:25: windows.h: No such file or directory tmp/e_os.h:267:23: errno.h: No such file or directory tmp/e_os.h:279:24: malloc.h: No such file or directory tmp/e_os.h:281:18: io.h: No such file or directory tmp/e_os.h:282:21: fcntl.h: No such file or directory In file included from .\crypto\/cryptlib.h:72, from .\crypto\cryptlib.c:117: outinc/openssl/crypto.h:125:19: stdio.h: No such file or directory In file included from .\crypto\/cryptlib.h:72, from .\crypto\cryptlib.c:117: outinc/openssl/crypto.h:511: error: syntax error before '*' token In file included from .\crypto\/cryptlib.h:73, from .\crypto\cryptlib.c:117: outinc/openssl/buffer.h:71:23: sys/types.h: No such file or directory In file included from .\crypto\/cryptlib.h:74, from .\crypto\cryptlib.c:117: outinc/openssl/bio.h:567: error: syntax error before '*' token outinc/openssl/bio.h:644: error: syntax error before '*' token outinc/openssl/bio.h:645: error: syntax error before '*' token In file included from outinc/openssl/err.h:74, from .\crypto\/cryptlib.h:75, from .\crypto\cryptlib.c:117: outinc/openssl/lhash.h:185: error: syntax error before "FILE" outinc/openssl/lhash.h:186: error: syntax error before "FILE" outinc/openssl/lhash.h:187: error: syntax error before "FILE" In file included from .\crypto\/cryptlib.h:75, from .\crypto\cryptlib.c:117: outinc/openssl/err.h:279: error: syntax error before '*' token .\crypto\cryptlib.c: In function `CRYPTO_thread_id': .\crypto\cryptlib.c:436: warning: implicit declaration of function `GetCurrentThreadId' .\crypto\cryptlib.c: In function `OPENSSL_cpuid_setup': .\crypto\cryptlib.c:559: warning: implicit declaration of function `getenv' .\crypto\cryptlib.c:559: warning: assignment makes pointer from integer without a cast .\crypto\cryptlib.c:560: warning: implicit declaration of function `strtoul' .\crypto\cryptlib.c:624:19: tchar.h: No such file or directory .\crypto\cryptlib.c: In function `OPENSSL_isservice': .\crypto\cryptlib.c:628: error: `HWINSTA' undeclared (first use in this function) .\crypto\cryptlib.c:628: error: (Each undeclared identifier is reported only once .\crypto\cryptlib.c:628: error: for each function it appears in.) .\crypto\cryptlib.c:628: error: syntax error before "h" .\crypto\cryptlib.c:629: error: `DWORD' undeclared (first use in this function) .\crypto\cryptlib.c:630: error: `WCHAR' undeclared (first use in this function) .\crypto\cryptlib.c:630: error: `name' undeclared (first use in this function) .\crypto\cryptlib.c:632: warning: implicit declaration of function `GetDesktopWindow' .\crypto\cryptlib.c:634: error: `h' undeclared (first use in this function) .\crypto\cryptlib.c:634: warning: implicit declaration of function `GetProcessWindowStation' .\crypto\cryptlib.c:637: warning: implicit declaration of function `GetUserObjectInformationW' .\crypto\cryptlib.c:637: error: `UOI_NAME' undeclared (first use in this function) .\crypto\cryptlib.c:637: error: `len' undeclared (first use in this function) .\crypto\cryptlib.c:638: warning: implicit declaration of function `GetLastError' .\crypto\cryptlib.c:638: error: `ERROR_INSUFFICIENT_BUFFER' undeclared (first use in this function) .\crypto\cryptlib.c:642: warning: left-hand operand of comma expression has no effect .\crypto\cryptlib.c:646: error: syntax error before ')' token .\crypto\cryptlib.c:651: warning: left-hand operand of comma expression has no effect .\crypto\cryptlib.c:657: warning: implicit declaration of function `wcsstr' .\crypto\cryptlib.c: In function `OPENSSL_showfatal': .\crypto\cryptlib.c:670: error: `TCHAR' undeclared (first use in this function) .\crypto\cryptlib.c:670: error: syntax error before "buf" .\crypto\cryptlib.c:671: error: syntax error before '*' token .\crypto\cryptlib.c:686: error: `fmt' undeclared (first use in this function) .\crypto\cryptlib.c:686: error: syntax error before "TCHAR" .\crypto\cryptlib.c:689: warning: implicit declaration of function `strlen' .\crypto\cryptlib.c:690: error: `WCHAR' undeclared (first use in this function) .\crypto\cryptlib.c:690: error: `fmtw' undeclared (first use in this function) .\crypto\cryptlib.c:695: error: syntax error before ')' token .\crypto\cryptlib.c:697: error: syntax error before "TCHAR" .\crypto\cryptlib.c:697: error: break statement not within loop or switch .\crypto\cryptlib.c:700: warning: implicit declaration of function `MultiByteToWideChar' .\crypto\cryptlib.c:700: error: `CP_ACP' undeclared (first use in this function) .\crypto\cryptlib.c:702: error: syntax error before "fmta" .\crypto\cryptlib.c:706: error: `keepgoing' undeclared (first use in this function) .\crypto\cryptlib.c:719: error: syntax error before "TCHAR" .\crypto\cryptlib.c:669: warning: unused variable `ap' .\crypto\cryptlib.c: At top level: .\crypto\cryptlib.c:722: warning: type defaults to `int' in declaration of `__builtin_va_start' .\crypto\cryptlib.c:722: warning: parameter names (without types) in function declaration .\crypto\cryptlib.c:722: warning: data definition has no type or storage class .\crypto\cryptlib.c:723: error: syntax error before "sizeof" .\crypto\cryptlib.c:724: error: `buf' undeclared here (not in a function) .\crypto\cryptlib.c:724: error: `TCHAR' undeclared here (not in a function) .\crypto\cryptlib.c:724: warning: type defaults to `int' in declaration of `buf' .\crypto\cryptlib.c:724: warning: implicit declaration of function `_T' .\crypto\cryptlib.c:724: error: invalid initializer .\crypto\cryptlib.c:724: warning: data definition has no type or storage class .\crypto\cryptlib.c:725: warning: type defaults to `int' in declaration of `__builtin_va_end' .\crypto\cryptlib.c:725: warning: parameter names (without types) in function declaration .\crypto\cryptlib.c:725: warning: data definition has no type or storage class .\crypto\cryptlib.c:729: error: syntax error before "if" .\crypto\cryptlib.c:731: error: syntax error before '*' token .\crypto\cryptlib.c:731: warning: type defaults to `int' in declaration of `pmsg' .\crypto\cryptlib.c:731: warning: data definition has no type or storage class .\crypto\cryptlib.c:732: error: syntax error before numeric constant .\crypto\cryptlib.c:732: warning: type defaults to `int' in declaration of `ReportEvent' .\crypto\cryptlib.c:732: warning: data definition has no type or storage class .\crypto\cryptlib.c:733: warning: type defaults to `int' in declaration of `DeregisterEventSource' .\crypto\cryptlib.c:733: warning: parameter names (without types) in function declaration .\crypto\cryptlib.c:733: warning: data definition has no type or storage class .\crypto\cryptlib.c:734: error: syntax error before '}' token .\crypto\cryptlib.c: In function `OpenSSLDie': .\crypto\cryptlib.c:755: warning: implicit declaration of function `abort' .\crypto\cryptlib.c: In function `OPENSSL_stderr': .\crypto\cryptlib.c:758: error: `stderr' undeclared (first use in this function) .\crypto\cryptlib.c: In function `OPENSSL_isservice': .\crypto\cryptlib.c:642: warning: statement with no effect .\crypto\cryptlib.c:651: warning: statement with no effect .\crypto\cryptlib.c: In function `OPENSSL_showfatal': .\crypto\cryptlib.c:686: warning: statement with no effect .\crypto\cryptlib.c:702: warning: statement with no effect mingw32-make: *** [tmp\cryptlib.o] Error 1 C:\openssl-0.9.8e>Title: A possible bug when compiling openSSL with minGW
Hi,
I am having a bit of a trouble compiling the openSSL release 0.9.8e under WinXP SP2.
The version of minGW's the gcc compiler I am using is 3.4.5-20060117-1 and the minGW32-make is 3.80.0-1.
For some reason the build tools use malformed file names such as ".\crypto\/cryptlib.h" (pay attention to the "\/" -- it's not V, but "\" and "/" concatenated) and the compilation fails with the final message being "mingw32-make: *** [tmp\cryptlib.o] Error 1". I included the compile log with my letter. Any ideas what might be the issue here?
best regards,
Maleamat88r
====================
C:\openssl-0.9.8e>ms\mingw32
C:\openssl-0.9.8e>perl Configure mingw
Configuring for mingw
no-camellia [default] OPENSSL_NO_CAMELLIA (skip dir)
no-gmp [default] OPENSSL_NO_GMP (skip dir)
no-krb5 [krb5-flavor not specified] OPENSSL_NO_KRB5
no-mdc2 [default] OPENSSL_NO_MDC2 (skip dir)
no-rc5 [default] OPENSSL_NO_RC5 (skip dir)
no-rfc3779 [default] OPENSSL_NO_RFC3779 (skip dir)
no-shared [default]
no-zlib [default]
no-zlib-dynamic [default]
IsMK1MF=1
CC =gcc
CFLAG =-DOPENSSL_THREADS -DDSO_WIN32 -mno-cygwin -DL_ENDIAN -fomit-frame-pointer -O3 -march=i486 -Wall -D_WIN32_WINNT=0x333 -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_IA32_SSE2 -DSHA1_ASM -DM
EX_LIBS =-lwsock32 -lgdi32
CPUID_OBJ =x86cpuid-cof.o
BN_ASM =bn86-cof.o co86-cof.o
DES_ENC =dx86-cof.o yx86-cof.o
AES_ASM_OBJ =ax86-cof.o
BF_ENC =bx86-cof.o
CAST_ENC =cx86-cof.o
RC4_ENC =rx86-cof.o
RC5_ENC =r586-cof.o
MD5_OBJ_ASM =mx86-cof.o
SHA1_OBJ_ASM =sx86-cof.o s512sse2-cof.o
RMD160_OBJ_ASM=rm86-cof.o
PROCESSOR =
RANLIB =true
ARFLAGS =
PERL =perl
THIRTY_TWO_BIT mode
DES_PTR used
DES_RISC1 used
DES_UNROLL used
BN_LLONG mode
RC4_INDEX mode
RC4_CHUNK is undefined
Configured for mingw.
Generating x86 for GNU assember
Bignum
DES
crypt
Blowfish
CAST5
RC4
MD5
SHA1
RIPEMD160
RC5\32
CPUID
Generating makefile
Generating DLL definition files
Building the libraries
Building OpenSSL
copy .\crypto\buildinf.h tmp\buildinf.h
1 file(s) copied.
copy .\crypto\opensslconf.h outinc\openssl\opensslconf.h
1 file(s) copied.
gcc -o tmp\cryptlib.o -Ioutinc -Itmp -DL_ENDIAN -DDSO_WIN32 -fomit-frame-pointer -O3 -march=i486 -Wall -DBN_ASM -DMD5_ASM -DSHA1_ASM -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_NO_CAMELLIA -DOPENSSL_N
In file included from .\crypto\cryptlib.c:117:
.\crypto\/cryptlib.h:62:20: stdlib.h: No such file or directory
.\crypto\/cryptlib.h:63:20: string.h: No such file or directory
In file included from .\crypto\/cryptlib.h:65,
from .\crypto\cryptlib.c:117:
tmp/e_os.h:265:25: windows.h: No such file or directory
tmp/e_os.h:267:23: errno.h: No such file or directory
tmp/e_os.h:279:24: malloc.h: No such file or directory
tmp/e_os.h:281:18: io.h: No such file or directory
tmp/e_os.h:282:21: fcntl.h: No such file or directory
In file included from .\crypto\/cryptlib.h:72,
from .\crypto\cryptlib.c:117:
outinc/openssl/crypto.h:125:19: stdio.h: No such file or directory
In file included from .\crypto\/cryptlib.h:72,
from .\crypto\cryptlib.c:117:
outinc/openssl/crypto.h:511: error: syntax error before '*' token
In file included from .\crypto\/cryptlib.h:73,
from .\crypto\cryptlib.c:117:
outinc/openssl/buffer.h:71:23: sys/types.h: No such file or directory
In file included from .\crypto\/cryptlib.h:74,
from .\crypto\cryptlib.c:117:
outinc/openssl/bio.h:567: error: syntax error before '*' token
outinc/openssl/bio.h:644: error: syntax error before '*' token
outinc/openssl/bio.h:645: error: syntax error before '*' token
In file included from outinc/openssl/err.h:74,
from .\crypto\/cryptlib.h:75,
from .\crypto\cryptlib.c:117:
outinc/openssl/lhash.h:185: error: syntax error before "FILE"
outinc/openssl/lhash.h:186: error: syntax error before "FILE"
outinc/openssl/lhash.h:187: error: syntax error before "FILE"
In file included from .\crypto\/cryptlib.h:75,
from .\crypto\cryptlib.c:117:
outinc/openssl/err.h:279: error: syntax error before '*' token
.\crypto\cryptlib.c: In function `CRYPTO_thread_id':
.\crypto\cryptlib.c:436: warning: implicit declaration of function `GetCurrentThreadId'
.\crypto\cryptlib.c: In function `OPENSSL_cpuid_setup':
.\crypto\cryptlib.c:559: warning: implicit declaration of function `getenv'
.\crypto\cryptlib.c:559: warning: assignment makes pointer from integer without a cast
.\crypto\cryptlib.c:560: warning: implicit declaration of function `strtoul'
.\crypto\cryptlib.c:624:19: tchar.h: No such file or directory
.\crypto\cryptlib.c: In function `OPENSSL_isservice':
.\crypto\cryptlib.c:628: error: `HWINSTA' undeclared (first use in this function)
.\crypto\cryptlib.c:628: error: (Each undeclared identifier is reported only once
.\crypto\cryptlib.c:628: error: for each function it appears in.)
.\crypto\cryptlib.c:628: error: syntax error before "h"
.\crypto\cryptlib.c:629: error: `DWORD' undeclared (first use in this function)
.\crypto\cryptlib.c:630: error: `WCHAR' undeclared (first use in this function)
.\crypto\cryptlib.c:630: error: `name' undeclared (first use in this function)
.\crypto\cryptlib.c:632: warning: implicit declaration of function `GetDesktopWindow'
.\crypto\cryptlib.c:634: error: `h' undeclared (first use in this function)
.\crypto\cryptlib.c:634: warning: implicit declaration of function `GetProcessWindowStation'
.\crypto\cryptlib.c:637: warning: implicit declaration of function `GetUserObjectInformationW'
.\crypto\cryptlib.c:637: error: `UOI_NAME' undeclared (first use in this function)
.\crypto\cryptlib.c:637: error: `len' undeclared (first use in this function)
.\crypto\cryptlib.c:638: warning: implicit declaration of function `GetLastError'
.\crypto\cryptlib.c:638: error: `ERROR_INSUFFICIENT_BUFFER' undeclared (first use in this function)
.\crypto\cryptlib.c:642: warning: left-hand operand of comma _expression_ has no effect
.\crypto\cryptlib.c:646: error: syntax error before ')' token
.\crypto\cryptlib.c:651: warning: left-hand operand of comma _expression_ has no effect
.\crypto\cryptlib.c:657: warning: implicit declaration of function `wcsstr'
.\crypto\cryptlib.c: In function `OPENSSL_showfatal':
.\crypto\cryptlib.c:670: error: `TCHAR' undeclared (first use in this function)
.\crypto\cryptlib.c:670: error: syntax error before "buf"
.\crypto\cryptlib.c:671: error: syntax error before '*' token
.\crypto\cryptlib.c:686: error: `fmt' undeclared (first use in this function)
.\crypto\cryptlib.c:686: error: syntax error before "TCHAR"
.\crypto\cryptlib.c:689: warning: implicit declaration of function `strlen'
.\crypto\cryptlib.c:690: error: `WCHAR' undeclared (first use in this function)
.\crypto\cryptlib.c:690: error: `fmtw' undeclared (first use in this function)
.\crypto\cryptlib.c:695: error: syntax error before ')' token
.\crypto\cryptlib.c:697: error: syntax error before "TCHAR"
.\crypto\cryptlib.c:697: error: break statement not within loop or switch
.\crypto\cryptlib.c:700: warning: implicit declaration of function `MultiByteToWideChar'
.\crypto\cryptlib.c:700: error: `CP_ACP' undeclared (first use in this function)
.\crypto\cryptlib.c:702: error: syntax error before "fmta"
.\crypto\cryptlib.c:706: error: `keepgoing' undeclared (first use in this function)
.\crypto\cryptlib.c:719: error: syntax error before "TCHAR"
.\crypto\cryptlib.c:669: warning: unused variable `ap'
.\crypto\cryptlib.c: At top level:
.\crypto\cryptlib.c:722: warning: type defaults to `int' in declaration of `__builtin_va_start'
.\crypto\cryptlib.c:722: warning: parameter names (without types) in function declaration
.\crypto\cryptlib.c:722: warning: data definition has no type or storage class
.\crypto\cryptlib.c:723: error: syntax error before "sizeof"
.\crypto\cryptlib.c:724: error: `buf' undeclared here (not in a function)
.\crypto\cryptlib.c:724: error: `TCHAR' undeclared here (not in a function)
.\crypto\cryptlib.c:724: warning: type defaults to `int' in declaration of `buf'
.\crypto\cryptlib.c:724: warning: implicit declaration of function `_T'
.\crypto\cryptlib.c:724: error: invalid initializer
.\crypto\cryptlib.c:724: warning: data definition has no type or storage class
.\crypto\cryptlib.c:725: warning: type defaults to `int' in declaration of `__builtin_va_end'
.\crypto\cryptlib.c:725: warning: parameter names (without types) in function declaration
.\crypto\cryptlib.c:725: warning: data definition has no type or storage class
.\crypto\cryptlib.c:729: error: syntax error before "if"
.\crypto\cryptlib.c:731: error: syntax error before '*' token
.\crypto\cryptlib.c:731: warning: type defaults to `int' in declaration of `pmsg'
.\crypto\cryptlib.c:731: warning: data definition has no type or storage class
.\crypto\cryptlib.c:732: error: syntax error before numeric constant
.\crypto\cryptlib.c:732: warning: type defaults to `int' in declaration of `ReportEvent'
.\crypto\cryptlib.c:732: warning: data definition has no type or storage class
.\crypto\cryptlib.c:733: warning: type defaults to `int' in declaration of `DeregisterEventSource'
.\crypto\cryptlib.c:733: warning: parameter names (without types) in function declaration
.\crypto\cryptlib.c:733: warning: data definition has no type or storage class
.\crypto\cryptlib.c:734: error: syntax error before '}' token
.\crypto\cryptlib.c: In function `OpenSSLDie':
.\crypto\cryptlib.c:755: warning: implicit declaration of function `abort'
.\crypto\cryptlib.c: In function `OPENSSL_stderr':
.\crypto\cryptlib.c:758: error: `stderr' undeclared (first use in this function)
.\crypto\cryptlib.c: In function `OPENSSL_isservice':
.\crypto\cryptlib.c:642: warning: statement with no effect
.\crypto\cryptlib.c:651: warning: statement with no effect
.\crypto\cryptlib.c: In function `OPENSSL_showfatal':
.\crypto\cryptlib.c:686: warning: statement with no effect
.\crypto\cryptlib.c:702: warning: statement with no effect
mingw32-make: *** [tmp\cryptlib.o] Error 1
C:\openssl-0.9.8e>