Skip to content
Browse files

Fix compilation error on F16; make zlib optional.

  • Loading branch information...
1 parent 07f75d7 commit d76f4954d1554114d53f4949e585d7b7f43b2465 @davidmoreno committed Jan 10, 2012
Showing with 5 additions and 1 deletion.
  1. +1 −0 CMakeLists.txt
  2. +4 −1 examples/ofileserver/CMakeLists.txt
View
1 CMakeLists.txt
@@ -54,6 +54,7 @@ endif(${ONION_USE_PTHREADS})
if (${ONION_USE_XML2})
find_library(XML2_LIB NAMES xml2 PATH ${LIBPATH})
+ find_library(Z_LIB NAMES z PATH ${LIBPATH})
find_path(XML2_HEADERS NAMES libxml/xmlwriter.h HINTS ${INCLUDE_PATH} PATH_SUFFIXES libxml2)
if(XML2_HEADERS)
message(STATUS "libxml2 found. WebDAV support is compiled in.")
View
5 examples/ofileserver/CMakeLists.txt
@@ -41,7 +41,10 @@ endif(HAVE_MSGFMT)
add_executable(ofileserver fileserver.c fileserver_html.c)
-target_link_libraries(ofileserver onion_handlers_static onion_static z m )
+target_link_libraries(ofileserver onion_handlers_static onion_static m )
+if (${Z_LIB})
+ target_link_libraries(ofileserver ${Z_LIB})
+endif(${Z_LIB})
install(TARGETS ofileserver DESTINATION ${BINDIR})

0 comments on commit d76f495

Please sign in to comment.
Something went wrong with that request. Please try again.