patch from IRIE Shinsuke, use systems openjpeg on *nix.
[blender.git] / build_files / cmake / macros.cmake
index b700fdf2cfa95494c58b934a92d33e80b57838c0..6fd9fda152bf65b07a1c14de4afd988f63d8a737 100644 (file)
@@ -85,6 +85,9 @@ macro(SETUP_LIBDIRS)
        if(WITH_IMAGE_TIFF)
                link_directories(${TIFF_LIBPATH})
        endif()
+       if(WITH_IMAGE_OPENJPEG AND UNIX AND NOT APPLE)
+               link_directories(${OPENJPEG_LIBPATH})
+       endif()
        if(WITH_LCMS)
                link_directories(${LCMS_LIBPATH})
        endif()
@@ -180,6 +183,9 @@ macro(setup_liblinks
                        target_link_libraries(${target} ${OPENEXR_LIB})
                endif()
        endif()
+       if(WITH_IMAGE_OPENJPEG AND UNIX AND NOT APPLE)
+               target_link_libraries(${target} ${OPENJPEG_LIB})
+       endif()
        if(WITH_LCMS)
                target_link_libraries(${target} ${LCMS_LIBRARY})
        endif()