null+****@clear*****
null+****@clear*****
2012年 4月 13日 (金) 17:11:38 JST
Kouhei Sutou 2012-04-13 17:11:38 +0900 (Fri, 13 Apr 2012)
New Revision: f614e7fedb674106986f34e0a90c22626ff79750
Log:
cmake: use HAVE_LIB${LIBRARY} to adjust Autoconf style
Modified files:
CMakeLists.txt
Modified: CMakeLists.txt (+4 -4)
===================================================================
--- CMakeLists.txt 2012-04-13 17:05:31 +0900 (b570e3d)
+++ CMakeLists.txt 2012-04-13 17:11:38 +0900 (1972383)
@@ -56,7 +56,7 @@ endmacro()
macro(ac_check_lib library function)
string(REGEX REPLACE "[/.]" "_" output_variable_base_name ${library})
string(TOUPPER "${output_variable_base_name}" output_variable_base_name)
- set(output_variable_name "HAVE_${output_variable_base_name}")
+ set(output_variable_name "HAVE_LIB${output_variable_base_name}")
check_library_exists(${library} ${function} "" ${output_variable_name})
if(${output_variable_name})
set(${output_variable_base_name}_LIBS "${library}")
@@ -70,7 +70,7 @@ ac_check_lib(dl dlopen)
if(UNIX)
ac_check_headers(pthread.h)
ac_check_lib(pthread pthread_mutex_init "" "")
- if(NOT ${HAVE_PTHREAD} EQUAL 1)
+ if(NOT ${HAVE_LIBPTHREAD} EQUAL 1)
message(FATAL_ERROR "No libpthread found")
endif()
endif()
@@ -78,7 +78,7 @@ endif()
option(WITH_ZLIB "use zlib for data compression." OFF)
if(WITH_ZLIB)
AC_CHECK_LIB(z compress)
- if (NOT HAVE_Z)
+ if (NOT HAVE_LIBZ)
message(FATAL_ERROR "No libz found")
endif()
endif()
@@ -86,7 +86,7 @@ endif()
option(WITH_LZO "use LZO for data compression." OFF)
if(WITH_LZO)
AC_CHECK_LIB(lzo2 lzo1_compress)
- if (NOT HAVE_LZO2)
+ if (NOT HAVE_LIBLZO2)
message(FATAL_ERROR "No liblzo2 found")
endif()
endif()