@@ -44,52 +44,66 @@ else()
4444
4545 endif ()
4646
47- add_executable (ojph_compress ${SOURCES} )
47+ # add_executable(ojph_compress ${SOURCES})
4848
49- if ( USE_TIFF )
50- if ( USE_OPENEXR )
51- target_link_libraries (ojph_compress PUBLIC openjph ${TIFF_LIBRARIES}
52- # For OpenEXR/Imath 3.x:
53- $<$<TARGET_EXISTS:OpenEXR::OpenEXR>:OpenEXR::OpenEXR>
54- $<$<TARGET_EXISTS:Imath::Imath>:Imath::Imath>
55- $<$<TARGET_EXISTS:Imath::Half>:Imath::Half>
56- # For OpenEXR 2.4/2.5:
57- $<$<TARGET_EXISTS:OpenEXR::IlmImf>:OpenEXR::IlmImf>
58- $<$<TARGET_EXISTS:IlmBase::Imath>:IlmBase::Imath>
59- $<$<TARGET_EXISTS:IlmBase::Half>:IlmBase::Half>
60- $<$<TARGET_EXISTS:IlmBase::IlmThread>:IlmBase::IlmThread>
61- $<$<TARGET_EXISTS:IlmBase::Iex>:IlmBase::Iex>
62- # ZLIB for OpenEXR 2.x:
63- $<$<TARGET_EXISTS:ZLIB::ZLIB>:ZLIB::ZLIB>)
64- else ()
65- target_link_libraries (ojph_compress PUBLIC openjph ${TIFF_LIBRARIES} )
66- endif ()
67- else ()
68- if ( USE_OPENEXR )
69- target_link_libraries (ojph_compress PUBLIC openjph
70- # For OpenEXR/Imath 3.x:
71- $<$<TARGET_EXISTS:OpenEXR::OpenEXR>:OpenEXR::OpenEXR>
72- $<$<TARGET_EXISTS:Imath::Imath>:Imath::Imath>
73- $<$<TARGET_EXISTS:Imath::Half>:Imath::Half>
74- # For OpenEXR 2.4/2.5:
75- $<$<TARGET_EXISTS:OpenEXR::IlmImf>:OpenEXR::IlmImf>
76- $<$<TARGET_EXISTS:IlmBase::Imath>:IlmBase::Imath>
77- $<$<TARGET_EXISTS:IlmBase::Half>:IlmBase::Half>
78- $<$<TARGET_EXISTS:IlmBase::IlmThread>:IlmBase::IlmThread>
79- $<$<TARGET_EXISTS:IlmBase::Iex>:IlmBase::Iex>
80- # ZLIB for OpenEXR 2.x:
81- $<$<TARGET_EXISTS:ZLIB::ZLIB>:ZLIB::ZLIB>)
82- else ()
83- target_link_libraries (ojph_compress PUBLIC openjph)
84- endif ()
85- endif ()
49+ # if( USE_TIFF )
50+ # if( USE_OPENEXR )
51+ # target_link_libraries(ojph_compress PUBLIC openjph ${TIFF_LIBRARIES}
52+ # # For OpenEXR/Imath 3.x:
53+ # $<$<TARGET_EXISTS:OpenEXR::OpenEXR>:OpenEXR::OpenEXR>
54+ # $<$<TARGET_EXISTS:Imath::Imath>:Imath::Imath>
55+ # $<$<TARGET_EXISTS:Imath::Half>:Imath::Half>
56+ # # For OpenEXR 2.4/2.5:
57+ # $<$<TARGET_EXISTS:OpenEXR::IlmImf>:OpenEXR::IlmImf>
58+ # $<$<TARGET_EXISTS:IlmBase::Imath>:IlmBase::Imath>
59+ # $<$<TARGET_EXISTS:IlmBase::Half>:IlmBase::Half>
60+ # $<$<TARGET_EXISTS:IlmBase::IlmThread>:IlmBase::IlmThread>
61+ # $<$<TARGET_EXISTS:IlmBase::Iex>:IlmBase::Iex>
62+ # # ZLIB for OpenEXR 2.x:
63+ # $<$<TARGET_EXISTS:ZLIB::ZLIB>:ZLIB::ZLIB>)
64+ # else()
65+ # target_link_libraries(ojph_compress PUBLIC openjph ${TIFF_LIBRARIES})
66+ # endif()
67+ # else()
68+ # if( USE_OPENEXR )
69+ # target_link_libraries(ojph_compress PUBLIC openjph
70+ # # For OpenEXR/Imath 3.x:
71+ # $<$<TARGET_EXISTS:OpenEXR::OpenEXR>:OpenEXR::OpenEXR>
72+ # $<$<TARGET_EXISTS:Imath::Imath>:Imath::Imath>
73+ # $<$<TARGET_EXISTS:Imath::Half>:Imath::Half>
74+ # # For OpenEXR 2.4/2.5:
75+ # $<$<TARGET_EXISTS:OpenEXR::IlmImf>:OpenEXR::IlmImf>
76+ # $<$<TARGET_EXISTS:IlmBase::Imath>:IlmBase::Imath>
77+ # $<$<TARGET_EXISTS:IlmBase::Half>:IlmBase::Half>
78+ # $<$<TARGET_EXISTS:IlmBase::IlmThread>:IlmBase::IlmThread>
79+ # $<$<TARGET_EXISTS:IlmBase::Iex>:IlmBase::Iex>
80+ # # ZLIB for OpenEXR 2.x:
81+ # $<$<TARGET_EXISTS:ZLIB::ZLIB>:ZLIB::ZLIB>)
82+ # else()
83+ # target_link_libraries(ojph_compress PUBLIC openjph)
84+ # endif()
85+ # endif()
8686
87- install (TARGETS ojph_compress DESTINATION bin)
87+ # install(TARGETS ojph_compress DESTINATION bin)
8888endif ()
8989
9090add_executable (ojph_compress ${SOURCES} )
9191target_include_directories (ojph_compress PRIVATE ../common)
92- target_link_libraries (ojph_compress PRIVATE openjph $<TARGET_NAME_IF_EXISTS:TIFF::TIFF>)
92+ target_link_libraries (ojph_compress PRIVATE openjph
93+ #TIFF
94+ $<TARGET_NAME_IF_EXISTS:TIFF::TIFF>
95+ # For OpenEXR/Imath 3.x:
96+ $<$<TARGET_EXISTS:OpenEXR::OpenEXR>:OpenEXR::OpenEXR>
97+ $<$<TARGET_EXISTS:Imath::Imath>:Imath::Imath>
98+ $<$<TARGET_EXISTS:Imath::Half>:Imath::Half>
99+ # For OpenEXR 2.4/2.5:
100+ $<$<TARGET_EXISTS:OpenEXR::IlmImf>:OpenEXR::IlmImf>
101+ $<$<TARGET_EXISTS:IlmBase::Imath>:IlmBase::Imath>
102+ $<$<TARGET_EXISTS:IlmBase::Half>:IlmBase::Half>
103+ $<$<TARGET_EXISTS:IlmBase::IlmThread>:IlmBase::IlmThread>
104+ $<$<TARGET_EXISTS:IlmBase::Iex>:IlmBase::Iex>
105+ # ZLIB for OpenEXR 2.x:
106+ $<$<TARGET_EXISTS:ZLIB::ZLIB>:ZLIB::ZLIB>)
93107
94108install (TARGETS ojph_compress
95109 EXPORT openjph-config
0 commit comments