home *** CD-ROM | disk | FTP | other *** search
- @echo off
-
- rem
- rem 10H9767, 10H9769 (C) COPYRIGHT International Business Machines Corp. 1992,1994,1995
- rem
- rem All Rights Reserved
- rem Licensed Materials - Property of IBM
- rem US Government Users Restricted Rights - Use, duplication or
- rem disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- @REM %Z% %I% %W% %G% %U% [%H% %T%]
-
- rem Command script to convert to implict stars (like CORBA) for
- rem interface references.
- rem
- rem SETLOCAL
- IF "%SOMBASE%"=="" GOTO sombase
- IF "%SC%"=="" GOTO somsc
-
- REM IF "%SOMDRIVE%"=="" GOTO body
- REM %SOMDRIVE%
-
- :body
-
- REM IF SMBINDINGS is already set, use it as the destination directory.
- if "%SMBINDINGS%"=="" goto else1
- set SOMDEST=%SMBINDINGS%
- goto endif1
- :else1
- set SOMDEST=%SOMBASE%\include
- :endif1
-
- REM On Windows 95, we can't use exist to test a directory
- REM That's why we need this work-around.
- echo Looking for destination directory %SOMDEST%
- md %SOMDEST%
- echo test > %SOMDEST%\somtmp.tmp
- if not exist %SOMDEST%\somtmp.tmp goto nodest
- del %SOMDEST%\somtmp.tmp
-
-
- IF NOT EXIST %SOMBASE%\include\som.hc GOTO drive
- IF NOT EXIST %SOMBASE%\include\somcorba.gen goto normal
-
- echo.
- echo You chose to have the C bindings generated in the SOMobjects
- echo package you last installed. This process will take
- echo between 5-30 minutes to complete depending on your system
- echo and install options. Please be patient.
- rem - this process will not
- rem echo be run again unless you install some new SOM components.
- rem echo.
-
- :normal
- echo Generating the CORBA C Bindings:
- IF EXIST %SOMDEST%\somstars.bld DEL %SOMDEST%\somstars.bld
- rem CD %SOMBASE%\include
- if exist %SOMDEST%\som.h ATTRIB -R %SOMDEST%\som.h
- if exist %SOMDEST%\gen_c.efw ATTRIB -R %SOMDEST%\gen_c.efw
- COPY %SOMBASE%\include\som.hc %SOMDEST%\som.h > NUL
- COPY %SOMBASE%\include\gen_c.efc %SOMDEST%\gen_c.efw > NUL
- SET SMADDSTAR=
- %SC% -%% -mnoaddstar -D_WIN32 -sh -d %SOMDEST% %SOMBASE%\include\*.idl
- IF NOT ERRORLEVEL 0 GOTO end
- IF EXIST %SOMBASE%\include\somdtype.idl %SC% -mnoaddstar -D_WIN32 -sh -DEMIT_SOMDTYPES -d %SOMDEST% %SOMBASE%\include\somdtype.idl
- IF EXIST %SOMDEST%\somcorba.gen DEL %SOMDEST%\somcorba.gen
- echo somcorba.bld > %SOMDEST%\somcorba.bld
- GOTO end
-
- :sombase
- ECHO SOMBASE should be set before running somcorba.
- GOTO end
-
- :somsc
- ECHO SC should be set before running somcorba.
- GOTO end
-
- :drive
- rem ECHO SOM is not installed on the current drive, please set SOMDRIVE.
- echo Can't find *.idl files. Please check SOMBASE.
- goto end
-
- :nodest
- echo Can't create/find destination directory %SOMDEST%
-
- :end
- rem ENDLOCAL
-