\documentclass[10pt]{article}
\usepackage{verbatim}

\title{ autoconf package for CORBA support }
\author{ Ruslan Shevchenko \\ $<Ruslan@Shevchenko.Kiev.UA>$ }

% $Id: CORBA-autoconf.tex,v 1.3 2000/08/03 18:34:38 rssh Exp $

\begin{document}

\maketitle{}


\section{ Introduction }

 This is autoconf package for CORBA support.

\section{ autoconf macroses }

\begin{itemize}
 \item \verb|RSSH_CHECK_ORB| - check supported CORBA ORB and define appropriative substitution macroses and preprocessor symbols.
 \item \verb|RSSH_CHECK_ORBACUS| - check for ORBacus
 \item \verb|RSSH_CHECK_TAO| - check for TAO
 \item \verb|RSSH_CHECK_OMNIORB| - check for omniORB
\end{itemize}

\section{ Makefile.in variables }

\begin{itemize}



  \item{ORB} Define the name of ORB.
    Possible names for now are:
    \begin{enumerate}
      \item TAO
      \item OmniORB
      \item ORBacus
    \end{enumerate}



  \item IDL (deprecated), IDLCXX
      Define the name of IDL compiler. IDLCXX compiler is used to produce
    C++ stubs and skeletons.
    It's defined as:
    \begin{enumerate}
      \item TAO      \verb|$ACE_ROOT/tao/TAO_IDL/taoidl|
      \item OmniORB3  \verb|omniidl -bcxx -I$(OMNI_ROOT)/idl|
      \item ORBacus  \verb|idl -I$(OB_PREFIX)/idl -I$(OB_PREFIX)/idl/OB|
    \end{enumerate}
  \item 

   when idl compiler process input file, it's produce
 few output files:
   \begin{itemize}
    \item  client stub headers,
    \item  some orb generate additiona helper file for stub headers, 
    \item  C++ sources for client stub,
    \item  server skeleton headers
    \item  some ORB generate additional server skeleton headers
    \item  C++ sources for client skeleton
   \end{itemize}

 So, the next set of autoconf macroses are defined:

   \item \verb|IDL_CLN_H_SUFFIX| - suffix for generated client stub headers. (i. e
    for X.idl client stub header file is \verb*X|IDL_CLN_H_SUFFIX*, where 
    \verb+|+ -- concatenation symbol. 
   \item \verb|IDL_CLN_H1_SUFFIX| -- suffix for additional generated client stub headers, or { \em no}, if one not exists.
   \item \verb|IDL_CLN_CPP_SUFFIX| -- suffix for client stub C++ sources.
   \item \verb|IDL_CLN_OBJ_SUFFIX| -- suffix for client stub object file.
   \item \verb|IDL_SRV_H_SUFFIX| -- suffix for server skeleton header
   \item \verb|IDL_SRV_H1_SUFFIX| -- suffix for additional server skeleton header, or {\em no} if one not exists
   \item \verb|IDL_SRV_CPP_SUFFIX| -- suffix for server skeleton C++ sources.
   \item \verb|IDL_SRV_OBJ_SUFFIX| -- suffix for server skeleton object file


  \item \verb|IDL_LIBDIR| -- linker options for setting directory of ORB libraries ( something like \verb|-L/opt/ACE/TAO/lib| )
  \item \verb|ORB_LIBS|  -- linker options for ORB libraries. 
  \item \verb|ORB_COSNAMING_LIB| - library for CORBA Naming Service.
  (General rule: for standart CORBA service XX, if ORB implement this service, than \verb|ORB_XX_LIB| is defined.
\end{itemize}

\section{ Preprocessor variables }

\begin{enumerate}
 \item \verb|CORBA_MODULE_NAMESPACE_MAPPING| defined, when IDL modules are mapped to C++ namespaces.
 \item \verb|CORBA_MODULE_CLASS_MAPPING| defined, when IDL modules are mapped to C++ classes.
 \item \verb|CORBA_MODULE_C_MAPPING| defined, when IDL modules are mapped to identifiers as in C case.
 \item \verb|CORBA_HAVE_POA| defined, when ORB is POA based.
 \item \verb|CORBA_HAVE_POA| defined, when ORB is POA based.
 \item \verb|CORBA_ORB_INIT_HAVE_3_ARGS| defined, when \verb|CORBA::ORB_init| accept
 3 arguments.
 \item \verb|CORBA_ORB_INIT_THIRD_ARG| -- third argument of \verb|CORBA::ORB_init|
 The common usage of last 2 macro variables shown in next code snipshet:
\begin{verbatim}
#ifdef CORBA_ORB_INIT_HAVE_3_ARGS
  CORBA::ORB_var orb = CORBA::ORB_init(argc,argv,CORBA_ORB_INIT_THIRD_ARG);
#else
  CORBA_ORB_var orb = CORBA::ORB_init(argc,argv);
#endif
\end{verbatim}
 \item \verb|CORBA_SYSTEM_EXCEPTION_IS_STREAMBLE| defined, when operator:
\begin{verbatim}
ostream& operator<<(ostream&, const CORBA::SystemException&)
\end{verbatim}
 is defined by ORB.
 \item \verb|CORBA_H| -- header file for CORBA definitions. common usage:
\begin{verbatim}
#include CORBA_H
\end{verbatim}

 \item \verb|COSNAMING_H| -- header file with definitions of CORBA CosNaming service.


 \item \verb|IDL_CLN_H_SUFFIX| -- suffix of generated client stubs header.
 \item \verb|IDL_SRV_H_SUFFIX| -- suffix of generated skeleton header.

The tupical usage of this symbols are next:

\begin{verbatim}
#ifndef __CAT2_FF
#define __CAT2_FF(x,y) <##x##y##>
#endif

#ifndef __CAT2_F
#define __CAT2_F(x,y) __CAT2_FF(x,y)
#endif

#define CORBA_STUB_HEADER(x)  __CAT2_F(x,IDL_CLN_H_SUFFIX)
#define CORBA_SKELETON_HEADER(x)  __CAT2_F(x,IDL_SRV_H_SUFFIX)

\end{verbatim}

from now we can write:
\begin{verbatim}
#include CORBA_STUB_HEADER(X)
\end{verbatim}
 for inclusion of corba client stub header in C++ code.

\end{enumerate}

\end{document}
