Compiling problems



I'm very new to ORBit and have just attmpted my first ORBit2
client/server program where the client just asks the server to add 2
numbers together. I've written a Makefile (added below) to compile the
code but get errors when doing a "make build" ("make skeleton" works
fine) saying undefined reference to TC_CORBA_double_struct. But I know
that the definition for TC_CORBA_double_struct is in
/usr/local/include/orbit-2.0/orbit/orb-core/corba-typecode.h and I have
definitely included this directory in my Makefile.

Where am I going wrong?? I would REALLY appreciate some help :-)

Katherine

--------------------------------------------------------------

PROJECT = calculator
CC = gcc
ORBIT_IDL = ../src/idl-compiler/orbit-idl-2
ORBIT_CFLAGS = \
-I/usr/local/lib/glib-2.0/include \
-I/usr/local/include/glib-2.0 \
-I/usr/local/include/libIDL-2.0 \
-I/usr/local/include/linc-1.0 \
-I/usr/local/include/orbit-2.0 \
-I/usr/local/include/orbit-2.0/orbit/orb-core \
-I/usr/local/lib/glib-2.0/include \
-I../include \
-I. \
-I..
ORBIT_LIBS = -L/usr/local/lib -lIDL-2 -lgobject-2.0 -lgmodule-2.0 -lIIOP
-lORBitutil -ldl -lglib-2.0 -lm -llinc -lgthread-2.0 -lpthread
CFLAGS = $(ORBIT_CFLAGS)
LFLAGS = $(ORBIT_LIBS)

skeleton : idltargets

build : $(PROJECT)-client $(PROJECT)-server

$(PROJECT)-client : $(PROJECT)-client.o $(PROJECT)-common.o
$(PROJECT)-stubs.o
 $(CC) -o $(PROJECT)-client $(CFLAGS) $(PROJECT)-client.o
$(PROJECT)-stubs.o $(PROJECT)-common.o -lIIOP -lORBit -lORBitutil
$(LFLAGS)

$(PROJECT)-server : $(PROJECT)-server.o $(PROJECT)-skels.o
$(PROJECT)-common.o
 $(CC) -o $(PROJECT)-server $(CFLAGS) $(PROJECT)-server.o
$(PROJECT)-skels.o $(PROJECT)-common.o -lIIOP -lORBit -lORBitutil
$(LFLAGS)

idltargets : $(PROJECT).idl
 $(ORBIT_IDL) --skeleton-impl $(PROJECT).idl

#individual rules

$(PROJECT)-stubs.c : $(PROJECT).idl
 $(ORBIT_IDL) $(PROJECT).idl

$(PROJECT)-common.c : $(PROJECT).idl
 $(ORBIT_IDL) $(PROJECT).idl

$(PROJECT)-skels.c : $(PROJECT).idl
 $(ORBIT_IDL) $(PROJECT).idl

$(PROJECT)-client.c : $(PROJECT).h

$(PROJECT)-server.c : $(PROJECT).h

$(PROJECT).h : $(PROJECT).idl
 $(ORBIT_IDL) $(PROJECT).idl





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]