The programs in this directory are used as examples in chapter 2 The Basics
of "The omniORB2 User's Guide".

1. eg1                - collocated object implementation and client
2. eg2_clt, eg2_impl  - the object implementation and the client are in 
                        different address spaces. The client obtain the
                        stringified object reference from the command line.
3. eg3_clt, eg3_impl  - same as 2 except that the object reference is
                        passed via the COS Naming service.


To Compile
----------

+ On Unix

  - Make sure that the make configuration file ../../../mk/config.mk links to
    the appropriate config file for this platform. For example:
        $ cd ../../../mk
        $ ln -s sun4_sosV_5.5.mk config.mk

  - Do 'make all' in this directory. When make finishes, the binaries are
    compiled. 

+ On NT and Windows 95

  - Make sure that the make configuration file ..\..\..\build-win32\CONFIG.win32
    is setup for your environment. Consult ..\..\..\README.win32 for details.

  - Change directory to ..\..\..\build-win32 and do
        NMAKE /F "examples_mak.win32" CFG="echo"


To Run The Programs
-------------------

- On unix, since the shared libraries libomniORB2.so and libomnithread.so
  are not in the directories searched by the dynamic loader by default, you
  must add the library directory to the search path. 

  On Solaris 2.5
     $ LD_LIBRARY_PATH=<absolute pathname of ../../../lib>
     $ export LD_LIBRARY_PATH

- Similarly, ensure that the DLLs on NT are in a directory that is 
  searched by the system's DLL loader (see also ..\..\..\README.win32).

- Example 3 requires the presence of the COS Naming service. Make sure that
  the naming service is running before trying to run eg3_clt and eg3_impl.
  See ../../../README.{unix,win32} and Chapter 1 of 
  "The omniORB2 User's Guide" for details.

- The programs are expected to produce the following output:

> $ ./eg1
> I said,"Hello!". The Object said,"Hello!"

> $ ./eg2_impl
> 'IOR:000000000000000d49444c3a4563686f3a312e300077e450000000010000000000000028000100000000000d3139322e352e3233392e3134002095f30000000c3369f9a0a5a66bef00000001'

   Cut and paste the stringified IOR emitted by eg2_impl to be the command
   line argument to eg2_clt
> $ ./eg2_clt 'IOR:000000000000000d49444c3a4563686f3a312e300077e450000000010000000000000028000100000000000d3139322e352e3233392e3134002095f30000000c3369f9a0a5a66bef00000001'
> I said,"Hello!". The Object said,"Hello!"

  If the naming service is running:
> $ ./eg3_impl

> $ ./eg3_clt
> I said,"Hello!". The Object said,"Hello!"

