Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dev-C++ compiler giving error `__gxx_personality_v0' 1

Status
Not open for further replies.

computerwhiz

Programmer
May 1, 2002
28
US
I keep getting this error I have listed below but I cannot figure out what is causing it. Please help. I would show you code but I don't even know what is causing the error.

Compiler: Default compiler
Building Makefile: "C:\WINDOWS\Desktop\mysource\Makefile.win"
Executing make...
make.exe -f "C:\WINDOWS\Desktop\mysource\Makefile.win" all
windres.exe -i chkparser_private.rc -I rc -o chkparser_private.res -O coff

gcc.exe Main.o chkparser_private.res -o "chkparser.exe" -L"C:/DEV-CPP/lib" -mwindows

Main.o(.eh_frame+0x11):Main.c: undefined reference to `__gxx_personality_v0'

Execution terminated
 
This is the make file:

# Project: chkparser
# Makefile created by Dev-C++ 4.9.8.7

CPP = g++.exe
CC = gcc.exe
WINDRES = windres.exe
RES = chkparser_private.res
OBJ = Main.o $(RES)
LINKOBJ = Main.o $(RES)
LIBS = -L"C:/DEV-CPP/lib" -mwindows
INCS = -I"C:/DEV-CPP/include"
CXXINCS = -I"C:/DEV-CPP/include/c++" -I"C:/DEV-CPP/include/c++/mingw32" -I"C:/DEV-CPP/include/c++/backward" -I"C:/DEV-CPP/include"
BIN = chkparser.exe
CXXFLAGS = $(CXXINCS) -fexpensive-optimizations -O3
CFLAGS = $(INCS) -fexpensive-optimizations -O3

.PHONY: all all-before all-after clean clean-custom

all: all-before chkparser.exe all-after


clean: clean-custom
rm -f $(OBJ) $(BIN)

$(BIN): $(OBJ)
$(CC) $(LINKOBJ) -o "chkparser.exe" $(LIBS)

Main.o: Main.c
$(CPP) -c Main.c -o Main.o $(CXXFLAGS)

chkparser_private.res: chkparser_private.rc Menu.rc
$(WINDRES) -i chkparser_private.rc -I rc -o chkparser_private.res -O coff
 
For some reason, it thinks your C code is C++ (it compiled it with g++, yet it's linking it with gcc)

> $(CPP) -c Main.c -o Main.o $(CXXFLAGS)
Compiled with C++

> gcc.exe Main.o chkparser_private.res -o "chkparser.exe" -L"C:/DEV-CPP/lib" -mwindows
Linked with C

Dunno what to do to fix it (recreating the project would probably fix things).
Or maybe try a 'make clean' to start with
Or perhaps 'rebuild all'

--
 
absolutely perfect, I took my files and placed them into a new project and when I compiled it worked. thank you very much.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top