enmora
06-16-2004, 06:47 PM
I had tried to run the code in the book but neither them has been working.
I followed the indications from the page 2 and the compiler says that have errors despite of try to compile all archives that the book says, obtaining the foolow message:
[enrique@localhost other]$ g++ flmoon.cpp
/usr//bin/../lib/gcc-lib/i586-mandrake-linux-gnu/3.3.1/../../../crt1.o(.text+0x18): In function `_start':
../sysdeps/i386/elf/start.S:98: undefined reference to `main'
collect2: ld returned 1 exit status
[enrique@localhost other]$ g++ avevar.cpp
/usr//bin/../lib/gcc-lib/i586-mandrake-linux-gnu/3.3.1/../../../crt1.o(.text+0x18): In function `_start':
../sysdeps/i386/elf/start.S:98: undefined reference to `main'
collect2: ld returned 1 exit status
[enrique@localhost other]$ g++ unonr.cpp
unonr.cpp: In function `int main()':
unonr.cpp:11: error: `ntot' undeclared (first use this function)
unonr.cpp:11: error: (Each undeclared identifier is reported only once for each function it appears in.)
unonr.cpp:17: error: 'class Vec_DP' has no member named 'ave'
unonr.cpp:21:2: warning: no newline at end of file
I followed the indications from the page 2 and the compiler says that have errors despite of try to compile all archives that the book says, obtaining the foolow message:
[enrique@localhost other]$ g++ flmoon.cpp
/usr//bin/../lib/gcc-lib/i586-mandrake-linux-gnu/3.3.1/../../../crt1.o(.text+0x18): In function `_start':
../sysdeps/i386/elf/start.S:98: undefined reference to `main'
collect2: ld returned 1 exit status
[enrique@localhost other]$ g++ avevar.cpp
/usr//bin/../lib/gcc-lib/i586-mandrake-linux-gnu/3.3.1/../../../crt1.o(.text+0x18): In function `_start':
../sysdeps/i386/elf/start.S:98: undefined reference to `main'
collect2: ld returned 1 exit status
[enrique@localhost other]$ g++ unonr.cpp
unonr.cpp: In function `int main()':
unonr.cpp:11: error: `ntot' undeclared (first use this function)
unonr.cpp:11: error: (Each undeclared identifier is reported only once for each function it appears in.)
unonr.cpp:17: error: 'class Vec_DP' has no member named 'ave'
unonr.cpp:21:2: warning: no newline at end of file