[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
g++3.0.3 can't do with sleep()
From: |
James Shen |
Subject: |
g++3.0.3 can't do with sleep() |
Date: |
23 Jan 2002 17:55:04 -0800 |
Hi,
I think this is a bug for g++3.0.3 (Solaris). I downloaded a package
of G++3.0.3
and compiled it on my solaris2.6 (SPARC). After installation, I test
it
by a little program as below
//test.cc
#incldue <stdio.h>
#include <unistd.h>
main() {
printf("this is a test for g++3\n");
sleep(5);
printf("succeed!\n");
}
I compile it using g++ , but it always shows :
test.cc: In function `int main()':
test.cc:9: `sleep' undeclared (first use this function)
test.cc:9: (Each undeclared identifier is reported only once for each
function it appears in.)
But the same program can be compiled smoothly by Sun's CC and
g++2.95.3 ( the g++3.0.3 and g++2.95.3 on the same solaris box ).
I don't know whether I missed some option when compiling g++3.0.3 but
I compile
g++2.95.3 with the default configuration.
If there is mistake correct me please.
James
- g++3.0.3 can't do with sleep(),
James Shen <=