[Bug target/26052] cygwin's defnes does not honor the -undef option
--- Comment #4 from gerrit at gcc dot gnu dot org 2006-02-02 16:09 --- IMO it should be coded in the executable itself that -undef skips reading the specs at all. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26052
[Bug libstdc++/16612] empty basic_strings can't live in shared memory
--- Comment #30 from gerrit at gcc dot gnu dot org 2005-10-05 22:09 --- It crashes on Cygwin too. I wonder if --enable-fully-dynamic-string should be the default when building on platforms where it is known to fail without this option. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16612
[Bug libstdc++/24196] Using string instances to pass arguments to dlls fails
--- Comment #1 from gerrit at gcc dot gnu dot org 2005-10-04 19:08 --- Created an attachment (id=9877) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=9877&action=view) Testcase which demostrates the problem -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24196
[Bug libstdc++/24196] New: Using string instances to pass arguments to dlls fails
Hello, I noticed the following problem while porting an internal C++ application from linux to Cygwin. If a std::string instance created in one module (exe or dll) is passed to another say as an argument of a function call, the program crashes or hangs. I did debug for a while and it turned out that it is not the program itself that causes the crash - the cause lies in the std::string implementation, the fact that libstdc++ is provided as a static archive and that it is compiled without _GLIBCXX_FULLY_DYNAMIC_STRING defined. What happens is that each module which links agains libstdc++ get its very personal copy of the class member _S_empty_rep_storage. Now since _GLIBCXX_FULLY_DYNAMIC_STRING is not defined an empty string instance i.e. one that is created by the default constructor of std::string gets a pointer to _S_empty_rep_storage i.e. the actual allocation of memory is delayed until memory is really needed. If _GLIBCXX_FULLY_DYNAMIC_STRING is defined each string instance would get a pointer to a newly heap allocated block of memory instead . Now look at the ouput of gdb and nm used on the attached testcase: [EMAIL PROTECTED] ~/src/testcase/tc $ nm dll.dll | grep _S_empty_rep_storage 1000c030 d .data$_ZNSs4_Rep20_S_empty_rep_storageE 1000c030 D __ZNSs4_Rep20_S_empty_rep_storageE [EMAIL PROTECTED] ~/src/testcase/tc $ nm main.exe | grep _S_empty_rep_storage 00442120 d .data$_ZNSs4_Rep20_S_empty_rep_storageE 00442120 D __ZNSs4_Rep20_S_empty_rep_storageE === Breakpoint 1, main (argc=1, argv=0x10042980) at main.cc:9 9 { (gdb) n 10string s, s1; (gdb) 12export1 (s); (gdb) print s $1 = {static npos = 4294967295, _M_dataplus = {> = {> = {}, }, _M_p = 0x44212c ""}} (gdb) print s1 $2 = {static npos = 4294967295, _M_dataplus = {> = {> = {}, }, _M_p = 0x44212c ""}} === Here the two strings share _S_empty_rep_storage. === (gdb) step export1 ([EMAIL PROTECTED]) at dll.cc:7 7 string s1; (gdb) n 9 s1.push_back ('A'); (gdb) n 10s.push_back ('A'); (gdb) print s $3 = (string &) @0x22eea0: {static npos = 4294967295, _M_dataplus = {> = {> = {}, }, _M_p = 0x44212c ""}} (gdb) print s1 $4 = {static npos = 4294967295, _M_dataplus = {> = {> = {}, }, _M_p = 0x10042aec "A"}} (gdb) === Here s1 points to the dll local _S_empty_rep_storage. The _M_p member of _M_dataplus is pointing to different copies of _S_empty_rep_storage - one stored in the executable which calls the dll and another one in the dll itself. Now the second push_back() call in export1 () will end up calling _M_mutate() to actually allocate storage. _M_mutate() will call _M_rep()->_M_dispose() which will end up free()-ing the memory reserved for _S_empty_rep_storage in the main exe. There is a check to prevent free()-ing _S_empty_rep_storage: #ifndef _GLIBCXX_FULLY_DYNAMIC_STRING if (__builtin_expect(this != &_S_empty_rep(), false)) #endif but it doesn't work well in the case when a string instance created in one module is passed to another and libstdc++ is statically linked because of the fact that each module has its own copy _S_empty_rep_storage. Can we get this fixed ? -- Summary: Using string instances to pass arguments to dlls fails Product: gcc Version: 3.4.4 Status: UNCONFIRMED Severity: normal Priority: P2 Component: libstdc++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: gerrit at gcc dot gnu dot org GCC build triplet: i686-pc-cygwin GCC host triplet: i686-pc-cygwin GCC target triplet: i686-pc-cygwin http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24196
[Bug target/23093] base class template specialization in library
-- What|Removed |Added CC||gerrit at gcc dot gnu dot ||org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23093
[Bug ada/20530] gnatlink does not respect -mno-cygwin
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-06-08 12:40 --- >> According to >> http://gcc.gnu.org/onlinedocs/gcc-3.4.3/gcc/Option-Index.html#Option-Index >> >> -mno-cygwin is not a FSF option, so closing this PR. This option just triggers gcc to use other lib and include paths, as they are defined in the specs. So it seems gnat doesn't use the specs when linking. Note that it works quite well with include paths when compiling the source? I will provide a workaround in the upcoming release of cygwin gcc-3.4.4, in addition to -mno-cygwin another flag is needed then: --RTS=no-cygwin This will cause gnat to pick up the right runtime if the gcc-mingw-ada package is correctly installed. Then there is a new subdirectory in i686-pc-cygwin/3.4.4 named no-cygwin with symlinks to the mingw runtime: /---3.4.4 | /---adainclude | /---adalib | /---no-cygwin | +---adainclude | +---adalib $ gcc -v -c --RTS=no-cygwin -mno-cygwin hello_a.adb Reading specs from /usr/lib/gcc/i686-pc-mingw32/3.4.4/specs Configured with: /gcc/gcc-3.4.4/gcc-3.4.4-1/configure --verbose --prefix=/usr --exec-prefix=/usr --sysconfdir=/etc --libdir=/usr/lib --libexecdir=/usr/lib --mandir=/usr/share/man --infodir=/usr/share/info --enable-languages=c,ada,c++,d,f77,java,objc --enable-nls --without-included-gettext --enable-version-specific-runtime-libs --without-x --enable-libgcj --disable-java-awt --with-system-zlib --enable-interpreter --disable-libgcj-debug --enable-threads=posix --enable-java-gc=boehm --disable-win32-registry --enable-sjlj-exceptions --enable-hash-synchronization --enable-libstdcxx-debug : (reconfigured) Thread model: posix gcc version 3.4.4 (cygming special) (gdc 0.12, using dmd 0.125) /usr/lib/gcc/i686-pc-mingw32/3.4.4/gnat1.exe -quiet -dumpbase hello_a.adb -mno-cygwin -mtune=pentiumpro -fRTS=no-cygwin hello_a.adb -o /tmp/ccqn0PMb.s /usr/lib/gcc/i686-pc-mingw32/3.4.4/../../../../i686-pc-mingw32/bin/as.exe -o hello_a.o /tmp/ccqn0PMb.s $ gnatbind -v -aO./ --RTS=no-cygwin -I- -x hello_a.ali GNATBIND 3.4.4 (cygming special) (gdc 0.12, using dmd 0.125) Copyright 1995-2004 Free Software Foundation, Inc. Binding: hello_a.ali No errors $ gnatlink hello_a.ali -mno-cygwin -v GNATLINK 3.4.4 (cygming special) (gdc 0.12, using dmd 0.125) Copyright 1995-2004 Free Software Foundation, Inc gcc -c -gnatA -gnatWb -gnatiw -mno-cygwin -mtune=pentiumpro --RTS=no-cygwin -gnatws b~hello_a.adb /usr/bin/gcc.exe b~hello_a.o ./hello_a.o -mno-cygwin -o hello_a.exe -L./ -L/usr/lib/gcc/i686-pc-cygwin/3.4.4/no-cygwin/adalib/ /usr/lib/gcc/i686-pc-cygwin/3.4.4/no-cygwin/adalib/libgnat.a -Wl,--stack=0x200 $ cygcheck hello_a.exe Found: h:\cygwin\gcc\gcc-test\hello_a.exe h:/cygwin/gcc/gcc-test/hello_a.exe C:\WINNT\System32\msvcrt.dll C:\WINNT\System32\KERNEL32.dll C:\WINNT\System32\ntdll.dll C:\WINNT\System32\ADVAPI32.DLL C:\WINNT\System32\USER32.dll C:\WINNT\System32\GDI32.dll C:\WINNT\System32\RPCRT4.dll Running this executable works fine. I'll try to find a way to integrate this in to the binary to make it work as one expect it to work. Gerrit -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20530
[Bug ada/20530] gnatlink does not respect -mno-cygwin
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-06-08 12:22 --- (In reply to comment #2) > Right, gnatmake has never supported -mno-cygwin. Instead, I'd suggest > configuring gcc for mingw to start with. > > According to > http://gcc.gnu.org/onlinedocs/gcc-3.4.3/gcc/Option-Index.html#Option-Index > > -mno-cygwin is not a FSF option, so closing this PR. > > Arno Many thanks. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20530
[Bug middle-end/21836] internal compiler error: in valid_in_set, at tree-ssa-pre.c:1082 when compiling libstdc++-v3/src/ctype.cc
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-05-31 16:23 --- Many thanks. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21836
[Bug libstdc++/21836] internal compiler error: in valid_in_set, at tree-ssa-pre.c:1082 when compiling libstdc++-v3/src/ctype.cc
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-05-31 10:31 --- I applied the patch from http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21173 I'll reconfigure and rebuild now. See you later, Gerrit -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21836
[Bug libstdc++/21836] internal compiler error: in valid_in_set, at tree-ssa-pre.c:1082 when compiling libstdc++-v3/src/ctype.cc
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-05-31 09:40 --- It compiles ok when using -O2 instead of -O3, i.e. it is the flag -finline-functions Gerrit -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21836
[Bug libstdc++/21836] internal compiler error: in valid_in_set, at tree-ssa-pre.c:1082 when compiling libstdc++-v3/src/ctype.cc
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-05-31 09:30 --- Created an attachment (id=8998) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=8998&action=view) ctype.s -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21836
[Bug libstdc++/21836] internal compiler error: in valid_in_set, at tree-ssa-pre.c:1082 when compiling libstdc++-v3/src/ctype.cc
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-05-31 09:29 --- Created an attachment (id=8997) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=8997&action=view) ctype.ii -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21836
[Bug libstdc++/21836] New: internal compiler error: in valid_in_set, at tree-ssa-pre.c:1082 when compiling libstdc++-v3/src/ctype.cc
gcc-4.0.0, confiured with: CFLAGS='-O3 -pipe -march=i486 -funroll-loops' \ CXXFLAGS='-O3 -pipe -march=i486 -funroll-loops' \ LIBCFLAGS='-O3 -pipe -march=i486 -funroll-loops' \ LIBCXXFLAGS='-O3 -pipe -march=i486 -funroll-loops' \ LDFLAGS='-Wl,-s -Wl,--stack=0x0080' \ JCFLAGS='-O3 -pipe -march=i486 -funroll-loops' \ LIBGCJ_CFLAGS='-O3 -pipe -march=i486 -D__NO_MATH_INLINES -ffloat-store -fno-omit-frame-pointer -funroll-loops' \ LIBGCJ_CXXFLAGS='-O3 -pipe -march=i486 -D__NO_MATH_INLINES -ffloat-store -fno-omit-frame-pointer -funroll-loops' \ LIBGCJ_JAVAFLAGS='-O3 -pipe -march=i486 -ffloat-store -fno-omit-frame-pointer -funroll-loops' \ GNATLIBCFLAGS='-O3 -pipe -march=i486 -funroll-loops' \ ../configure \ --verbose \ --prefix=/usr \ --exec-prefix=/usr \ --sysconfdir=/etc \ --libdir=/usr/lib \ --libexecdir=/usr/lib \ --mandir=/usr/share/man \ --infodir=/usr/share/info \ --enable-bootstrap \ --enable-languages=c,ada,c++,f95,java,objc,treelang \ --enable-nls \ --without-included-gettext \ --enable-version-specific-runtime-libs \ --enable-libada \ --without-x \ --enable-libgcj \ --disable-java-awt \ --with-system-zlib \ --enable-interpreter \ --disable-libgcj-debug \ --enable-threads=posix \ --enable-java-gc=boehm \ --disable-win32-registry \ --disable-sjlj-exceptions \ --enable-hash-synchronization \ --enable-libstdcxx-debug getting error in tree-ssa-pre.c when compiling this file libstdc++-v3/src/ctype.cc: /gcc/gcc4/gcc-4.0.0-1/.build/gcc/xgcc \ -shared-libgcc \ -B/gcc/gcc4/gcc-4.0.0-1/.build/gcc/ \ -nostdinc++ -L/gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3/src \ -L/gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3/src/.libs \ -B/usr/i686-pc-cygwin/bin/ \ -B/usr/i686-pc-cygwin/lib/ \ -isystem /usr/i686-pc-cygwin/include \ -isystem /usr/i686-pc-cygwin/sys-include \ -I/gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3/include/i686-pc-cygwin \ -I/gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3/include \ -I/gcc/gcc4/gcc-4.0.0-1/libstdc++-v3/libsupc++ \ -O3 \ -pipe \ -march=i486 \ -funroll-loops \ -fno-implicit-templates \ -Wall \ -Wextra \ -Wwrite-strings \ -Wcast-qual \ -fdiagnostics-show-location=once \ -ffunction-sections \ -fdata-sections \ -c /gcc/gcc4/gcc-4.0.0-1/libstdc++-v3/src/ctype.cc -o ctype.o /gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3/include/i686-pc-cygwin/bits/ctype_noninline.h: In constructor 'std::ctype::ctype(int*, const char*, bool, size_t)': /gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3/include/i686-pc-cygwin/bits/ctype_noninline.h:41: internal compiler error: in valid_in_set, at tree-ssa-pre.c:1082 Please submit a full bug report, with preprocessed source if appropriate. See http://gcc.gnu.org/bugs.html> for instructions. make[3]: *** [ctype.lo] Error 1 make[3]: Leaving directory `/gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3/src' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3' make[1]: *** [all] Error 2 make[1]: Leaving directory `/gcc/gcc4/gcc-4.0.0-1/.build/i686-pc-cygwin/libstdc++-v3' make: *** [all-target-libstdc++-v3] Error 2 -- Summary: internal compiler error: in valid_in_set, at tree-ssa- pre.c:1082 when compiling libstdc++-v3/src/ctype.cc Product: gcc Version: 4.0.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: libstdc++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: gerrit at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org GCC build triplet: i686-pc-cygwin GCC host triplet: i686-pc-cygwin GCC target triplet: i686-pc-cygwin http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21836
[Bug rtl-optimization/15584] Ada build with stage1 bootstrap compiler fails.
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-05-29 02:25 --- No longer a problem with gcc-3.4.2. -- What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15584
[Bug libgcj/13708] static java program crashes at startup, UTF-8 environment
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-05-29 02:09 --- (In reply to comment #29) > *** Bug 21793 has been marked as a duplicate of this bug. *** The same example works with the MinGW version of gcj-3.4.2? And it works when I set the encoding to ISO-8859-1: $ /usr/bin/gcj -Dfile.encoding=ISO-8859-1 --main=hello_j hello_j.java -o hello_j $ ./hello_j Just another Java hacker, How do I set the default encoding to ISO-8859-1 when building gcj? And when will GCC be switched to use >= libtool-1.5.10 and newer automake & autoconf versions? Shared libraries are not supported by the antiquated libtool and friends used by GCC. Gerrit -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13708
[Bug java/21793] java doesn't work with Cygwin
--- Additional Comments From gerrit at gcc dot gnu dot org 2005-05-28 00:20 --- $ gdb hello_j.exe GNU gdb 6.3.50_2004-12-28-cvs (cygwin-special) Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i686-pc-cygwin"... (gdb) run Starting program: /gcc/gcc-test/hello_j.exe warning: LDR: Automatic DLL Relocation in hello_j.exe warning: LDR: Dll cygz.dll base 1000 relocated due to collision with h:\cygwin\bin\cyg iconv-2.dll warning: LDR: Automatic DLL Relocation in hello_j.exe warning: LDR: Dll MSVCRT.dll base 7800 relocated due to collision with C:\WINNT\system 32\GDI32.dll Program received signal SIGSEGV, Segmentation fault. 0x00406618 in _Jv_FindClass () (gdb) bt #0 0x00406618 in _Jv_FindClass () #1 0x0040fd58 in java::lang::Class::forName () #2 0x0040fec4 in java::lang::Class::forName () #3 0x0047c0ed in gnu.gcj.convert.UnicodeToBytes.getDefaultEncoder() () at /gcc/gcc-3.4.2/gcc-3.4.2-1/libjava/gnu/gcj/convert/UnicodeToBytes.java:49 #4 0x0044a12e in java.io.PrintStream.PrintStream(java.io.OutputStream, boolean) ( this=0x10150f90, out=0x1014dab0, auto_flush=269647105) at /gcc/gcc-3.4.2/gcc-3.4.2-1/libjava/java/io/PrintStream.java:118 #5 0x004043f1 in java.lang.System.() () at /gcc/gcc-3.4.2/gcc-3.4.2-1/libjava/java/lang/System.java:146 #6 0x0040f6dd in java::lang::Class::initializeClass () #7 0x00543aca in _Jv_InitClass () #8 0x004047a1 in java.lang.System.getProperty(java.lang.String) (key=0x10130f00) at /gcc/gcc-3.4.2/gcc-3.4.2-1/libjava/java/lang/System.java:405 #9 0x0044be58 in java.lang.VMClassLoader.getSystemClassLoader() () at /gcc/gcc-3.4.2/gcc-3.4.2-1/libjava/java/lang/VMClassLoader.java:280 #10 0x0041182b in java.lang.ClassLoader.() () at /gcc/gcc-3.4.2/gcc-3.4.2-1/libjava/java/lang/ClassLoader.java:156 #11 0x0040f6dd in java::lang::Class::initializeClass () #12 0x004038af in _Jv_CreateJavaVM () #13 0x00403956 in _Jv_RunMain () #14 0x00403b1b in JvRunMain () #15 0x0040109e in main (argc=1, argv=0x10102ca0) (gdb) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21793
[Bug java/21793] New: java doesn't work with Cygwin
file hello_j.java: public class hello_j { public static void main(String[] args) { System.out.println("Just another Java hacker,"); } } /usr/bin/gcj --main=hello_j hello_j.java -o hello_j ./hello_j Signal 11 -- Summary: java doesn't work with Cygwin Product: gcc Version: 3.4.2 Status: UNCONFIRMED Severity: normal Priority: P2 Component: java AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: gerrit at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org,java-prs at gcc dot gnu dot org GCC build triplet: i686-pc-cygwin GCC host triplet: i686-pc-cygwin GCC target triplet: i686-pc-cygwin http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21793
[Bug libf2c/21792] New: --enable-version-specific-runtime-libs doesn't install version specific fortran & java libs
The configure switch --enable-version-specific-runtime-libs is not honored by java at all, and g77 is not correct too. Where libgcc and other defaults are installed version specific anyway, with or without this switch: usr/lib/gcc/i686-pc-cygwin/3.4.2/libgcc.a usr/lib/gcc/i686-pc-cygwin/3.4.2/libgcov.a it works ok for objc: usr/lib/gcc/i686-pc-cygwin/3.4.2/libobjc.a usr/lib/gcc/i686-pc-cygwin/3.4.2/libobjc.la ok for c++: usr/lib/gcc/i686-pc-cygwin/3.4.2/libstdc++.a usr/lib/gcc/i686-pc-cygwin/3.4.2/libstdc++.la usr/lib/gcc/i686-pc-cygwin/3.4.2/libsupc++.a usr/lib/gcc/i686-pc-cygwin/3.4.2/libsupc++.la usr/lib/gcc/i686-pc-cygwin/3.4.2/specs not ok for fortran: usr/lib/gcc/i686-pc-cygwin/libfrtbegin.a usr/lib/gcc/i686-pc-cygwin/libg2c.a usr/lib/gcc/i686-pc-cygwin/libg2c.la and even worse, not ok for java: usr/lib/lib-org-w3c-dom.a usr/lib/lib-org-w3c-dom.la usr/lib/lib-org-xml-sax.a usr/lib/lib-org-xml-sax.la usr/lib/libffi.a usr/lib/libffi.la usr/lib/libgcj.a usr/lib/libgcj.la usr/lib/libgcj.spec usr/lib/libiberty.a Regards, Gerrit P. Haase -- Summary: --enable-version-specific-runtime-libs doesn't install version specific fortran & java libs Product: gcc Version: 3.4.2 Status: UNCONFIRMED Severity: normal Priority: P2 Component: libf2c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: gerrit at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org GCC build triplet: i686-pc-cygwin GCC host triplet: i686-pc-cygwin GCC target triplet: i686-pc-cygwin http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21792
[Bug bootstrap/18547] Cygwin
--- Additional Comments From gerrit at gcc dot gnu dot org 2004-11-21 16:30 --- (In reply to comment #1) > Text mode is the default at least according to C89 so the bug is in cygwin and not GCC. If you want a file to be mode 'A' then read/write it in this mode explicitly. You cannot expect the underlying OS to know who is reading/writing a file and how to do it without explicitly telling the OS what is expected. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18547