This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/14291] [3.4/3.5 Regression] -fprofile-arcs fails (unresolved symbol)
- From: "dannysmith at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 Mar 2004 09:41:24 -0000
- Subject: [Bug target/14291] [3.4/3.5 Regression] -fprofile-arcs fails (unresolved symbol)
- References: <20040225150311.14291.xtrochu@yahoo.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From dannysmith at gcc dot gnu dot org 2004-03-16 09:41 -------
Umm, the mingw runtime has a function
int _chsize (int, long);
declared in io.h (could also include unistd.h, which basically maps to io.h)
It does exactly the same thing as ftruncate, at least as used
by gcov.
So a simple
#ifdef __MINGW32__
# define ftruncate _chsize
#endif
works.
I've been using that for awhile but had forgotten about it.
Danny
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14291