Skip to content

Instantly share code, notes, and snippets.

@sogaiu
Last active July 17, 2025 06:52
Show Gist options
  • Save sogaiu/c4075a1220a31ba9df838f9be5a4484f to your computer and use it in GitHub Desktop.
Save sogaiu/c4075a1220a31ba9df838f9be5a4484f to your computer and use it in GitHub Desktop.
building janet
  • prefer per-user install

  • prefer Makefile (meson is supported but is less exercised)

  • build prep with meson can be useful to end up with compile_commands.json for lsp-ish purposes. though after running meson appropriately (see below), making a symlink of the same name that points to the build/compile_commands.json file may be a good idea.

  • if doing meson:

    meson setup build \
          --buildtype release \
          --optimization 2 \
          --libdir /usr/local/lib \
          -Dgit_hash=$(git log --pretty=format:'%h' -n 1)
    

    via: https://github.com/janet-lang/janet#meson

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment