Building Your Application


Compiler Flags and Preprocessor Directives

This section provides details about compiler flags and preprocessor directives used for successfully building an ACIS-based application on supported platforms. Also listed are the linker flags and system libraries used when linking the ACIS shared libraries.

To see examples of how Scheme AIDE is linked against the ACIS libraries, refer to the make files and projects provided in scm/acis3dt. If you are rebuilding the Scheme AIDE source code, refer to the required defines listed near the end of each table for recompiling the Scheme AIDE toolkit code and extensions.

Windows 32-bit/Visual Studio C++ 6.0 SP5

ACIS ARCH names for Windows platform, Microsoft Visual Studio C++ 6.0 SP5 Compiler (32-bit)

NT_DLL

32-bit release ACIS libraries

NT_DLLD

32-bit debug ACIS libraries

Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8804 for 80x86

Description

NT_DLL

NT_DLLD

Compiler Flags

/MD

Link with MSVCRT.dll

X

/MDd

Link with MSVCRTD.dll debug lib

X

Preprocessor Directives

_DEBUG

Debug build

X

_WINDOWS

MS specific

X

X

ANSI

Enable ANSI prototyping

X

X

NDEBUG

Release build

X

 

NT

Define the base architecture

X

X

NT_DLL

Define this to force link ACIS release libraries. By default, at least one Windows arch directive must be provided.

X

NT_DLLD

Define this to force link ACIS debug libraries. By default, at least one Windows arch directive must be provided.

X

SPA_NO_AUTO_LINK

Define this to disable force linking of ACIS libraries. If this is defined, neither NT_DLL nor NT_DLLD needs to be defined.

X

X

Linker Options

link /LIB /NODEFAULTLIB /DEF: /MACHINE:IX86
link /DLL /FORCE:MULTIPLE /MACHINE:IX86 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oeaut32.lib uuid.lib

X

X

Windows 32-bit/Visual Studio C++ .NET 2003

ACIS ARCH names for Windows platform, Microsoft Visual Studio C++ .NET 2003 Compiler (32-bit)

NT_NET_DLL

32-bit release ACIS libraries

NT_NET_DLLD

32-bit debug ACIS libraries

Microsoft (R) C/C++ Optimizing Compiler Version 13.10.4233 for 80x86

Description

NT_NET_DLL

NT_NET_DLLD

Compiler Flags

/MD

Link with MSVCRT.dll

X

/MDd

Link with MSVCRTD.dll debug lib

X

Preprocessor Directives

_DEBUG

Debug build

X

_WINDOWS

MS specific

X

X

ANSI

Enable ANSI prototyping

X

X

NDEBUG

Release build

X

 

NT

Define the base architecture

X

X

NT_NET_DLL

Define this to force link ACIS release libraries. By default, at least one Windows arch directive must be provided.

X

NT_NET_DLLD

Define this to force link ACIS debug libraries. By default, at least one Windows arch directive must be provided.

X

SPA_NO_AUTO_LINK

Define this to disable force linking of ACIS libraries. If this is defined, neither NT_NET_DLL nor NT_NET_DLLD needs to be defined.

X

X

Linker Options

link /LIB /NODEFAULTLIB /DEF: /MACHINE:IX86
link /DLL /FORCE:MULTIPLE /MACHINE:IX86 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oeaut32.lib uuid.lib

X

X

Windows 32-bit/Visual C++ 2005

ACIS ARCH names for Windows platform, Microsoft Visual Studio C++ 2005 Compiler (32-bit)

NT_VC8_DLL

32-bit release ACIS libraries

NT_VC8_DLLD

32-bit debug ACIS libraries

Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 14.00.50727.42 for 80x86

Description

NT_VC8_DLL

NT_VC8_DLLD

Compiler Flags

/EHa

Enable asynchronous C++ exception handling

X

X

/MD

Link with MSVCRT.dll

X

/MDd

Link with MSVCRTD.dll debug lib

X

Preprocessor Directives

_DEBUG

Debug build

X

_WINDOWS

MS specific

X

X

ANSI

