
Linker Error on asctime, ctime, localtime functions...
Hello Techies--
I'm getting the dreaded: LINK2001 unresolved symbol message when
trying to compile (console application) with the following externals:
#include<iostream>
using std::ostream;
#include<cstdlib>
#include<string>
#include<string.h>
#include<errno.h>
#include<time.h>
extern "C" {
extern char *ctime_r(const time_t *clock, char *buf);
extern struct tm *localtime_r(const time_t *clock,
struct tm *result);
extern struct tm *gmtime_r(const time_t *clock, struct tm *result);
extern char *asctime_r(const struct tm *tm, char *buf);
}
< snip >
My project settings for linker look like:
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib
advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib
odbccp32.lib winmm.lib wininet.lib shell32.lib /nologo
/subsystem:console /incremental:yes
/pdb:"Debug/NTTimer.pdb" /debug /machine:I386 /out:"Debug/NTTimer.exe"
/pdbtype:sept
..any insight into this would be greatly appreciated. By the way, the
same code compiles on LINUX without a glitch!
Warm regards,
Paula DiTallo