RE: [Dev-C++] Problem linking in library
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: <ech...@ne...> - 2002-04-08 21:09:41
|
> Hello, > I am very new to Dev-C++ so excuse my ignorance. I've been blindly > using the big money C++ compiler, but now I'm better. > Here is my deal. > > I have a gui development library that utilizes opengl and glut that I > want to link into my appication. > Here are the steps I took. > > 1. Compiled the library > 2. Developed an archive file from the object files using the command > line gcc archive command (ar -ru lib.a *.o). > 3. Created a new project that links in -lopengl32 -lglu32 -lglut32 and > lib.a. (I put this in Further object files section of the project > options window). I believe that libraries for gcc are suposed to be named lib<name>.a ie libgl.a, libc.a, ... and then are linked by -l<name> -lgl -lc ... So you might want to try naming the file libsomething.a Changing this might be resolve the error. Evan > 4. Attempted to compile my application > > When Dev-C++ attempts to link in the library it gives me an "undefined > reference to `opengl function' error. > It's almost as if it doesn't know where to find the opengl functions > that I included. > > If I put the whole library source code into my project I can compile, > link, and run the project without a hitch. > > Any clues as to what I'm doing wrong? > > Thanks for you help. > Bobby __________________________________________________________________ Your favorite stores, helpful shopping tools and great gift ideas. Experience the convenience of buying online with Shop@Netscape! http://shopnow.netscape.com/ Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/ |