Open CASCADE Technology
7.4.0
|
|
This page describes steps to build OCCT libraries from a complete source archive on Windows with MS Visual C++ using projects generated by genproj tool. It is an alternative to use of CMake build system (see Building with CMake).
genproj is a legacy tool (originated from command "wgenproj" in WOK) for generation of Visual Studio, Code.Blocks, and XCode project files used for building Open CASCADE Technology. These project files are placed inside OCCT directory (in adm subfolder) and use relative paths, thus can be moved together with sources.
The project files included in official distribution of OCCT are generated by this tool. If you have official distribution with project files included, you can use them directly without a need to call genproj.
Before building OCCT, make sure to have all the required third-party libraries installed.
The easiest way to install third-party libraries is to download archive with pre-built binaries, corresponding to version of Visual Studio you are using, from https://www.opencascade.com/content/3rd-party-components.
You can also build third-party libraries from their sources, see Building 3rd-party libraries on Windows for instructions.
If you have Visual Studio projects already available (pre-installed or generated), you can edit file custom.bat manually to adjust the environment:
VCVER | Visual Studio version | Windows Platform | Binaries folder name |
---|---|---|---|
vc10 | 2010 (10) | Desktop (Windows API) | vc10 |
vc11 | 2012 (11) | Desktop (Windows API) | vc11 |
vc12 | 2013 (12) | Desktop (Windows API) | vc12 |
vc14 | 2015 (14) | Desktop (Windows API) | vc14 |
vc14-uwp | 2015 (14) | UWP (Universal Windows Platform) | vc14-uwp |
vc141 | 2017 (15) | Desktop (Windows API) | vc14 |
vc141-uwp | 2017 (15) | UWP (Universal Windows Platform) | vc14-uwp |
vc142 | 2019 (16) | Desktop (Windows API) | vc14 |
vc142-uwp | 2019 (16) | UWP (Universal Windows Platform) | vc14-uwp |
Alternatively, you can launch genconf, a GUI tool allowing to configure build options interactively. That tool will analyze your environment and propose you to choose available options:
Click "Save" to store the specified configuration in custom.bat file.
Launch genproj to update content of inc folder and generate project files after changes in OCCT code affecting layout or composition of source files.
Note that if custom.bat is not present, genproj will start genconf to configure environment.
Launch msvc.bat to start Visual Studio with all necessary environment variables defined, and build the whole solution or required toolkits.
Note: the MSVC project files are located in folders adm\msvc\vc.... Binaries are produced in win32 or win64 folders.
To start DRAW, launch draw.bat.