Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Invalid
-
4.2.0, 4.2.1
-
None
-
Ubuntu Linux, Cygwin, MinGW
-
Incorrect Behavior
Description
On Cygwin it's possible to build library in two modes:
1) with using cygwin1.dll (POSIX compatibility layer)
2) without using cygwin1.dll - the same result as if you're using MinGW compiler
For building library in MinGW mode the compiler and linker options should be extended with -mno-cygwin option.
I've tried to use CPPOPTS, CXXOPTS and LDOPTS make variables, described in README file:
$ make builddir BUILDDIR=mingw15s BUILDTYPE=15s CONFIG=gcc.config CXXOPTS=-mno-cygwin LDOPTS=-mno-cygwin $ cd mingw15s/include && make CXXOPTS=-mno-cygwin LDOPTS=-mno-cygwin
The config.log file shows that -mno-cygwin option is used only once at linking stage of the sanity test:
int main () { return 0; } gcc -D_RWSTDDEBUG -D_REENTRANT -mthreads -I. -pedantic -nostdinc++ -g -W -Wall -Wcast-qual -Winline -Wshadow -Wwrite-strings -Wno-long-long -Wcast-align -c a.cpp -o a.o gcc a.o -mthreads -mno-cygwin -lm -lsupc++ -lcatgets -liconv -o a.out int main () { return sizeof (int); } int main () { return sizeof (long); } int main () { return sizeof (long long); } int main () { return sizeof (void*); } int main () { int i = 1; return *(char*)&i; } gcc -E -D_RWSTDDEBUG -D_REENTRANT -mthreads -pedantic -nostdinc++ -g /tmp/assert-2408.cpp >/tmp/assert-2408.i /tmp/assert-2408.cpp:1:19: cassert: No such file or directory gcc -E -D_RWSTDDEBUG -D_REENTRANT -mthreads -pedantic -nostdinc++ -g /tmp/assert-2408.cpp >/tmp/assert-2408.i ...
The same effect observing on Ubuntu Linux.