Readme file created by Steve Cerniglia concerning the examples in the FrontOffice1 and FrontOffice2 directories. Some of the instructions here also apply to the example in the matrix directory. 1. Introduction The FrontOffice example is found int Chapter 2 of "CORBA Distributed Objects: Using Orbix" by Sean Baker. This file contains brief documentation on how I used AT&T's (formally OSL's) OmniORB to compile and execute this example. The first thing to take note is that I compiled and ran this example under Microsoft Windows 98 using Microsoft's Visual C++ 6.0. 2. Compiling the IDL The idl file, front.idl, is taken directly from page 24 of the textbook. The OmniORB idl compiler is called omniidl2. To compile front.idl, I did the following: > omniidl2 -h .hh -s .cpp front.idl The -h option takes a value which is used to specify the extension of the generated header file(s). The -s option takes a value that is used to specify the extension of the generated stub file(s). This command generated the following files: o front.h o frontSkel.cpp Unfortunately, I couldn't find any documentation on if/how I could generate server and client stubs. So, I created them from scratch. I named them server.cpp and client.cpp respectively. 3. The Server Created the following files o front_impl.cpp o server.cpp front_impl.cpp which implements the class that is declared in front.h. server.cpp is this examples server code. To compile the server, I had to make the the following additions to the standard MS VC++ environment. 1) Add the following to the include path: c:\OmniORB_2.7.0\include 2) Add the following libraries to be linked with: omniORB270_rt.lib omnithread2_rt.lib wsock32.lib advapi32.lib 3) Add the following to the -libpath option for the linker: c:\OmniORB_2.7.0\lib\x86_win32 To make the server: > make server Please refer to the Makefile for all the building details. 4. The Client Created the following files: o client.cpp Client.cpp implements the client code for this example. To make the client: > make client 5. The Makefile I added the above noted environment changes to a hand-built make file so that I could build the project from the command line. This makefile works with Microsoft's nmake and _should_ work with GNU's make for win32 as well (although I have not tested this yet). 6. Windows Settings I had to make the following entry into the Windows Registry at: My Computer\HKEY_LOCAL_MACHINE\Software\ORL\omniORB\2.0 The entry is called NAMESERVICE and has a value of the IOR string returned by calling omniNames.exe for the first time. > omninames -start 12345 where 12345 is the port # that you want the omninames server to be listening on. 7. Registering the server 8. Running the Example There are two examples. The first, simpler example does not use the name server. Instead, when the server starts up, it outputs the unique IOR number for it. When the client starts you need to pass this number to it, so it can find the server. Unfortunately, the DOS command buffer is smaller than the size of the IOR string so I've had to create a batch file for the client to store the IOR string. Please update the IOR number in the batch file, whenever you restart the server. The second example uses the omniname server. For this example to run, you have to use 3 dos boxes, 1 for the omniname server, 1 for the example server and then one for a client. In both examples you can rerun the client as many times as you wish.