1

I'm trying to compile emacs 28.2 (from https://ftp.gnu.org/gnu/emacs/) with json support on a Ubuntu-based system (Linux Mint). But I don't get it to work meaning that json-available-p is void and I cannot use the json-parse-string function.

I installed the libjansson-dev library and added --with-json as a parameter to configure. It shows Does Emacs use -ljansson? yes. But within emacs the json-support is not working. What else do I need or am I missing something?

dmw64
  • 155
  • 4
  • 1
    @phils Ohh, yes! Thanks. I updated the problem ;-) – dmw64 Nov 30 '22 at 10:15
  • When you do `ldd \`which emacs\` | grep jans` does libjansson show up? If not, you're going to have to recompile. – g-gundam Nov 30 '22 at 14:17
  • Also, out of curiosity, what happens when you do `(require 'json)` in your current emacs? – g-gundam Nov 30 '22 at 14:21
  • @g-gundam No, `ldd `which emacs` | grep jans` is empty. Not sure why since configure showing jansson to be used... Using `(require 'json)` does not complain and returns `json`. – dmw64 Dec 01 '22 at 08:22
  • How did you start Emacs. Are you sure that you are using the newly built Emacs? – dalanicolai Dec 01 '22 at 09:40
  • Yeah, do `emacs --version` to make sure you're running the right one. You can verify build settings with `emacs -nw -q --batch --eval '(message system-configuration-options)'` too. – g-gundam Dec 01 '22 at 15:37

0 Answers0