summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorvrabaud <vrabaud@google.com>2017-04-26 04:24:58 -0700
committerVictor Costan <pwnall@chromium.org>2017-06-05 13:53:29 -0700
commitc8131680d018bad83a0b0b2e2f6e49a37593c550 (patch)
tree2577f336a9b43736b684c4c92d363232f638016f /cmake
parented3b7b242bd24de2ca6750c73f64bee5b7505944 (diff)
downloadsnappy-c8131680d018bad83a0b0b2e2f6e49a37593c550.tar.gz
snappy-c8131680d018bad83a0b0b2e2f6e49a37593c550.tar.bz2
snappy-c8131680d018bad83a0b0b2e2f6e49a37593c550.zip
Provide a CMakeLists.txt.
This lands https://github.com/google/snappy/pull/29
Diffstat (limited to 'cmake')
-rw-r--r--cmake/SnappyConfig.cmake.in9
-rw-r--r--cmake/config.h.in99
2 files changed, 108 insertions, 0 deletions
diff --git a/cmake/SnappyConfig.cmake.in b/cmake/SnappyConfig.cmake.in
new file mode 100644
index 0000000..5e604fe
--- /dev/null
+++ b/cmake/SnappyConfig.cmake.in
@@ -0,0 +1,9 @@
+set(SNAPPY_VERSION @SNAPPY_MAJOR@.@SNAPPY_MINOR@.@SNAPPY_PATCHLEVEL@)
+
+@PACKAGE_INIT@
+
+set_and_check(SNAPPY_INCLUDE_DIR "@PACKAGE_INCLUDE_INSTALL_DIR@")
+set_and_check(SNAPPY_LIBRARY_DIR "@PACKAGE_LIBRARY_INSTALL_DIR@")
+set_and_check(SNAPPY_BINARY_DIR "@PACKAGE_BINARY_INSTALL_DIR@")
+
+check_required_components(SNAPPY) \ No newline at end of file
diff --git a/cmake/config.h.in b/cmake/config.h.in
new file mode 100644
index 0000000..757d031
--- /dev/null
+++ b/cmake/config.h.in
@@ -0,0 +1,99 @@
+#ifndef SNAPPY_CONFIG_H
+#define SNAPPY_CONFIG_H 1
+
+/* Define to 1 if the compiler supports __builtin_ctz and friends. */
+#cmakedefine HAVE_BUILTIN_CTZ ${HAVE_BUILTIN_CTZ}
+
+/* Define to 1 if the compiler supports __builtin_expect. */
+#cmakedefine HAVE_BUILTIN_EXPECT ${HAVE_BUILTIN_EXPECT}
+
+/* Define to 1 if you have the <byteswap.h> header file. */
+#cmakedefine HAVE_BYTESWAP_H ${HAVE_BYTESWAP_H}
+
+/* Define to 1 if you have the <dlfcn.h> header file. */
+#cmakedefine HAVE_DLFCN_H ${HAVE_DLFCN_H}
+
+/* Use the gflags package for command-line parsing. */
+#cmakedefine HAVE_GFLAGS ${HAVE_GFLAGS}
+
+/* Defined when Google Test is available. */
+#cmakedefine HAVE_GTEST ${HAVE_GTEST}
+
+/* Define to 1 if you have the <inttypes.h> header file. */
+#cmakedefine HAVE_INTTYPES_H ${HAVE_INTTYPES_H}
+
+/* Define to 1 if you have the `fastlz' library (-lfastlz). */
+#cmakedefine HAVE_LIBFASTLZ ${HAVE_LIBFASTLZ}
+
+/* Define to 1 if you have the `lzf' library (-llzf). */
+#cmakedefine HAVE_LIBLZF ${HAVE_LIBLZF}
+
+/* Define to 1 if you have the `lzo2' library (-llzo2). */
+#cmakedefine HAVE_LIBLZO2 ${HAVE_LIBLZO2}
+
+/* Define to 1 if you have the `quicklz' library (-lquicklz). */
+#cmakedefine HAVE_LIBQUICKLZ ${HAVE_LIBQUICKLZ}
+
+/* Define to 1 if you have the `z' library (-lz). */
+#cmakedefine HAVE_LIBZ ${HAVE_LIBZ}
+
+/* Define to 1 if you have the <sys/uio.h> header file. */
+#cmakedefine HAVE_SYS_UIO_H ${HAVE_SYS_UIO_H}
+
+/* Define to 1 if you have the <memory.h> header file. */
+#cmakedefine HAVE_MEMORY_H ${HAVE_MEMORY_H}
+
+/* Define to 1 if you have the <stddef.h> header file. */
+#cmakedefine HAVE_STDDEF_H ${HAVE_STDDEF_H}
+
+/* Define to 1 if you have the <stdint.h> header file. */
+#cmakedefine HAVE_STDINT_H ${HAVE_STDINT_H}
+
+/* Define to 1 if you have the <stdlib.h> header file. */
+#cmakedefine HAVE_STDLIB_H ${HAVE_STDLIB_H}
+
+/* Define to 1 if you have the <strings.h> header file. */
+#cmakedefine HAVE_STRINGS_H ${HAVE_STRINGS_H}
+
+/* Define to 1 if you have the <string.h> header file. */
+#cmakedefine HAVE_STRING_H ${HAVE_STRING_H}
+
+/* Define to 1 if you have the <sys/byteswap.h> header file. */
+#cmakedefine HAVE_SYS_BYTESWAP_H ${HAVE_SYS_BYTESWAP_H}
+
+/* Define to 1 if you have the <sys/endian.h> header file. */
+#cmakedefine HAVE_SYS_ENDIAN_H ${HAVE_SYS_ENDIAN_H}
+
+/* Define to 1 if you have the <sys/mman.h> header file. */
+#cmakedefine HAVE_SYS_MMAN_H ${HAVE_SYS_MMAN_H}
+
+/* Define to 1 if you have the <sys/resource.h> header file. */
+#cmakedefine HAVE_SYS_RESOURCE_H ${HAVE_SYS_RESOURCE_H}
+
+/* Define to 1 if you have the <sys/stat.h> header file. */
+#cmakedefine HAVE_SYS_STAT_H ${HAVE_SYS_STAT_H}
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+#cmakedefine HAVE_SYS_TIME_H ${HAVE_SYS_TIME_H}
+
+/* Define to 1 if you have the <sys/types.h> header file. */
+#cmakedefine HAVE_SYS_TYPES_H ${HAVE_SYS_TYPES}
+
+/* Define to 1 if you have the <unistd.h> header file. */
+#cmakedefine HAVE_UNISTD_H ${HAVE_UNISTD_H}
+
+/* Define to 1 if you have the <windows.h> header file. */
+#cmakedefine HAVE_WINDOWS_H ${HAVE_WINDOWS_H}
+
+/* Define to 1 if you have the ANSI C header files. */
+#define STDC_HEADERS 1
+
+/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
+ significant byte first (like Motorola and SPARC, unlike Intel and VAX). */
+#cmakedefine WORDS_BIGENDIAN
+
+#if defined(_MSC_VER) && (_MSC_VER <= 1900)
+typedef __int64 ssize_t;
+#endif
+
+#endif