Warning, /DD4hep/examples/README.md is written in an unsupported language. File is not indexed.
0001 # DD4hep Examples
0002
0003 The subfolders in this directory contain several examples on how to use DD4hep. There are two ways to build these examples:
0004 1. **Recommended way**:
0005 to build all examples in this folder:
0006 ```
0007 mkir build
0008 cd build
0009 cmake ..
0010 make
0011 make install
0012 ctest --output-on-failure
0013 ```
0014 or to build a subset, use the variable `DD4HEP_EXAMPLES` e.g.
0015 ```
0016 cmake -DDD4HEP_EXAMPLES="OpticalSurfaces DDG4" ..
0017 make
0018 make install
0019 ctest --output-on-failure
0020 ```
0021 2. Not-recommended way:
0022 It is also possible to build each subfolder separately, however in this case the tests are not enabled:
0023 ```
0024 cd OpticalSurfaces
0025 mkir build
0026 cd build
0027 cmake ..
0028 make
0029 make install
0030 ```
0031