Building OCC under Linux

I have just received a message from the webmaster that details the build of OCC for Linux/UNIX. It appears that the GNU Autotools build is NOT the way to go here. Use the traditional *.COMP scripts. Too bad... I include the message below for those interested. Hope it helps.


How to rebuild modules on Unix and Linux.

On Unix and Linux each module can be rebuilt with a file named command.

Attention: In order to adapt compilation procedures to your system configuration edit the $CASROOT/adm//init file

Example of rebuilding:
cd $CASROOT/adm/Linux
csh -f FoundationClasses.COMP

In the directory $CASROOT/adm/Linux (resp SunOS), you will find all the scripts which allow you to completely recompile the modules:

A .COMP file builds the module completely . This is done by calling .comp files corresponding to each toolkit of the module in a respective order. (Example: Refer to $CASROOT/ModelingData.COMP) A .comp file completely builds each unit. This is done by calling compilations of each package of the toolkit (the .comp file) and by creating a shareable for the toolkit ( the toolkit.lnk file) The .comp file completely compiles each package. For each source file, it creates an object file $CASROOT/Linux/obj/.o (resp SunOS) and on Linux platform a $CASROOT/Linux/obj/.d file containing the dependencies of the includes. Note: On SunOS platform, this file is not created. You can create it using the -H option of the compiler. In that case dependencies are sent to stderr together with the error messages.

William Jones's picture

BTW: The order is presented in $CASROOT/adm/build.htm as

`csh -f FoundationClasses.COMP`
`csh -f ModelingData.COMP`
`csh -f ModelingAlgorithms.COMP`
`csh -f Visualization.COMP`
`csh -f Draw.COMP`
`csh -f DataExchange.COMP`
`csh -f STLVRMLConvertor.COMP`
`csh -f Viewer.COMP`
`csh -f DrawDE.COMP`
`csh -f ApplicationFramework.COMP`
`csh -f DrawAF.COMP`
`csh -f DECAF.COMP`
`csh -f WOK.COMP` (if desired)

Or you can just use

`csh -f OCC.COMP`

to build all modules.

The $CASROOT/adm/build.htm has some other useful information as well. It would be nice if this were available on or .com if not already.

William Jones's picture

Using `csh -f adm/Linux/OCC.COMP` does indeed work under RedHat 7.3