A meta-package for developing projects that use these libraries.
Throughout this section, I assume
- Your installation prefix is /opt/extern,
- You installed to a subdirectory of the installation prefix,
- Your version of ovsrpro is 21.09.
If you do any of these differently, make the appropriate substitutes in the instructions and example commands.
- Install ovsrpro on your platform. See the releases page for downloads.
- We recommend installing to /opt/extern/, but that is not required.
- Create a symbolic link from /opt/extern/ovsrpro/ /opt/extern/ovsrpro-21.09-gcc931-64-Linux/.
- Update your ldconfig.
./ovsrpro-21.09-gcc931-64-Linux.sh \
--prefix=/opt/extern \
--include-subdir
ln -s /opt/extern/ovsrpro-21.09-gcc931-64-Linux/ /opt/extern/ovsrpro
- Copy /opt/extern/ovsrpro-21.09-gcc931-64-Linux/share/cmake/Findovsrpro.cmake to the root directory of your project.
- In your root CMakeLists.txt file, add these lines:
set(ovsrpro_rev 21.09) find_package(ovsrpro)
- Use
opFindPkg()
to load an ovsrpro package:opFindPkg(qwt)
We recommend using our VS Code development container. Follow these steps to get the container setup.
- Clone the repository.
- Make a build directory adjacent to the repository.
cd /path/to/repository mkdir ../build
- Open the repository folder in VS Code.
- Use the VS Code command
Remote Containers: Rebuild and Reopen in Container
.
If you don't want to use the development container, you need to maintain your own build environment. Follow these instructions to set up your system.
- Install these tools:
- Install 3rd party development packages. See our development container Dockerfile for the complete list.
Run these steps in your build directory:
- Use CMake to generate the build system.
- Use your build tool to build the projects.
- Use CPack to create the installation package.
Here is a basic complete example:
cmake -D XP_STEP=build ../ovsrpro
cmake --build .
cpack -G STGZ
Refer to the cmake(1) and cpack(1) documentation for more options. See the externpro documentation for available CMake options. In addition, there are a few undocumented options which you might find useful.
Option | Type | Default | Description |
---|---|---|---|
XP_BUILD_DEBUG |
boolean | true |
Build debug versions of the projects. Note that release versions are always built. |
XP_DEFAULT |
boolean | true |
Build all the ovsrpro projects. If you disable this option, you can enable individual projects with their XP_PRO_<project> options. |
XP_MARKPARTIAL |
boolean | true |
Add "-p" to the ovsrpro project files, such as the installation package. This only occurs if some projects are excluded from the build. |
XP_PRO_<projct> |
boolean | false |
Configure and build the <project> project. If XP_DEFAULT is enabled, these options are ignored. |