[omniORB] omniORB Environment
renny.koshy at rubixinfotech.com
renny.koshy at rubixinfotech.com
Mon Oct 1 12:47:47 BST 2007
One comment is the defines... such as -D_REENTRANT -D__OSVERSION__=2
-D__linux__ -D__x86__ are compiler/platform specific....
A good general rule (because we use omniORB on several diff OS/hardware)
is to comple the example and capture the output... that will show you
which defines you need....
Renny Koshy
President & CEO
--------------------------------------------
RUBIX Information Technologies, Inc.
www.rubixinfotech.com
BadKnees <a.olsen at flatrate.fo>
Sent by: omniorb-list-bounces at omniorb-support.com
10/01/2007 09:39 AM
To
omniorb-list at omniorb-support.com
cc
Subject
[omniORB] omniORB Environment
> Perhaps some kind soul would post a simple makefile they're using...
Just in case someone else is wondering about how to get a quick start:
Copy the bd_client.cc bd_server and the echo_callback.idl to your
workspace.
Lay it out like this:
./IDL/echo_callback.idl
./bd_server.cc
./bd_client.cc
And here's a simple Makefile:
PWD = $(shell pwd)
IDL = $(PWD)/IDL
STUB = $(PWD)/.stub
OBJ = $(PWD)/.obj
OMNIROOT = /usr/local/omniorb
IDLC = $(OMNIROOT)/bin/omniidl -bcxx
C++ = g++
CARGS = -c -O2 -Wall -Wno-unused -fexceptions -D__OMNIORB4__
-D_REENTRANT -D__OSVERSION__=2 -D__linux__ -D__x86__
LARGS = -O2 -Wall -Wno-unused -fexceptions
INC = -I$(OMNIROOT)/include/ -I. -I$(STUB)
LIB = -L$(OMNIROOT)/lib -L.
LDF = -lomniORB4 -lomniDynamic4 -lomnithread -lpthread
RM = rm -rf
all: bd_client bd_server
$(OBJ):
mkdir $(OBJ)
$(STUB):
mkdir $(STUB)
$(STUB)/echo_callbackSK.cc $(STUB)/echo_callback.hh: $(STUB)
$(IDL)/echo_callback.idl
cd $(STUB) && $(IDLC) $(IDL)/echo_callback.idl
$(OBJ)/echo_callbackSK.o: $(OBJ) $(STUB)/echo_callbackSK.cc
$(STUB)/echo_callback.hh
cd $(OBJ) && $(C++) $(CARGS) $(INC) -o $(OBJ)/echo_callbackSK.o
$(STUB)/echo_callbackSK.cc
$(OBJ)/bd_server.o: $(OBJ) $(STUB)/echo_callback.hh bd_server.cc
$(C++) $(CARGS) $(INC) -o $(OBJ)/bd_server.o bd_server.cc
$(OBJ)/bd_client.o: $(OBJ) $(STUB)/echo_callback.hh bd_client.cc
$(C++) $(CARGS) $(INC) -o $(OBJ)/bd_client.o bd_client.cc
bd_server: $(OBJ)/echo_callbackSK.o $(OBJ)/bd_server.o
$(C++) $(LARGS) $(LIB) $(LDF) -o bd_server $(OBJ)/bd_server.o
$(OBJ)/echo_callbackSK.o
bd_client: $(OBJ)/echo_callbackSK.o $(OBJ)/bd_client.o
$(C++) $(LARGS) $(LIB) $(LDF) -o bd_client $(OBJ)/bd_client.o
$(OBJ)/echo_callbackSK.o
clean:
$(RM) $(OBJ) $(STUB) bd_server bd_client
_______________________________________________
omniORB-list mailing list
omniORB-list at omniorb-support.com
http://www.omniorb-support.com/mailman/listinfo/omniorb-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20071001/61038fa1/attachment.htm
More information about the omniORB-list
mailing list