Hi, I'm having issues compiling a program and keep having trouble with
the linking.  I suspect it has something to do with the inheritance of
a new window class derived from GlWindow in FLTK 2.0.  I keep getting
the following errors...Source code included below.  I'm running OS
10.4.11 PPCand using gcc 4.0.1.   Thanks for any help!

Peace
Gary
--
[EMAIL PROTECTED]
<http://www.babelgraph.org/>



g++ -L/usr/local/lib/libfltk2.a -L/usr/local/lib/libfltk2_gl.a
-L/System/Library/Frameworks/OpenGL.framework/Libraries
-L/usr/local/lib /usr/local/lib/libfltk2_gl.a -framework AGL
-framework OpenGL /usr/local/lib/libfltk2.a -lpthread -framework
Carbon -framework ApplicationServices -o "BabelGraph-0.2"  ./Graph.o
./GraphEngine.o ./edge.o ./main.o ./node.o
/usr/libexec/gcc/powerpc-apple-darwin8/4.0.1/ld: Undefined symbols:
fltk::GlWindow::init()
vtable for GraphEngine
vtable for fltk::GlWindow
collect2: ld returned 1 exit status


The source code for the new class is in GraphEngine.hpp:

#include <fltk/gl.h>
#include <fltk/GlWindow.h>
#include <fltk/Window.h>
#include "Graph.hpp"

class GraphEngine : public fltk::GlWindow
{

public :
    // CONSTRUCTOR
    GraphEngine(int X,int Y,int W,int H,const char*L);
    
    ~GraphEngine();
    void newGraph (int size);

    
private:
        void draw();
        void resize(int X,int Y,int W,int H);
        Graph *g;

 
};

And from the .cpp file:

#include "GraphEngine.hpp"

// CONSTRUCTOR
GraphEngine::GraphEngine(int X,int Y,int W,int H,const char*L=0) :
fltk::GlWindow(X,Y,W,H,L){}


-- 

I'm trying a new usenet client for Mac, Nemo OS X.
You can download it at http://www.malcom-mac.com/nemo

_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to