From 1a006390d9ba8a2efb14bb396dd9f7aecba79d90 Mon Sep 17 00:00:00 2001 From: Glenn Randers-Pehrson Date: Tue, 5 Oct 2010 08:36:49 -0500 Subject: [PATCH] [master] Wrapped long lines in CMakeLists.txt and introduced ${libpng_public_hdrs} --- ANNOUNCE | 1 + CHANGES | 1 + CMakeLists.txt | 35 +++++++++++++++++++++++++---------- 3 files changed, 27 insertions(+), 10 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index f28ddabf7..4ac6145f5 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -36,6 +36,7 @@ version 1.4.5beta02 [October 5, 2010] that CCP writes to standard output by default (Martin Banky). version 1.4.5beta03 [October 5, 2010] + Wrapped long lines in CMakeLists.txt and introduced ${libpng_public_hdrs} Send comments/corrections/commendations to glennrp at users.sourceforge.net or to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/CHANGES b/CHANGES index 0e1c212ce..cbb573e22 100644 --- a/CHANGES +++ b/CHANGES @@ -2690,6 +2690,7 @@ version 1.4.5beta02 [October 5, 2010] that CCP writes to standard output by default (Martin Banky). version 1.4.5beta03 [October 5, 2010] + Wrapped long lines in CMakeLists.txt and introduced ${libpng_public_hdrs} Send comments/corrections/commendations to glennrp at users.sourceforge.net or to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/CMakeLists.txt b/CMakeLists.txt index 0bc88ad07..2e46ceb14 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -4,7 +4,13 @@ set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true) if(UNIX AND NOT DEFINED CMAKE_BUILD_TYPE) if(CMAKE_MAJOR_VERSION EQUAL 2 AND CMAKE_MINOR_VERSION EQUAL 4) # workaround CMake 2.4.x bug - set(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel.") + set(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING + "Choose the type of build, options are: + None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) + Debug + Release + RelWithDebInfo + MinSizeRel.") else() set(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING "Choose the type of build, options are: @@ -101,11 +107,13 @@ set(PNG_LIB_NAME png${PNGLIB_MAJOR}${PNGLIB_MINOR}) # to distinguish between debug and release lib set(CMAKE_DEBUG_POSTFIX "d") - # OUR SOURCES -set(libpng_sources +set(libpng_public_hdrs png.h pngconf.h +) +set(libpng_sources + ${libpng_public_hdrs} pngpriv.h png.c pngerror.c @@ -237,7 +245,8 @@ install(CODE ${PNG_PC_INSTALL_CODE}) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/libpng-config.in ${CMAKE_CURRENT_BINARY_DIR}/${PNGLIB_NAME}-config @ONLY) -_png_generate_symlink_code(PNG_CONFIG_INSTALL_CODE ${PNGLIB_NAME}-config libpng-config) +_png_generate_symlink_code(PNG_CONFIG_INSTALL_CODE ${PNGLIB_NAME}-config + libpng-config) install(CODE ${PNG_CONFIG_INSTALL_CODE}) # SET UP LINKS @@ -283,7 +292,9 @@ if(NOT SKIP_INSTALL_LIBRARIES AND NOT SKIP_INSTALL_ALL ) ${PNGLIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX} libpng${CMAKE_IMPORT_LIBRARY_SUFFIX}) install(CODE ${PNG_SHARED_IMPLIB_INSTALL_CODE}) - install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_IMPORT_LIBRARY_SUFFIX} DESTINATION ${CMAKE_INSTALL_LIBDIR}) + install(FILES + ${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_IMPORT_LIBRARY_SUFFIX} + DESTINATION ${CMAKE_INSTALL_LIBDIR}) endif() if(NOT WIN32) @@ -291,8 +302,10 @@ if(NOT SKIP_INSTALL_LIBRARIES AND NOT SKIP_INSTALL_ALL ) ${PNGLIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX} libpng${CMAKE_SHARED_LIBRARY_SUFFIX}) install(CODE ${PNG_SHARED_INSTALL_CODE}) - install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_SHARED_LIBRARY_SUFFIX} DESTINATION ${CMAKE_INSTALL_LIBDIR}) - endif() + install(FILES + ${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_SHARED_LIBRARY_SUFFIX} + DESTINATION ${CMAKE_INSTALL_LIBDIR}) + endif() endif() if(PNG_STATIC) @@ -305,14 +318,16 @@ if(NOT SKIP_INSTALL_LIBRARIES AND NOT SKIP_INSTALL_ALL ) ${PNGLIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX} libpng${CMAKE_STATIC_LIBRARY_SUFFIX}) install(CODE ${PNG_STATIC_INSTALL_CODE}) - install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_STATIC_LIBRARY_SUFFIX} DESTINATION ${CMAKE_INSTALL_LIBDIR}) + install(FILES + ${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_STATIC_LIBRARY_SUFFIX} + DESTINATION ${CMAKE_INSTALL_LIBDIR}) endif() endif() endif() if(NOT SKIP_INSTALL_HEADERS AND NOT SKIP_INSTALL_ALL ) - install(FILES png.h pngconf.h DESTINATION include) - install(FILES png.h pngconf.h DESTINATION include/${PNGLIB_NAME}) + install(FILES ${libpng_public_hdrs} DESTINATION include) + install(FILES ${libpng_public_hdrs} DESTINATION include/${PNGLIB_NAME}) endif() if(NOT SKIP_INSTALL_EXECUTABLES AND NOT SKIP_INSTALL_ALL ) install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/libpng-config DESTINATION bin)