Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix error on NetBSD #256

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion bin/env.bash
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
set -euo pipefail

system=$(uname)
if [[ $system == "Linux" ]]; then
if [[ $system == "Linux" ]] || [[ $system == "NetBSD" ]]; then
ext="so"
elif [[ $system == "Darwin" ]]; then
ext="dylib"
Expand Down
2 changes: 1 addition & 1 deletion core/tsc-dyn-get.el
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ this to nil."
(pcase system-type
('windows-nt "dll")
('darwin "dylib")
((or 'gnu 'gnu/linux 'gnu/kfreebsd) "so")
((or 'gnu 'gnu/linux 'gnu/kfreebsd 'berkeley-unix) "so")
((or 'ms-dos 'cygwin) (error "Unsupported system-type %s" system-type))
(_ "so")))

Expand Down
2 changes: 1 addition & 1 deletion lisp/tree-sitter-load.el
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ See `tree-sitter-require'.")
(pcase system-type
;; The CLI tool outputs `.so', but `.dylib' is more sensible on macOS.
('darwin (list ".dylib" ".so"))
('gnu/linux (list ".so"))
((or 'gnu 'gnu/linux 'gnu/kfreebsd 'berkeley-unix) "so")
('windows-nt (list ".dll"))
(_ (error "Unsupported system-type %s" system-type)))
"List of suffixes for shared libraries that define tree-sitter languages.")
Expand Down