From 0927fa6237246a11b2f6550058b52f791c5411f4 Mon Sep 17 00:00:00 2001 From: Robin Stuart Date: Sun, 2 Jan 2011 21:56:30 +0000 Subject: [PATCH] Correct NO_PNG compilation. Correct a couple of minor omissions which prevented compiling without PNG support. --- backend/CMakeLists.txt | 1 + backend/png.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/CMakeLists.txt b/backend/CMakeLists.txt index 612e1158..72637e61 100644 --- a/backend/CMakeLists.txt +++ b/backend/CMakeLists.txt @@ -22,6 +22,7 @@ set_target_properties(zint PROPERTIES SOVERSION "${ZINT_VERSION_MAJOR}.${ZINT_V VERSION ${ZINT_VERSION}) target_link_libraries(zint ${PNG_LIBRARIES} ) +target_link_libraries(zint -lm) install(TARGETS zint ${INSTALL_TARGETS_DEFAULT_ARGS} ) install(FILES zint.h DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel) diff --git a/backend/png.c b/backend/png.c index c3a69361..7c53290f 100644 --- a/backend/png.c +++ b/backend/png.c @@ -34,8 +34,8 @@ #ifndef NO_PNG #include "png.h" /* libpng header; includes zlib.h and setjmp.h */ -#include "maxipng.h" /* Maxicode shapes */ #endif /* NO_PNG */ +#include "maxipng.h" /* Maxicode shapes */ #include "font.h" /* Font for human readable text */