Enable ANSI prototyping

X

X

NDEBUG

Release build

X

 

NT

Define the base architecture

X

X

NT_VC8_DLL

Define this to force link ACIS release libraries. By default, at least one Windows arch directive must be provided.

X

NT_VC8_DLLD

Define this to force link ACIS debug libraries. By default, at least one Windows arch directive must be provided.

X

SPA_NO_AUTO_LINK

Define this to disable force linking of ACIS libraries. If this is defined, neither NT_VC8_DLL nor NT_VC8_DLLD needs to be defined.

X

X

Linker Options

link /LIB /NODEFAULTLIB /DEF: /MACHINE:IX86
link /DLL /FORCE:MULTIPLE /MACHINE:IX86 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oeaut32.lib uuid.lib

X

X

Special Notes

Each sample has _vc8.* appended to its name when installed, for example, <sample_name>_vc8.vcproj.
Manifest files are embedded only in the DLL files for VC8; they are not embedded in the VC8 executables.
The portion of your application that links against ACIS must be built with the compilation flag /EHa. This is new with VS2005. VS2005 has a more strict implementation of try/catch. Formerly, if you built /EHs with VC6 or VC7(.1), try/catch blocks would catch asynchronous exceptions and would invoke the ACIS-structured exception handler (assuming the asynchronous exception happened in an ACIS API block or EXCEPTION block). With VS2005, however, asynchronous exceptions are not caught in an /EHs built try/catch block.
 

Windows 64-bit/Visual C++ 2005

ACIS ARCH names for Windows platform, Microsoft Visual Studio C++ 2005 Compiler for x64 (64-bit)

NT_AMD_64_DLL

64-bit release ACIS libraries

NT_AMD_64_DLLD

64-bit debug ACIS libraries

Microsoft (R) C/C++ Optimizing Compiler Version 14.00.50727.42 for x64

Description

NT_AMD_64_DLL

NT_AMD_64_DLLD

Compiler Flags

/EHa

Enable asynchronous C++ exception handling

X

X

/MD

Link with MSVCRT.dll

X

/MDd

Link with MSVCRTD.dll debug lib

X

Preprocessor Directives

_DEBUG

Debug build

X

_M_AMD_64

MS specific

X

X

_WINDOWS

MS specific

X

X

ACIS64

64-bit architecture

X

X

ANSI

Enable ANSI prototyping

X

X

NDEBUG

Release build

X

 

NT

Define the base architecture

X

X

NT_AMD_64

Define AMD specific architecture

X

X

NT_AMD_64_DLL

Define this to force link ACIS release libraries. By default, at least one Windows arch directive must be provided.

X

NT_AMD_64_DLLD

Define this to force link ACIS debug libraries. By default, at least one Windows arch directive must be provided.

X

SPA_NO_AUTO_LINK

Define this to disable force linking of ACIS libraries. If this is defined, neither NT_DLL nor NT_DLLD needs to be defined.

X

X

Linker Options

link /LIB /NODEFAULTLIB /DEF: /MACHINE:AMD64
link /DLL /FORCE:MULTIPLE /MACHINE:AMD64 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oeaut32.lib uuid.lib

X

X

Special Notes

Each sample has _vc8.* appended to its name when installed, for example, <sample_name>_vc8.vcproj.
VC8 Debug libraries are not supported on the 3D InterOp ACIS CATIA V5 JT Reader or Writer.
Manifest files are embedded only in the DLL files for VC8; they are not embedded in the VC8 executables.
The portion of your application that links against ACIS must be built with the compilation flag /EHa. This is new with VS2005. VS2005 has a more strict implementation of try/catch. Formerly, if you built /EHs with VC6 or VC7(.1), try/catch blocks would catch asynchronous exceptions and would invoke the ACIS-structured exception handler (assuming the asynchronous exception happened in an ACIS API block or EXCEPTION block). With VS2005, however, asynchronous exceptions are not caught in an /EHs built try/catch block.
 

IBM 32-bit and 64-bit/VisualAge C++ 6.0

