hello Stefan,

I also use eclipse and i managed to make it work.
All that you have to do is create a project with a standard Makfile instead
of the managed one.
Then use the make file as specified by Carsten and then i hope it will
compile and work.

I am attaching a sample of mine for reference.To make the sample one working
you have to create a
.depend file in the same directory.


Regards
Sajjad

*************************************Makefile*****************************************************


#File : MakeFile
#A very general MakeFile that will
#compile the OpenSG programs


#"opt" if you used the optimized library
#otherwise it is "dbg"
LIBTYPE ?= opt

#set the path to  the installed osg-config
#executable here
OSGCONFIG := /usr/local/bin/osg-config

#use the osg-config to set the options
#to compile and link the program
CC = $(shell $(OSGCONFIG) --compiler)
CCFLAGS = $(shell $(OSGCONFIG) --cflags --$(LIBTYPE) Base System GLUT )
LDFLAGS = $(shell $(OSGCONFIG) --libs --$(LIBTYPE) Base System GLUT )

#DEBUG = -c -03

#all  the sources in the directory
SOURCES = planet.cpp

GOVIEWOBJS = $(SOURCES:.cpp=.o)


#use the following one to earse  the files
RM = rm -rf

#program executable file name
PROGS = planet

#top level rule to compille everything
all: $(PROGS)

#rule to compile the recompilable files
clean:
    $(RM) $(PROGS) $(GOVIEWOBJS)

superclean:
    $(RM) $(PROGS) $(GOVIEWOBJS)

#rule to  link  the program
$(PROGS): $(GOVIEWOBJS)
    $(CC) -o $@ $(GOVIEWOBJS) $(LDFLAGS)

#meta rules to compile any cpp souurce files
#here "%" character is a wildcard that  matches any part of the filename
#the rule here means that "A file with a '.o' suffix is dependant on a file
with the same but with a '.c' suffix"

%.o: %.cpp
    $(CC) $(CCFLAGS) -c $<

#rule for building the dependency list and writing them to  a file
#named ".depend"
.depend:
    $(RM) .depend
    makedepend -f -- $(CCFLAGS) --$(SOURCES) > .depend

#now add a line to include the dependency list
include .depend
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to