Skip to content

Commit

Permalink
Revert "Use INC_DIR for OPENJPEG_INCLUDE_DIRS (fixes uclouvain#1174)"
Browse files Browse the repository at this point in the history
This reverts commit 6558637 which
breaks cross-compilation of poppler under buildroot (because of
DESTDIR usage).
  • Loading branch information
ffontaine authored and msabwat committed Jun 10, 2021
1 parent 0d9a565 commit a26c71b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cmake/OpenJPEGConfig.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,12 @@ if(EXISTS ${SELF_DIR}/OpenJPEGTargets.cmake)
# This is an install tree
include(${SELF_DIR}/OpenJPEGTargets.cmake)

# We find a relative path from the PKG directory to header files.
set(PKG_DIR "@CMAKE_INSTALL_PREFIX@/@OPENJPEG_INSTALL_PACKAGE_DIR@")
set(INC_DIR "@CMAKE_INSTALL_PREFIX@/@OPENJPEG_INSTALL_INCLUDE_DIR@")
get_filename_component(OPENJPEG_INCLUDE_DIRS "${INC_DIR}" ABSOLUTE)
file(RELATIVE_PATH PKG_TO_INC_RPATH "${PKG_DIR}" "${INC_DIR}")

get_filename_component(OPENJPEG_INCLUDE_DIRS "${SELF_DIR}/${PKG_TO_INC_RPATH}" ABSOLUTE)

else()
if(EXISTS ${SELF_DIR}/OpenJPEGExports.cmake)
Expand Down

0 comments on commit a26c71b

Please sign in to comment.