ACIS ARCH names for AIX platform, VisualAge C++ Professional 6.0 Compiler (32-bit, 64-bit)

aix4_so

32-bit release ACIS libraries

aix4_so_debug

32-bit debug ACIS libraries

aix4_64_so

64-bit release ACIS libraries

aix4_64_so_debug

64-bit debug ACIS libraries

IBM VisualAge C++ Professional for AIX, Version 6.0

Description

aix4_so

aix4_so_debug

aix4_64_so

aix4_64_so_debug

Compiler Flags

/q64

Choose 64 bit compiler

X

X

Preprocessor Directives

_ALL_SOURCE

O/S Specific

X

X

X

X

_DEBUG

Debug build

X

X

_POSIX_SOURCE

Defined when linking with thread safe system libraries

X

X

X

X

ACIS64

64-bit architecture

X

X

aix

Define the base architecture

X

X

X

X

ANSI

Enable ANSI prototyping

X

X

X

X

Linker Options

makeC++SharedLib -brtl -G -bernotok -bnolibpath -bnoipath -p10 -lc -lm -lpthread
(-brtl allows .so and .a libraries to be mixed when building shared libraries)

X

X

makeC++SharedLib -X64 -brtl -G -bernotok -bnolibpath -bnoipath -p10 -lc -lm -lpthread

X

X

Preprocess Directives Needed for Building SCM

MOTIF

Motif support

X

X

X

X

HP 32-bit and 64-bit/HP aCC Version A.03.52

ACIS ARCH names for HP-UX 11 platform, HP aCC Version A.03.52 Compiler (32-bit, 64-bit)

hp700_11_so

32-bit release ACIS libraries

hp700_11_so_debug

32-bit debug ACIS libraries

hp700_11_64_so

64-bit release ACIS libraries

hp700_11_64_so_debug

64-bit debug ACIS libraries

aCC : HP ANSI C++ B3910B A.03.52

Description

hp700_11_so

hp700_11_so_debug

hp700_11_64_so

hp700_11_64_so_debug

Compiler Flags

-Aa

Use Koenig lookup and strict ANSI for scope rules

X

X

X

X

+DA2.0W

Generate 64 bit code

X

X

+Z

Generate position independent code

X

X

X

X

-mt

Compile and link for multithreaded code

X

X

X

X

Preprocessor Directives

_DEBUG

Debug build

X

X

ACIS64

64-bit architecture

X

X

ANSI

Enable ANSI prototyping

X

X

X

X

hp700

Define the base architecture

X

X

X

X

X_WINDOWS(rnd_husk only)

X-Windows support

X

X

X

X

Linker Options

aCC -b -Wl,+s

X

X

aCC -b

X

X

Preprocess Directives Needed for Building SCM

MOTIF

Motif support

X

X

X

X

Linux 32-bit/GNU C++ gcc 3.2.3

ACIS ARCH names for Linux platform, GNU C++ gcc 3.2.3 Compiler (32-bit)

linux_so

32-bit release ACIS libraries

linux_so_debug

32-bit debug ACIS libraries

gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-20)

Description

linux_so

linux_so_debug

Compiler Flags

-fpic

Generate position independent code

X

X

Preprocessor Directives

_DEBUG

Debug build

X

ANSI

Enable ANSI prototyping

X

X

linux

Define the base architecture

X

X

X_WINDOWS(rnd_husk only)

X-Windows support

X

X

Linker Options

g++ -shared

X

X

Linux 64-bit/GNU C++ gcc 3.2.3

ACIS ARCH names for Linux platform for AMD64, GNU C++ gcc 3.2.3 Compiler (64-bit)

linux_amd_64_so

64-bit release ACIS libraries

linux_amd_64_so_debug

64-bit debug ACIS libraries

gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-20)

Description

linux_amd_64_so

linux_amd_64_so_debug

Compiler Flags

-fpic

Generate position independent code

X

X

-m64

Generate 64 bit code

X

X

Preprocessor Directives

_DEBUG

Debug build

X

ACIS64

64-bit architecture

X

X

ANSI

Enable ANSI prototyping

X

X

