fltk/png/CMakeLists.txt
Albrecht Schlosser a0d26b634a Mostly rewritten CMake files by Michael Surette. They are more complete
than what we had previously, but may need some more testing. The latest
changes (removing old APPLE_QD definitions and code) might need another
update.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7451 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2010-04-05 22:33:58 +00:00

36 lines
993 B
CMake

project(FLTKPNG)
include_regular_expression("^png.*[.][c|h]$")
include_directories(${FLTKZLIB_SOURCE_DIR})
include_directories(${ZLIB_INCLUDE_DIR})
include_directories(${FLTKPNG_SOURCE_DIR})
include_directories(${FLTKPNG_BINARY_DIR})
# source files for png
set(PNG_SRCS
pngget.c pngrio.c pngwrite.c
png.c pngmem.c pngrtran.c pngtrans.c pngwtran.c
pngerror.c pngpread.c pngrutil.c pngwutil.c
pngread.c pngset.c pngwio.c
)
#######################################################################
add_library(fltk_png ${PNG_SRCS})
if(MSVC)
set_target_properties(fltk_png PROPERTIES OUTPUT_NAME fltkpng)
if(OPTION_LARGE_FILE)
set_target_properties(fltk_png PROPERTIES LINK_FLAGS /LARGEADDRESSAWARE)
endif(OPTION_LARGE_FILE)
else()
set_target_properties(fltk_png PROPERTIES OUTPUT_NAME fltk_png)
endif(MSVC)
target_link_libraries(fltk_png ${FLTK_ZLIB_LIBRARIES})
install(TARGETS fltk_png
EXPORT fltk-install
DESTINATION ${PREFIX_LIB}
)