Pelles C > General discussions

__POCC__OLDNAMES

(1/1)

Akko:
I am using latest version 11.00.2. My program does not compile with POCC although it does compile with gcc, vcc, clang, tcc.
Reason: the program section for file I/O uses Posix functions like open, read, close.
However POCC prepends them with an _underscore like _open, _read, _close (declared in <io.h>)
IIUC when the preprocessor symbol __POCC__OLDNAMES is defined, they are recognized in Posix syntax as well.
But I just can't get it to work.

CC-flags: -Tx64-coff -std:C99 -Ob1 -fp:precise -W1 -Gd -Ze -Zx -J
LINK-flags: -machine:x64 -subsystem:console kernel32.lib advapi32.lib delayimp64.lib

If this is no bug but just my incompetence, please feel free to move my posting to where it belongs

TimoVJL:
Use pocc -Go

--- Quote ---Description:
The /Go option makes the compiler accept alternate names for some C runtime functions. It will also define the symbol __POCC__OLDNAMES in the compiler.


--- End quote ---

Akko:
Thanks a lot, that did it!

Accidently I looked up CC options, but not POCC options which are many more, and not all are accessible by the IDE project options dialog box.

frankie:
As general rule of thumbs you should never set compiler internal symbols (those prepended by one or more underscores), because they are automatically set by the compiler when appropriate configuration is selected using compiler switches.
This because the symbols definition could be only a part of internal compiler configuration.

Navigation

[0] Message Index

Go to full version