linux

Define the base architecture

X

X

X_WINDOWS(rnd_husk only)

X-Windows support

X

X

Linker Options

g++ -shared

X

X

Macintosh 32-bit/GNU C++ gcc 4.0.1 and XCode 2.3

ACIS ARCH names for Macintosh platform, gcc 4.0.1 (included with XCode 2.3) Compiler (32-bit)

macub

32-bit BSD release ACIS libraries

macub_debug

32-bit BSD debug ACIS libraries

gcc version 4.0.1 (Apple Computer, Inc. build 5026)

Description

macub

macub_debug

Compiler Flags

No mandatory flags

 

 

 

Preprocessor Directives

_DEBUG

Debug build

X

ANSI

Enable ANSI prototyping

X

X

mac

Define the base architecture

X

X

MacX

Define the base architecture

X

X

Linker Options

g++ -dynamiclib -Wl,-single_module -Wl, -noprebind -Wl,-install_name,@executable_path/libXXX.dylib

X

X

Special Notes

The version of ld used is from Xcode version 1.5. It contains a fix to a problem which caused crashes in ACIS during static initialization. You may not experience problems using an older version of ld to link ACIS, nevertheless, Spatial recommends that you use this version of ld.
The ACIS dynamic libraries are linked with the option:
     -Wl,-install_name,@executable_path/libXXX.dylib
For bundled applications, ACIS libraries must be in the executable directory at runtime (for example, YourApp.app/Contents/MacOS). You can avoid this requirement when running from the command line by setting the environmental variable DYLD_LIBRARY_PATH to the library location.

X

X

Sun 32-bit and 64-bit/Sun ONE Studio 8

ACIS ARCH names for Solaris platform, Sun ONE Studio 8 Compiler (32-bit, 64-bit)

solaris_so

32-bit release ACIS libraries

solaris _so_debug

32-bit debug ACIS libraries

solaris _64_so

64-bit release ACIS libraries

solaris _64_so_debug

64-bit debug ACIS libraries

CC: Sun Workshop 6 update 2 C++ 5.5 Patch 113817-08 2004/04/13

Description

solaris_so

solaris_so_debug

solaris_64_so

solaris_64_so_debug

Compiler Flags

-features=mutable,bool,arraynew,rtti

Recognize the keyword mutable, allow the bool type and literals, recognize array forms of operator new and delete, allow runtime type identification.

-mt

Compile and link for multithreaded code

X

X

X

X

-PIC

Generate position-independent code

X

X

X

X

-xarch=generic64

Generate 64 bit code

X

X

Preprocessor Directives

_DEBUG

Debug build

X

X

ACIS64

64-bit architecture

X

X

ANSI

Enable ANSI prototyping

X

X

X

X

solaris

Define the base architecture

X

X

X

X

X_WINDOWS(rnd_husk only)

X-Windows support

X

X

X

X

Linker Options

CC -mt –xildoff

X

X

X

X

Preprocess Directives Needed for Building SCM

MOTIF

Motif support

X

X

X

X

Building the ACIS Scheme AIDE Program

In order for you to see how to write and build an ACIS-based application, all source, projects, and makefiles for building the Scheme AIDE program on every platform have been distributed with your ACIS package.

For all platforms on which HOOPS is supported, you may either link using the HOOPS library delivered with ACIS or using a HOOPS installation. Note that if you are relinking acis3dt against a HOOPS version other than the version included with your ACIS installation, you must also rebuild the SpaHBridge and SpaHPart libraries using the projects/makefiles in src/ha_bridge and src/ha_part.

Note:  In order to rebuild the Spatial samples, you must add your license to the sample source code. The sample source file unlock_license.cpp contains a function unlock_license() which is called by every sample at startup. Modify this file to call your application license function.

Building on Windows

