0% found this document useful (0 votes)
11 views1 page

CMake Lists

The document outlines a CMake configuration for the libjxl library, specifying its repository and version. It includes various options for building features such as testing, documentation, and examples, all set to OFF by default. The configuration also sets up include directories and links the 'imagedecoder' target with several libraries, including jxl_dec and brotlidec.

Uploaded by

caksumo9
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views1 page

CMake Lists

The document outlines a CMake configuration for the libjxl library, specifying its repository and version. It includes various options for building features such as testing, documentation, and examples, all set to OFF by default. The configuration also sets up include directories and links the 'imagedecoder' target with several libraries, including jxl_dec and brotlidec.

Uploaded by

caksumo9
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1

FetchContent_Declare(libjxl

GIT_REPOSITORY https://github.com/libjxl/libjxl
GIT_TAG v0.10.0
BINARY_DIR build
SUBBUILD_DIR subbuild
)

option(BUILD_TESTING "" OFF)


option(JPEGXL_ENABLE_DOXYGEN "" OFF)
option(JPEGXL_ENABLE_MANPAGES "" OFF)
option(JPEGXL_ENABLE_EXAMPLES "" OFF)
option(JPEGXL_ENABLE_SJPEG "" OFF)
option(JPEGXL_ENABLE_OPENEXR "" OFF)
option(JPEGXL_ENABLE_TRANSCODE_JPEG "" OFF)
option(JPEGXL_ENABLE_TOOLS "" OFF)
option(JPEGXL_ENABLE_BENCHMARK "" OFF)
option(JPEGXL_ENABLE_JPEGLI "" OFF)
option(JPEGXL_ENABLE_JNI "" OFF)
option(JPEGXL_ENABLE_DEVTOOLS "" OFF)
option(JPEGXL_ENABLE_BENCHMARK "" OFF)

FetchContent_GetProperties(libjxl)

if(NOT libjxl_POPULATED)
FetchContent_Populate(libjxl)
add_subdirectory(${libjxl_SOURCE_DIR} ${libjxl_BINARY_DIR} EXCLUDE_FROM_ALL)
endif()

target_include_directories(imagedecoder PRIVATE
${libjxl_BINARY_DIR}
${libjxl_SOURCE_DIR}
$<TARGET_PROPERTY:hwy,INCLUDE_DIRECTORIES>
)

target_link_libraries(imagedecoder
jxl_dec
jxl_threads
brotlidec
brotlienc
brotlicommon
hwy
-Wl,--allow-multiple-definition
)

You might also like