diff --git a/CMakeLists.txt b/CMakeLists.txt index 0678c0f92a..6b2c980128 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -124,6 +124,13 @@ include(AddLLVM) include(AddMLIR) include(HandleLLVMOptions) +#------------------------------------------------------------------------------- +# Dip lib configuration +#------------------------------------------------------------------------------- + +find_package(JPEG REQUIRED) +find_package(PNG REQUIRED) + #------------------------------------------------------------------------------- # Hardware detection #------------------------------------------------------------------------------- diff --git a/examples/DIPDialect/CMakeLists.txt b/examples/DIPDialect/CMakeLists.txt index 441652a63e..9b34013e92 100644 --- a/examples/DIPDialect/CMakeLists.txt +++ b/examples/DIPDialect/CMakeLists.txt @@ -3,8 +3,6 @@ if(BUDDY_ENABLE_OPENCV) include_directories(${OpenCV_INCLUDE_DIRS}) endif() -find_package(JPEG REQUIRED) -find_package(PNG REQUIRED) add_library(DIP_LIBS INTERFACE) target_link_libraries(DIP_LIBS INTERFACE ${JPEG_LIBRARY} ${PNG_LIBRARY} BuddyLibDIP) diff --git a/tests/Interface/core/CMakeLists.txt b/tests/Interface/core/CMakeLists.txt index 94fd8d18a8..cfd184b549 100644 --- a/tests/Interface/core/CMakeLists.txt +++ b/tests/Interface/core/CMakeLists.txt @@ -7,8 +7,6 @@ if(BUDDY_ENABLE_OPENCV) include_directories(${OpenCV_INCLUDE_DIRS}) endif() -find_package(JPEG REQUIRED) -find_package(PNG REQUIRED) add_library(DIP_LIB INTERFACE) target_link_libraries(DIP_LIB INTERFACE ${JPEG_LIBRARY} ${PNG_LIBRARY})