Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   C Programming (http://www.velocityreviews.com/forums/f42-c-programming.html)
-   -   gcc 3.3, solaris 8, compile error - 'strftime', 'localtime', etc. "not declared" (http://www.velocityreviews.com/forums/t314839-gcc-3-3-solaris-8-compile-error-strftime-localtime-etc-not-declared.html)

Bimal 08-20-2003 11:24 AM

gcc 3.3, solaris 8, compile error - 'strftime', 'localtime', etc. "not declared"
 
Hi,

I upgraded my gcc from 2.95 to 3.3. When I compile some projects I get
error messages saying...

/usr/local/include/c++/3.3/ctime:68: error: `tm' not declared
/usr/local/include/c++/3.3/ctime:70: error: `clock' not declared
/usr/local/include/c++/3.3/ctime:71: error: `difftime' not declared
/usr/local/include/c++/3.3/ctime:72: error: `mktime' not declared
/usr/local/include/c++/3.3/ctime:73: error: `time' not declared
/usr/local/include/c++/3.3/ctime:74: error: `asctime' not declared
/usr/local/include/c++/3.3/ctime:75: error: `ctime' not declared
/usr/local/include/c++/3.3/ctime:76: error: `gmtime' not declared
/usr/local/include/c++/3.3/ctime:77: error: `localtime' not declared
/usr/local/include/c++/3.3/ctime:78: error: `strftime' not declared

Can anyone help?

Thanks.

Tim Prince 08-20-2003 12:33 PM

Re: gcc 3.3, solaris 8, compile error - 'strftime', 'localtime', etc. "not declared"
 
Bimal wrote:

> Hi,
>
> I upgraded my gcc from 2.95 to 3.3. When I compile some projects I get
> error messages saying...
>
> /usr/local/include/c++/3.3/ctime:68: error: `tm' not declared
> /usr/local/include/c++/3.3/ctime:70: error: `clock' not declared
> /usr/local/include/c++/3.3/ctime:71: error: `difftime' not declared
> /usr/local/include/c++/3.3/ctime:72: error: `mktime' not declared
> /usr/local/include/c++/3.3/ctime:73: error: `time' not declared
> /usr/local/include/c++/3.3/ctime:74: error: `asctime' not declared
> /usr/local/include/c++/3.3/ctime:75: error: `ctime' not declared
> /usr/local/include/c++/3.3/ctime:76: error: `gmtime' not declared
> /usr/local/include/c++/3.3/ctime:77: error: `localtime' not declared
> /usr/local/include/c++/3.3/ctime:78: error: `strftime' not declared
>
> Can anyone help?

It's hard to see how you could get these, unless you have mixed up C++ and
C in some fashion. If you had C code, #include <time.h> should take care
of these declarations.

--
Tim Prince


All times are GMT. The time now is 09:14 AM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.