Visual Studio C++ 6.0

  1. Open a command prompt window.
  2. Set environment variables:
         set A3DT to <your ACIS installation>, for example, set A3DT=c:\Progra~1\Spatial\acisR17
         set HOOPS_INSTALL_DIR to <your HOOPS installation directory>, if applicable
  3. Open the project file
         cd %A3DT%\scm\acis3dt
         msdev acis3dt.dsw
  4. Choose the configuration (release/debug)
         Build->Set Active Configuration
              ACIS3DT- Win32 Release
              ACIS3DT- Win32 Debug
  5. Add optional ACIS products (if applicable)
         Products->Settings
              C/C++ - Preprocessor definitions; Add:
              ACIS_DM          for 3D ACIS Deformable Modeling
              ACIS_PHLV5     for 3D ACIS PHL V5
  6. Add the corresponding library.
         Win32 Release configuration: Release Libraries
         Select, and then clear "Exclude from build"
              3D ACIS DM Release Lib
              3D ACIS PHL V5 Release Lib

         Win32 Debug configuration: Debug Libraries
         Select, and then clear "Exclude from build"
              3D ACIS DM Debug Lib
              3D ACIS PHL V5 Debug Lib
  7. Choose Build->Build ACIS3DT.exe

Visual Studio .NET 7.1 (NT_NET) and Visual Studio .NET 8.0 (NT_VC8 and NT_AMD_64)

Note:  The SPAha_bridge, SPAha_part, and admhoops DLLs shipped with ACIS were built with HOOPS version 15.0, arch nt_i386_sln (VC7.1), arch nt_x64_vc80 (NT_AMD_64 with VC8.0), and arch nt_i386_vc80 (NT_VC8 with VC8.0). The HOOPS VC6 configurations (nt_i386) have been removed from the acis3dt, ha_bridge, ha_part, and admhoops projects. The project configurations have been renamed to reflect this change.

  1. Open a command prompt window.
  2. Set environment variables:
         set A3DT to <your ACIS installation>, for example, set A3DT=c:\Progra~1\Spatial\acisR17
         set HOOPS_INSTALL_DIR to <your HOOPS installation directory>, if applicable
  3. Open the project file
         cd %A3DT%\scm\acis3dt
         devenv acis3dt.sln (NT_NET)
         devenv acis3dt_amd_64.sln (NT_AMD_64)
         devenv acis3dt_vc8.sln (NT_VC8)
  4. Choose one of the two available configurations: Release or Debug.
  5. Add optional ACIS products (if applicable)
         Open "Properties" for ACIS3DT
              Select C/C++ - Preprocessor; Add:
              ACIS_DM          for 3D ACIS Deformable Modeling
              ACIS_PHLV5     for 3D ACIS PHL V5
  6. Add the corresponding library.
         Release configuration: Release Libraries
         (Spatial arches: NT_VC8_DLL, NT_NET_DLL, NT_AMD_64_DLL)

         For each of the following libraries, open "Properties" and change "Excluded from Build" to No.
              3D ACIS DM Release Lib
              3D ACIS PHL V5 Release Lib

         Debug configuration: Debug Libraries
         (Spatial arches: NT_VC8_DLLD, NT_NET_DLLD, NT_AMD_64_DLLD)

         For each of the following libraries, open "Properties" and change "Excluded from Build" to No.
              3D ACIS DM Debug Lib
              3D ACIS PHL V5 Debug Lib
  7. Choose Build->Build ACIS3DT.exe

Note:  Once you have completed this step and if there are unresolved symbols at link time, then Visual Studio has not recognized that the libraries were added. Save and close the solution file, reopen it and rebuild. This should resolve the link error.

Building on UNIX

Note: If you are relinking acis3dt against a HOOPS version other than 15.0, you must also rebuild the SpaHBridge and SpaHPart libraries using the projects/makefiles in src/ha_bridge and src/ha_part.

  1. Set environment variables:
         Set A3DT to your ACIS installation.
         Set ARCH to the architecture you would like to build, for example, aix4_so.
         Set HOOPS_INSTALL_DIR to the location of your HOOPS installation, if applicable.
         Set HOOPS_VER to the version of your HOOPS installation, if applicable.
  2. Change your directory.
         cd $A3DT/scm/acis3dt
  3. Build the executable.
         Not using a HOOPS installation:
              make TARGET=<target>
        Using a HOOPS installation:
              make –f makefile_hoops TARGET=<target>
    where TARGET is one of the following:
    ACIS 3D ACIS Modeler
    ACIS_DM 3D ACIS Modeler and 3D ACIS Deformable Modeling
    ACIS_PHLV5 3D ACIS Modeler and 3D ACIS PHL V5
    ACIS_ALL 3D ACIS Modeler, 3D ACIS Deformable Modeling and 3D ACIS PHL V5

    The executable (acis3dt) is created in $A3DT/bin/$ARCH.

