[Dev-C++] Compiling errors using Borland Graphics Interface
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Paolo S. <snt...@ne...> - 2003-09-16 13:31:26
|
Hi All,
I need use the Borland Graphics Interface (graphics.h) under Dev-
C++ V 4.9.8.0 installed on WinMe.
I get some errors at compile time.
I have downloaded the files to the correct locations
winbgim.h (download to /Dev-C++/include)
winbgim.cpp (download to /Dev-C++/include)
libbgi.a (download to /Dev-C++/lib)
and added -lbgi -lgdi32 in the "Further object files and linker options"
field.
My test code is:
#include <winbgim.h>
int main()
{
initwindow(400,300); //open a 400x300 graphics window
moveto(0,0);
lineto(50,50);
while(!kbhit()); //wait for user to press a key
closegraph(); //close graphics window
return 0;
}
When compiled I get some errors:
Compilatore: Default compiler
Building Makefile: "C:\Dev-Cpp\Examples\bgi\Makefile.win"
Finding dependencies for file: C:\Dev-Cpp\Examples\bgi\main.cpp
Esecuzione di make...
make.exe -f "C:\Dev-Cpp\Examples\bgi\Makefile.win" all
g++.exe -c main.cpp -o main.o -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" -lbgi -lgdi32
In file included from main.cpp:1:
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `BLACK'
C:/DEV-CPP/include/conio.h:25: previous declaration as `COLORS BLACK'
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `BLUE'
C:/DEV-CPP/include/conio.h:26: previous declaration as `COLORS BLUE'
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `GREEN'
C:/DEV-CPP/include/conio.h:27: previous declaration as `COLORS GREEN'
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `CYAN'
C:/DEV-CPP/include/conio.h:28: previous declaration as `COLORS CYAN'
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `RED'
C:/DEV-CPP/include/conio.h:29: previous declaration as `COLORS RED'
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `MAGENTA'
C:/DEV-CPP/include/conio.h:30: previous declaration as `COLORS MAGENTA'
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `BROWN'
C:/DEV-CPP/include/conio.h:31: previous declaration as `COLORS BROWN'
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `LIGHTGRAY'
C:/DEV-CPP/include/conio.h:32: previous declaration as `COLORS LIGHTGRAY'
C:/DEV-CPP/include/winbgim.h:59: conflicting types for `DARKGRAY'
C:/DEV-CPP/include/conio.h:33: previous declaration as `COLORS DARKGRAY'
C:/DEV-CPP/include/winbgim.h:60: conflicting types for `LIGHTBLUE'
C:/DEV-CPP/include/conio.h:34: previous declaration as `COLORS LIGHTBLUE'
C:/DEV-CPP/include/winbgim.h:60: conflicting types for `LIGHTGREEN'
C:/DEV-CPP/include/conio.h:35: previous declaration as `COLORS LIGHTGREEN'
C:/DEV-CPP/include/winbgim.h:60: conflicting types for `LIGHTCYAN'
C:/DEV-CPP/include/conio.h:36: previous declaration as `COLORS LIGHTCYAN'
C:/DEV-CPP/include/winbgim.h:60: conflicting types for `LIGHTRED'
C:/DEV-CPP/include/conio.h:37: previous declaration as `COLORS LIGHTRED'
C:/DEV-CPP/include/winbgim.h:60: conflicting types for `LIGHTMAGENTA'
C:/DEV-CPP/include/conio.h:38: previous declaration as `COLORS LIGHTMAGENTA'
C:/DEV-CPP/include/winbgim.h:60: conflicting types for `YELLOW'
C:/DEV-CPP/include/conio.h:39: previous declaration as `COLORS YELLOW'
C:/DEV-CPP/include/winbgim.h:61: conflicting types for `WHITE'
C:/DEV-CPP/include/conio.h:41: previous declaration as `COLORS WHITE'
g++.exe main.o -o "Progetto1.exe" -L"C:/DEV-CPP/lib"
G__~1.EXE: main.o: No such file or directory
G__~1.EXE: no input files
Esecuzione terminata
Can Anybody help me ??
Thanks in advance.
Paolo Santinelli.
|