On Wed 1/11/2006 4:43 PM Per-Anton Rønning wrote:
> Hi all!
> Any C/C++ progremmers out there? I have just installed gcc 3.3.2
> (Mandrakelinux 10.0) and I am about to
> try it out. A very simple program (3 statements) still results in a
> cryptic  error message
>
> make -k vinWS
> gcc  -o vinWS  vinWS.cc
> /home/par/tmp/ccuXGsh7.o(.eh_frame+0x11): undefined reference to
> `__gxx_personality_v0'
> collect2: ld returned 1 exit status
> make: *** [vinWS] Error 1
> Compilation exited abnormally with code 2 at Thu Jan 12 00:26:56
>
> From time to time such errors pop up, but they always seem to have an
> obvious reason.
>
> How could a program like this cause such an error:
> ---------------------------------------
> #include <stdio.h>
> #include <stdlib.h>
> #include <math.h>                
> #include "/home/par/libs/baselib.h"  
> 
>
>  // --- #define    ----     
>
> // --- Externals  ----
>
> // --- Function Prototypes ----
>
>
> // --- Files      ----
>
> FILE *fopen(const char *fn, const char *mode);
>
> // --- structs   ----      
>
> // --- definition of variables ----
> char cmd[100];
>
> /*=======================================================*/
> int main(int argv,char *argc[]){
>   int i,j,k,l,m,n;
>
>  sprintf(cmd,"ls ./WS/*.htm*");
>  printf("cmd=%s\n",cmd);
>  i=system(cmd);
> }
> /*====================================================*/
> Statements like this I have written 1000's of times in previous C programs.
> Is there something missing in my gcc compiler? I installed it today.
 
Your program compiles and runs fine on my 10.1 system, which has gcc 3.4.1.
So I would guess that your gcc installation is somehow screwed up.
 
HTH,
-larry


____________________________________________________
Want to buy your Pack or Services from Mandriva? 
Go to http://store.mandriva.com
Join the Club : http://www.mandrivaclub.com
____________________________________________________

<<winmail.dat>>

Reply via email to