Am Freitag 19 Oktober 2007 schrieb eddy xu: > I have not found one module to find iconv library in cmake, so I wrote one, > here is the code: > > # Find iconv library > # > # Author: Eddy Xu <[EMAIL PROTECTED]> > # > # Released under BSD license > # > # ICONV_INCLUDE_DIRS - where to find iconv.h, etc > # ICONV_LIBRARIES - Lists of libraries when using iconv > # ICONV_FOUND - True if iconv found > > > # Look for the header file > FIND_PATH( ICONV_INCLUDE_DIR NAMES iconv.h ) > MARK_AS_ADVANCED( ICONV_INCLUDE_DIR ) > > # Look for the library > FIND_LIBRARY( ICONV_LIBRARY NAMES iconv ) > MARK_AS_ADVANCED( ICONV_LIBRARY )
This is not sufficient. Iconv may also be used with GNU libc and then doesn't need an additional library. Thus, you have to test for a symbol. HS _______________________________________________ CMake mailing list [email protected] http://www.cmake.org/mailman/listinfo/cmake