Building on Macintosh

  1. Open the Xcode project file in <A3DT>:scm:acis3dt, where A3DT is your ACIS installation. The project contains targets that build slightly different configurations of the acis3dt application. The project supports two build styles, both of which work for each of the targets. The Development style builds with debug symbols on and optimization off. The Deployment style builds with debug symbols off and optimization level -O1. Upon opening the project for the first time, the active Build style is Development.
    The targets are:
    acis3dt 3D ACIS Modeler using ACIS release mode macub libraries
    acis3dt_d 3D ACIS Modeler using ACIS debug mode macub libraries
    acis3dt_dm 3D ACIS Modeler and 3D ACIS Deformable Modeling using ACIS release mode macub libraries
    acis3dt_dm_d 3D ACIS Modeler and 3D ACIS Deformable Modeling using ACIS debug mode macub libraries
    acis3dt_phlv5 3D ACIS Modeler and 3D ACIS PHL V5 using ACIS release mode macub libraries
    acis3dt_phlv5_d 3D ACIS Modeler and 3D ACIS PHL V5 using ACIS debug mode macub libraries
    acis3dt_all 3D ACIS Modeler, 3D ACIS Deformable Modeling and 3D ACIS PHL V5 using ACIS release mode macub libraries
    acis3dt_all_d 3D ACIS Modeler, 3D ACIS Deformable Modeling and 3D ACIS PHL V5 using ACIS debug mode macub libraries

  2. Choose your desired build target using the Active Target drop down list.
  3. Update settings regarding your HOOPS installation, if applicable. These settings must be updated in both build styles.
    1. Click the Info button in the main toolbar, or select File->Get Info.
    2. Select the Build pane.
    3. Select the desired configuration or select "All Configurations" from the Configuration drop down menu.
    4. Select "Edit>Change Existing Settings" then change the two custom build settings HOOPS_INSTALL_DIR and HOOPS_VER.
    5. Using the Active Build Style drop down list, change the build configuration from Development to Deployment and repeat the previous two steps.
    6. Close the Info window.
  4. Click Build. Open the detailed build window (Build->Detailed Build Results) to view detailed build results, switch build style or switch the active build target.
  5. The application bundle is placed in <A3DT>/scm/acis3dt/build, which is Xcode's default build location. To change the destination location:
    1. In the Groups & Files window, select the project icon at the top of the window (titled acis3dt).
    2. Click the Info button in the main toolbar, or select File->Get Info.
    3. Select the General pane.
    4. Change the "Place Build Products In" setting to "Separate location" and enter your desired location.
  6. Note that three custom phases have been added to the Xcode build sequence to prepare the acis3dt bundle for runtime. Hence, additional disc space is occupied by the library copies.
    1. The libtool table of contents update discussed below is performed in a Shell Script phase.
    2. The HOOPS library is copied from $(HOOPS_INSTALL_DIR)/Dev_Tools/hoops_3dgs/lib to acis3dt*.app/Contents/MacOS.
    3. The ACIS dynamic libraries are copied from the ACIS bin directory to acis3dt*.app/Contents/MacOS.

Note Regarding Building and Using ACIS Scheme AIDE Program on Macintosh

ACIS Dynamic Libraries

ACIS dynamic libraries must be present in an application bundle's executable directory at runtime. Rather than installing an extra copy of the ACIS dynamic libraries inside the acis3dt application shipped with ACIS, your ACIS package supplies a script that creates relative links inside the acis3dt bundle pointing to each dynamic library in the bin/$ARCH directory. You must run this script before acis3dt can execute.

