2023-12-08 00:13:39 +08:00
|
|
|
|
|
|
|
set(lib_name jpeg-turbo)
|
2023-12-14 04:49:03 +08:00
|
|
|
set(target_name ${lib_name})
|
2023-12-08 00:13:39 +08:00
|
|
|
|
|
|
|
project(${lib_name})
|
|
|
|
|
2024-01-19 20:33:40 +08:00
|
|
|
_1kfetch_dist(jpeg-turbo)
|
2023-12-08 00:13:39 +08:00
|
|
|
|
|
|
|
add_library(${target_name} STATIC IMPORTED GLOBAL)
|
|
|
|
|
|
|
|
set_target_properties(${target_name} PROPERTIES
|
|
|
|
INTERFACE_INCLUDE_DIRECTORIES "${jpeg-turbo_INC_DIR}"
|
|
|
|
)
|
|
|
|
|
|
|
|
if(WINDOWS)
|
|
|
|
set_target_properties(${target_name} PROPERTIES
|
|
|
|
IMPORTED_LOCATION "${jpeg-turbo_LIB_DIR}/jpeg-static.lib"
|
|
|
|
)
|
2024-04-03 01:48:30 +08:00
|
|
|
elseif(APPLE)
|
|
|
|
set_target_properties(${target_name} PROPERTIES
|
|
|
|
IMPORTED_LOCATION "${jpeg-turbo_LIB_DIR}/jpeg.xcframework"
|
|
|
|
)
|
2023-12-08 00:13:39 +08:00
|
|
|
else()
|
|
|
|
set_target_properties(${target_name} PROPERTIES
|
|
|
|
IMPORTED_LOCATION "${jpeg-turbo_LIB_DIR}/libjpeg.a"
|
|
|
|
)
|
|
|
|
endif()
|