Another aha! Turns out that linux could successfully build the rescript repository because it was a version behind on tree-sitter (v24 instead of v25), which is also the latest version that ast-grep currently supports. Using npm to download the downgraded version of tree-sitter will let us generate a file usable by ast-grep.
npm install -g tree-sitter-cli@v0.24.7
cd desired/parent/directory/for/repo
git clone https://github.com/rescript-lang/tree-sitter-rescript
cd tree-sitter-rescript
tree-sitter build