From: Joerg Sonnenberger Date: Sat, 2 Jul 2016 08:44:03 +0000 (+0200) Subject: Merge LZMA MP detection from configure. X-Git-Tag: v3.2.2~41^2~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a31edc47153a79920f295b41a8ab9238a7f93cb2;p=thirdparty%2Flibarchive.git Merge LZMA MP detection from configure. --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 648b3341c..f5917fbae 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1303,6 +1303,10 @@ CHECK_C_SOURCE_COMPILES( "#include \nint main() { return major(256); }" MAJOR_IN_SYSMACROS) +CHECK_C_SOURCE_COMPILES( + "#include \n#if LZMA_VERSION < 50020000\n#error unsupported\n#endif\nint main(void){lzma_stream_encoder_mt(0, 0); return 0;}" + HAVE_LZMA_STREAM_ENCODER_MT) + IF(HAVE_STRERROR_R) SET(HAVE_DECL_STRERROR_R 1) ENDIF(HAVE_STRERROR_R) diff --git a/build/cmake/config.h.in b/build/cmake/config.h.in index dccc3023c..e6a9c5175 100644 --- a/build/cmake/config.h.in +++ b/build/cmake/config.h.in @@ -721,6 +721,9 @@ typedef uint64_t uintmax_t; /* Define to 1 if you have the header file. */ #cmakedefine HAVE_LZMA_H 1 +/* Define to 1 if you have a working `lzma_stream_encoder_mt' function. */ +#cmakedefine HAVE_LZMA_STREAM_ENCODER_MT 1 + /* Define to 1 if you have the header file. */ #cmakedefine HAVE_LZO_LZO1X_H 1