home *** CD-ROM | disk | FTP | other *** search
/ IRIX 6.2 Applications 1996 August / Silicon_Graphics_812-0542-002.iso / relnotes / goldengate / ch4.z / ch4
Text File  |  1996-08-03  |  2KB  |  67 lines

  1.  
  2.  
  3.  
  4.                                   - 1 -
  5.  
  6.  
  7.  
  8.        4.  _S_a_m_p_l_e__C_o_d_e
  9.  
  10.  
  11.        This release includes some sample programs to help get you
  12.        started with the Data Conversion Service API.  After
  13.        installing goldengate.sw.demo, in /usr/share/src/GoldenGate
  14.        you will find several subdirectories.  Each subdirectory is
  15.        self-contained and includes one or more C or C++ source
  16.        files, a Makefile and any other files needed by the
  17.        particular example.
  18.  
  19.        To help you get started writing converters, sample converter
  20.        code is included as well as several short demo applications.
  21.  
  22.        The converter sample directory includes a file with the
  23.        extension ".cdf".  This is a Converter Definition File.  You
  24.        will see entries with the same syntax in the system
  25.        converter registry file /etc/ConverterRegistry.  The
  26.        registry is the means by which the service can locate your
  27.        converters.
  28.  
  29.        The converters named in the default registry file all live
  30.        in the DSO /usr/lib/convert/libcvt_SGI.so.  When you run the
  31.        make file that comes with the sample converter named
  32.        "CvtToLower" you will generate another DSO named (by
  33.        default) libUserCvtrs.so.  If you rename this DSO, you must
  34.        remember to change the CDF to reference the new name so that
  35.        GoldenGate can find your converters.
  36.  
  37.        To test your own converters without disrupting the system
  38.        registry, you can set the environment variable
  39.        CVT_REGISTRY_OVERRIDE to the full pathname of your converter
  40.        definition file.  For instance you can say:
  41.  
  42.        cd MyTestConverterDir
  43.  
  44.        setenv CVT_REGISTRY_OVERRIDE `pwd`/CvtToLower.cdf
  45.  
  46.        Your program will temporarily use the definition file for
  47.        your sample converter instead of the system registry.  You
  48.        should only set this technique while testing your
  49.        converters.  Once a converter is finished, it should be
  50.        installed.  To install, copy your DSO to /usr/lib/convert or
  51.        another directory where you want to keep converter DSOs.  In
  52.        your CDF, you can include a full pathname in the DSO
  53.        specification, or just type the filename and the system will
  54.        look in /usr/lib/convert for the library.  You must then add
  55.        your CDF to the system registry to make it visible to the
  56.        conversion service.
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.