After installing ACIS, open a terminal window.
cd $A3DT/bin/macub
./RUNFIRST.sh.

where $A3DT is your ACIS installation.

Scheme Initialization File

Note that the scheme initialization file, acisinit.scm, is not automatically loaded by the Scheme AIDE program. This file defines some commonly used scheme procedures, such as zoom-all. On other platforms, Scheme AIDE looks for the file in either a path relative to the executable's location or a path relative to the current working directory. When running an application from the Finder on Mac OSX, neither of these options works.

To load the file, type the following command at the Scheme prompt:
(load "$A3DT/scm/examples/acisinit.scm")
where $A3DT is your ACIS installation.

Loading acisinit.scm

For the default toolkit applications that are provided with product installation, the acisinit.scm does not load automatically as it does on other platforms. The file, acisinit.scm is found in $A3DT/scm/examples/acisinit.scm, where $A3DT is the installation directory. You may load it after starting a Scheme session by using the command:
load "<path the ACIS>/scm/examples/acisinit.scm"

Scheme Static Libraries

Prior to use, all static libraries must have their table of contents updated once using libtool. The libtool emits an error when linking the executable if the table of contents of an included static library is older than the library's creation date. This error occurs if the library has been copied without retaining its original creation date, although the table of contents of the library is not actually out of date. The acis3dt.xcode sample project performs this step during the build, after which the libraries can be linked into any application.

