2

I was try to installing watchman on Ubuntu 19.10 but it throwing some issues.

My commands:

$ cd ~

$ git clone https://github.com/facebook/watchman.git

$ cd watchman/

$ git checkout v4.9.0

$ sudo apt-get install -y autoconf automake build-essential
python-dev

$ ./autogen.sh 

$ ./configure 

$ make

$ sudo make install$ watchman --version

Issues:

    scm/Mercurial.cpp: In constructor ‘watchman::Mercurial::infoCache::infoCache(std::string)’:
scm/Mercurial.cpp:16:40: error: ‘void* memset(void*, int, size_t)’ clearing an object of non-trivial type ‘struct watchman::FileInformation’; use assignment or value-initialization instead [-Werror=class-memaccess]
   16 |   memset(&dirstate, 0, sizeof(dirstate));
      |                                        ^
In file included from scm/Mercurial.h:10,
                 from scm/Mercurial.cpp:3:
./FileInformation.h:18:8: note: ‘struct watchman::FileInformation’ declared here
   18 | struct FileInformation {
      |        ^~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
make[1]: *** [Makefile:4446: scm/watchman-Mercurial.o] Error 1
make[1]: Leaving directory '/home/elavarasan/watchman-4.9.0'
make: *** [Makefile:1264: all] Error 2

Expecting: the watchman install successfully. watchman version 4.9.0

0

1 Answer 1

3

Running

./configure --without-python --without-pcre --enable-lenient

before make will do the trick.
I found the answer in this AskUbuntu question.

Not the answer you're looking for? Browse other questions tagged or ask your own question.