@@ -111,8 +111,8 @@ The instructions that follow describe building OpenEXR with CMake.
111111Note that as of OpenEXR 3, the Gnu autoconf bootstrap/configure build
112112system is no longer supported.
113113
114- Header Layout and ``#include `` Policy
115- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
114+ Headers and ``#include `` Policy
115+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
116116
117117Public headers are installed under ``${CMAKE_INSTALL_INCLUDEDIR} `` in
118118a dedicated subdirectory, by default ``OpenEXR/ `` (the CMake cache
@@ -138,25 +138,32 @@ The same dual-path behavior is reflected in the ``pkg-config`` file
138138**Recommended usage: ** Prefer ``find_package(OpenEXR …) `` and
139139``target_link_libraries(… OpenEXR::…) `` in CMake, or ``pkg-config `` for
140140other build systems, and keep either include spelling consistent within
141- your project. If you must set compiler flags yourself, mirror both
142- include directories above; a single ``-I$prefix/include `` without the
143- ``OpenEXR `` subdirectory is **not ** sufficient for flat
144- ``#include <Imf*.h> `` lines.
141+ your project.
142+
143+ If you are not using cmake or pkg-config and must set compiler flags
144+ yourself, mirror both include directories above and include
145+ ``-I$prefix/include `` and ``-I$prefix/include/OpenEXR ``; a single
146+ ``-I$prefix/include `` without the ``OpenEXR `` subdirectory is **not **
147+ sufficient for flat ``#include <Imf*.h> `` lines.
145148
146149This layout preserves long-standing flat includes in existing code and
147150documentation while keeping headers grouped under ``OpenEXR/ `` on
148151disk. There is no plan to remove either style in current release
149152lines.
150153
151- Also note that within the OpenEXR source tree, all local headers are
152- included with quotes, i.e. ``#include "ImfHeader.h" ``, not angle
153- brackets ``<> ``, since for an internal build the headers come from the
154- same library tree. Also note that since headers are stored alongside
155- source files in each internal library directory (``OpenEXR ``,
156- ``OpenEXRCore ``, ``OpenEXRUtil ``, ``Iex ``, ``IlmThread ``), not in a
157- single common ``OpenEXR `` folder, they are included internally as bare
158- files, without a ``OpenEXR/ `` subdirectory. This intentionally differs
159- from the installed layout.
154+ Headers in the OpenEXR Source Tree
155+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
156+
157+ When inspecting the OpenEXR source code or investigating issues
158+ building the library, note that within the OpenEXR source tree, all
159+ local headers are included with quotes, i.e. ``#include
160+ "ImfHeader.h" ``, not angle brackets ``<> ``, since for an internal
161+ build the headers come from the same library tree. Also note that
162+ since headers are stored alongside source files in each internal
163+ library directory (``OpenEXR ``, ``OpenEXRCore ``, ``OpenEXRUtil ``,
164+ ``Iex ``, ``IlmThread ``), not in a single common ``OpenEXR `` folder,
165+ they are included internally as bare files, without a ``OpenEXR/ ``
166+ subdirectory. This intentionally differs from the installed layout.
160167
161168OpenEXR/Imath Version Compatibility
162169~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
0 commit comments