To link the static libraries into your application without running the acis3dt.xcode sample project, you must perform this step manually:
     for mylib in $A3DT/lib/$ARCH/*.a
     do
          libtool -static -o $mylib $mylib
     done

where $A3DT is your ACIS installation and $ARCH is either macub or macub_debug.

Building the HOOPS/ACIS Bridge

ACIS ships projects and makefiles on all platforms for rebuilding the HOOPS/ACIS Bridge and ACIS Deformable Modeling HOOPS. This section discusses how to build the bridge.

Note:  In order to rebuild the Spatial samples, you must add your license to the sample source code. The sample source file unlock_license.cpp contains a function unlock_license() which is called by every sample at startup. Modify this file to call your application license function.

HOOPS/ACIS Bridge Projects and Makefiles

The HOOPS/ACIS Bridge libraries shipped with ACIS are linked against HOOPS 15.0. The source code for the HOOPS/ACIS Bridge is shipped with ACIS so that you may:

Projects and makefiles for rebuilding the two libraries in the bridge, SpaHPart and SpaHBridge, are included in the src/ha_bridge and src/ha_part directories. For those using ACIS Deformable Modeling, Spatial includes an additional set of projects for rebuilding the admhoops library in src/admhoops.

WARNING: If you are building a custom version of the HOOPS/ACIS Bridge, you must perform a rebuild when a new service pack is installed. This requirement results from the service pack's need to reinstall libraries linked against HOOPS 15.0 and to ensure that functionality changes in the bridge source code are incorporated into your bridge libraries.

If you have used these projects in previous releases, you must note that the projects have been changed to support different versions of HOOPS. Thus, UNIX makefiles now require that the environmental variable, HOOPS_VER, be set. For the .NET 7.1 projects, the HOOPS VC6 configurations (nt_i386) have been removed from the acis3dt, ha_bridge, ha_part, and admhoops projects. The project configurations have been renamed to reflect this change.

Building the SpaHPart, SpaHBridge, and admhoops Libraries on Windows

Visual C++ 6.0

  1. Open a command prompt window.
  2. Set the following environment variables:
         set A3DT to <your ACIS R17 installation>, for example, set A3DT=c:\Progra~1\Spatial\acisR17
         set HOOPS_INSTALL_DIR to <your HOOPS installationdirectory>>
  3. Open the desired project:
         cd %A3DT%\src\ha_bridge (or src\ha_part or src\admhoops)
         msdev ha_bridge.dsw (or ha_part.dsw or admhoops.dsw)
  4. Choose the configuration (release/debug):
         Win32 Release
         Win32 Debug
  5. Build->Set Active Configuration
  6. Build->Build the library

Visual Studio .NET 7.1

  1. Open a command prompt window.
  2. Set the following environment variables:
         set A3DT to <your ACIS R17 installation>, for example, set A3DT=c:\Progra~1\Spatial\acisR17
         set HOOPS_INSTALL_DIR to <your HOOPS installationdirectory>>
  3. Open the desired project:
         cd %A3DT%\src\ha_bridge (or src\ha_part or src\admhoops)
         devenv ha_bridge.sln (or ha_part.sln or admhoops.sln)
  4. Choose one of these configurations:
         Release - Use with HOOPS version 10 or higher to link release ACIS to VC7.1 release HOOPS.
         Debug - Use with HOOPS version 10 or higher to link debug ACIS to VC7.1 debug HOOPS.
  5. Build->Build the library

Visual C++ 8.0 (NT_VC8 and NT_AMD_64)

  1. Open a command prompt window.
  2. Set the following environment variables:
         set A3DT to <your ACIS R17 installation>, for example, set A3DT=c:\Progra~1\Spatial\acisR17
         set HOOPS_INSTALL_DIR to <your HOOPS installationdirectory>>
  3. Open the desired project:
         cd %A3DT%\src\ha_bridge (or src\ha_part or src\admhoops)
         devenv ha_bridge_amd_64.sln (or ha_part_amd_64.sln or admhoops_amd_64.sln) (for NT_AMD_64)
         devenv ha_bridge_vc8.sln (or ha_part_vc8.sln or admhoops_vc8.sln) (for NT_VC8)
  4. Choose one of these configurations:
         Release - Use with HOOPS version 10 or higher to link release ACIS to VC8.0 release HOOPS.
         Debug - Use with HOOPS version 10 or higher to link debug ACIS to VC8.0 debug HOOPS.
  5. Build->Build the library

Building the SpaHPart, SpaHBridge, and admhoops Libraries on UNIX

  1. Set the following environment variables:
         Set A3DT to your ACIS R17 installation
         Set ARCH to the ACIS architecture you would like to build against, for example aix4_so
         Set HOOPS_INSTALL_DIR to the location of your HOOPS installation
         Set HOOPS_VER to the version of your hoops installation.
  2. Change your working directory:
         cd $A3DT/src/ha_bridge (or src/ha_part or src/admhoops)
  3. Build the library:
         make arch
    where arch is one of the following:
         aix
         aix64
         hpux11
         hpux64
         linux
         linux_amd_64
         solaris
         solaris_64

Building the SpaHPart, SpaHBridge, and admhoops Libraries on Mac OS X

  1. Open the desired Xcode project in A3DT/src/ha_bridge (or src/ha_part or src/admhoops), where A3DT is your ACIS installation location.
  2. Update the settings regarding your HOOPS installation.
    1. In the Groups & Files window, expand the Target category and select the target (ha_bridge, ha_part or admhoops).
    2. Click the Info button in the main toolbar, or select File->Get Info.
    3. Select the Build pane.
    4. Scroll down through the settings to the two custom build settings HOOPS_INSTALL_DIR and HOOPS_VER.
    5. Select Edit Setting for each one and enter the appropriate value.

  3. Click Build on the main window.
    The library is placed in A3DT/src/ha_bridge/build, which is Xcode's default build location.
    To change the destination location:
    1. In the Groups & Files window, select the project icon at the top of the window(titled ha_bridge, ha_part, or admhoops).
    2. Click the Info button in the main toolbar, or select File->Get Info.
    3. Select the General pane.
    4. Change the "Place Build Products In" setting to "Separate location" and enter your desired location.

    Note: The project supports two build styles, both of which link against ACIS release libraries and the HOOPS release library. The Development style builds with debug symbols on and optimization off. The Deployment style builds with debug symbols off and optimization level -O1. Upon opening the project for the first time, the active Build Style is Development.
    To switch the style:

    1. Open the build results window by selecting Build->Detailed Build Results.
    2. Select Deployment from the Active Build Style drop down list.

[Top]