aboutsummaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorThomas Vigouroux <tomvig38@gmail.com>2020-09-17 11:25:22 +0200
committerThomas Vigouroux <tomvig38@gmail.com>2020-11-03 10:39:35 +0100
commit3eb241d8310f453ce5e5485f12796a0ae43a0a18 (patch)
treefa214d8724a4c3d3646b1c1c5e12137757464d6f /cmake
parenta061d53e18168130aad537a9e8012390834ff8c2 (diff)
downloadrneovim-3eb241d8310f453ce5e5485f12796a0ae43a0a18.tar.gz
rneovim-3eb241d8310f453ce5e5485f12796a0ae43a0a18.tar.bz2
rneovim-3eb241d8310f453ce5e5485f12796a0ae43a0a18.zip
bundle: move tree-sitter as a bundled dep
fixup! bundle: move tree-sitter as a bundled dep fixup! bundle: move tree-sitter as a bundled dep
Diffstat (limited to 'cmake')
-rw-r--r--cmake/FindTreesitter.cmake11
1 files changed, 11 insertions, 0 deletions
diff --git a/cmake/FindTreesitter.cmake b/cmake/FindTreesitter.cmake
new file mode 100644
index 0000000000..8ba3b72d28
--- /dev/null
+++ b/cmake/FindTreesitter.cmake
@@ -0,0 +1,11 @@
+# - Try to find tree-sitter
+# Once done, this will define
+#
+# TREESITTER_FOUND - system has tree-sitter
+# TREESITTER_INCLUDE_DIRS - the tree-sitter include directories
+# TREESITTER_LIBRARIES - link these to use tree-sitter
+
+include(LibFindMacros)
+
+libfind_pkg_detect(TREESITTER tree-sitter FIND_PATH tree_sitter/api.h FIND_LIBRARY tree-sitter)
+libfind_process(TREESITTER)