ctags icon indicating copy to clipboard operation
ctags copied to clipboard

Build instructions seem incomplete - required/useful development headers not mentioned

Open phlummox opened this issue 3 years ago • 3 comments


The name of the parser: not applicable

The command line you used to run ctags:

$ ctags --help

The content of input file:

  • none

The tags output you are not satisfied with:

  • not applicable

The tags output you expect:

  • not applicable

The version of ctags:

$ ctags --version
Universal Ctags 5.9.0(80753d68), Copyright (C) 2015 Universal Ctags Team
Universal Ctags is derived from Exuberant Ctags.
Exuberant Ctags 5.8, Copyright (C) 1996-2009 Darren Hiebert
  Compiled: Jan 13 2022, 23:36:02
  URL: https://ctags.io/
  Optional compiled features: +wildcards, +regex, +gnulib_regex, +iconv, +debug, +option-directory, +xpath, +json, +interactive, +yaml, +packcc, +optscript, +pcre2

How do you get ctags binary:

Building it locally

Summary of issue

The build instructions in the README seem incomplete.

How to reproduce

  1. Install build tools (make, gcc etc) on a fresh Ubuntu 20.04 system

  2. Observe that the build instructions don't mention that for best results, header files for the libyaml, libpcre2 and libjansson files should be installed.

  3. Follow the instructions:

       $ git clone https://github.com/universal-ctags/ctags.git
       $ cd ctags
       $ ./autogen.sh
       $ ./configure --prefix=$HOME/.local
       $ make
       $ make install
    
  4. Note that in the configure output are the following lines:

    checking for LIBXML... no
    checking for JANSSON... no
    checking for LIBYAML... no
    checking for PCRE2... no
    

Expected behaviour

The install instructions should mention any libraries that are either useful or required (and ideally, say what functionality they're needed for).

Actual behaviour

The install instruction don't mention useful or required libraries.

Suggested fix

As I'm not 100% sure what functionality those libraries are used for, I can't provide a patch or pull request. But ideally, the README should mention that the libyaml, libpcre2 and libjansson header files are needed and/or useful, and why. It would be even better if it could mention how to install them on some of the most common platforms (e.g. on Ubuntu, sudo apt-get install libpcre2-dev libyaml-dev libjansson-dev.

Thanks

Thanks for your work reviving ctags - it's much appreciated!

phlummox avatar Jan 13 '22 15:01 phlummox

Pull requests are welcome!

masatake avatar Jan 13 '22 16:01 masatake

Sure. As I said, I don't know what exactly the libraries are needed for, nor how essential the functionality they provide is. (I seemed to run into problems when PCRE2 was missing, but that might also have been due to problems with my PATH after I installed.) Nevertheless, I've created a pull request here: https://github.com/universal-ctags/ctags/pull/3272.

phlummox avatar Jan 16 '22 07:01 phlummox

Thank you for making the pull request. The essential features of ctags work without these libraries. I will review #3272.

masatake avatar Jan 16 '22 07:01 masatake