nick wrote:
Nick Ioffe wrote:
Also before that I got some strange errors when configure erroneusly created rts-config.h file - it didn't found open64 and usleep functions in /usr/local/include/fcntl.h - it was discovered by compiler.
What exactly was set? HAVE_OPEN64 and/or OPEN64_DECLARED?
- The OPEN64_DECLARED.
You mean OPEN64_DECLARED was set and HAVE_OPEN64 not, right? And what exactly was the error message by the compiler?
- The rts-config.h had OPEN64_DEFINED undefined, while HAVE_OPEN64 set to
- That caused the redeclaration of open64 with some gpc file which is
conflicting with /usr/local/include/fcntl.h.
You can look in <build>/gcc/p/rts/config.log for the error messages (search for `open64', two places). (If you did several compilations already, you might have to remove config.cache in that directory and make again, because the messages may have been overwritten.)
Or you could try to compile this C program. Does it work, or are there any errors or warnings?
#define _GNU_SOURCE #define _LARGEFILE64_SOURCE #define _FILE_OFFSET_BITS 64 #include <fcntl.h> typedef void (*fntype); volatile fntype tmp; int main() { tmp = (void (*)) open64; return 0; }
Perhaps it's a directory problem (/usr/local/include seems strange for a system header). Does it help if you set `GCC_FOR_TARGET' to `gcc -I /usr/local/include' (and remove all files in <build>/gcc/p/rts, so the RTS is configured again)?
- It is hard to me to provide the example since the machine I run the gpc
is not connected to the Internet. The only thing I can say is that the same module compiled well with gpc- 200205??. I'll try to bring some example...
With luck, you can reduce it so you easily copy it by typing.
Frank