1 2add_definitions( 3 -DWIN32 4 -DNDEBUG 5 -DUSE_WIN32_FILEIO 6 -DTIF_PLATFORM_CONSOLE) 7 8if(MSVC) 9 # error C4311: 'type cast': pointer truncation from 'thandle_t' to 'int' 10 replace_compile_flags("/we4311" " ") 11 12 # error C4312: 'type cast': conversion from 'int' to 'thandle_t' of greater size 13 replace_compile_flags("/we4312" " ") 14endif() 15 16include_directories( 17 ${REACTOS_SOURCE_DIR}/sdk/include/reactos/libs/libtiff 18 ${REACTOS_SOURCE_DIR}/sdk/include/reactos/libs/zlib) 19 20list(APPEND SOURCE 21 #mkg3states.c 22 tif_aux.c 23 tif_close.c 24 tif_codec.c 25 tif_color.c 26 tif_compress.c 27 tif_dir.c 28 tif_dirinfo.c 29 tif_dirread.c 30 tif_dirwrite.c 31 tif_dumpmode.c 32 tif_error.c 33 tif_extension.c 34 tif_fax3.c 35 tif_fax3sm.c 36 tif_flush.c 37 tif_getimage.c 38 #tif_jbig.c 39 #tif_jpeg.c 40 tif_luv.c 41 #tif_lzma.c 42 tif_lzw.c 43 tif_next.c 44 #tif_ojpeg.c 45 tif_open.c 46 tif_packbits.c 47 tif_pixarlog.c 48 tif_predict.c 49 tif_print.c 50 tif_read.c 51 #tif_stream.cxx 52 tif_strip.c 53 tif_swab.c 54 tif_thunder.c 55 tif_tile.c 56 tif_version.c 57 tif_warning.c 58 #tif_webp.c 59 tif_win32.c 60 tif_write.c 61 tif_zip.c 62 #tif_zstd.c 63 precomp.h) 64 65add_library(libtiff MODULE ${SOURCE} libtiff.def) 66set_module_type(libtiff win32dll) 67target_link_libraries(libtiff zlib getopt) 68add_importlibs(libtiff user32 msvcrt kernel32 ntdll) 69add_pch(libtiff precomp.h SOURCE) 70add_cd_file(TARGET libtiff DESTINATION reactos/system32 FOR all) 71 72if(NOT MSVC) 73 target_compile_options(libtiff PRIVATE "-Wno-unused-but-set-variable") 74endif() 75