home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: SysTools / SysTools.zip / insthint.zip / bldrc.cmd < prev    next >
OS/2 REXX Batch file  |  1996-05-10  |  6KB  |  146 lines

  1. /*
  2. ***********************************************************************
  3. **                        SOFTWARE INSTALLER
  4. ** 5621-434 (C) COPYRIGHT IBM CORP. 1989, 1996. ALL RIGHTS RESERVED.
  5. **               LICENSED MATERIALS - PROPERTY OF IBM
  6. ***********************************************************************
  7. */
  8. /*
  9. ** DO NOT MAKE ANY CHANGES TO THIS FILE OTHER THAN TO CUSTOMIZE THE
  10. ** RC COMPILE STATEMENT FOR NATIONAL LANGUAGE VERSIONS!
  11. */
  12. '@echo off'
  13.  
  14. Prefix = 'EPFPREFIX:EPF'
  15.  
  16. /* Query the new prefix */
  17. if pos(':', Prefix) <> 0
  18. then do
  19.    /* Prefix found */
  20.    parse value Prefix with . ':' RenamedPrefix
  21. end   /* end then */
  22. else do
  23.    /* Prefix not found; use default */
  24.    RenamedPrefix = 'EPF'
  25. end   /* end else */
  26.  
  27.    intro.1  = "   --------------------------------------------------------"
  28.    intro.2  = "                                                           "
  29.    intro.3  = "   This command file builds the customized IIRC.RC file and"
  30.    intro.4  = "   binds it to the" RenamedPrefix"IDLDS.EXE executable.  In order to   "
  31.    intro.5  = "   successfully perform this build, the following files    "
  32.    intro.6  = "   must be present in the current directory:               "
  33.    intro.7  = "                                                           "
  34.    intro.8  = "            IIRC.RC             IIRCH.H                    "
  35.    intro.9  = "           " RenamedPrefix"IIIRS.RES       " RenamedPrefix"IDLDS.EXE               "
  36.    intro.10 = "            Any bitmap file that IIRC.RC references        "
  37.    intro.11 = "                                                           "
  38.    intro.12 = "   --------------------------------------------------------"
  39.    intro.13 = "   Press <Enter> to start the build.                       "
  40.  
  41.    compiling.1 = "--------------------------------------------------"
  42.    compiling.2 = "- Compiling your customized resource file. . .   -"
  43.    compiling.3 = "--------------------------------------------------"
  44.  
  45.    creating.1 = "--------------------------------------------------"
  46.    creating.2 = "- Creating the bindable resource file . . .      -"
  47.    creating.3 = "--------------------------------------------------"
  48.  
  49.    binding.1 =  "--------------------------------------------------"
  50.    binding.2 =  "- Binding resources to" RenamedPrefix"IDLDS.EXE . . .        -"
  51.    binding.3 =  "--------------------------------------------------"
  52.  
  53.    complete.1 = "--------------------------------------------------"
  54.    complete.2 = "- Build completed successfully.  You can now run -"
  55.    complete.3 = "-" RenamedPrefix"IDLDS.EXE to test your changes.             -"
  56.    complete.4 = "--------------------------------------------------"
  57.  
  58.    error.1 = "**************************************************"
  59.    error.2 = "* Error occurred.  The build was not successful. *"
  60.    error.3 = "* Eliminate the errors and rerun BLDRC.CMD.      *"
  61.    error.4 = "**************************************************"
  62.  
  63.    'cls'
  64.    say intro.1
  65.    say intro.2
  66.    say intro.3
  67.    say intro.4
  68.    say intro.5
  69.    say intro.6
  70.    say intro.7
  71.    say intro.8
  72.    say intro.9
  73.    say intro.10
  74.    say intro.11
  75.    say intro.12
  76.    say intro.13
  77.    pull .
  78.  
  79.  
  80.    /**************************************************************/
  81.    /* Compile IIRC.RC.                                           */
  82.    /**************************************************************/
  83.    /* If compiling translated national language versions of the  */
  84.    /* IIRC.RC file and you have a RC.EXE resource compiler which */
  85.    /* supports the -cc and -cp parameters, then you can modify   */
  86.    /* the 'rc -r iirc.rc iirc.res' line below which performs the */
  87.    /* compile so that your system will not need to be rebooted   */
  88.    /* with the country code and codepage for the language.       */
  89.    /* Example replacment lines for several languages are:        */
  90.    /*                                                            */
  91.    /* Japanese       : 'rc -cc 81 -cp 942 -r iirc.rc iirc.res'   */
  92.    /* Korean         : 'rc -cc 82 -cp 949 -r iirc.rc iirc.res'   */
  93.    /* Trad. Chinese  : 'rc -cc 88 -cp 948 -r iirc.rc iirc.res'   */
  94.    /**************************************************************/
  95.    'cls'
  96.    say " "
  97.    say compiling.1
  98.    say compiling.2
  99.    say compiling.3
  100.    'rc -r iirc.rc iirc.res'
  101.    if \(rc = 0) then signal error;
  102.  
  103.    /**************************************************************/
  104.    /* Concatenate the EPFIIIRS.RES file and the IIRC.RES file    */
  105.    /* together into ALL.RES.                                     */
  106.    /**************************************************************/
  107.    'cls'
  108.    say " "
  109.    say creating.1
  110.    say creating.2
  111.    say creating.3
  112.    'copy' RenamedPrefix'iiirs.res /B + iirc.res /B all.res'
  113.    if \(rc = 0) then signal error;
  114.  
  115.    /**************************************************************/
  116.    /* Bind ALL.RES to EPFIDLDS.EXE.                              */
  117.    /**************************************************************/
  118.    'cls'
  119.    say " "
  120.    say binding.1
  121.    say binding.2
  122.    say binding.3
  123.    'rc all.res' RenamedPrefix'idlds.exe'
  124.    if \(rc = 0) then signal error;
  125.  
  126.    say complete.1
  127.    say complete.2
  128.    say complete.3
  129.    say complete.4
  130.    call beep  1000,500
  131.    'erase all.res'
  132.  
  133.    say
  134.    say 'Check for any errors.'
  135.    'pause'
  136.  
  137.    exit 0
  138.  
  139. error:
  140.    say " "
  141.    say error.1
  142.    say error.2
  143.    say error.3
  144.    say error.4
  145.    exit rc
  146.