Error while building micromanager

HI
I am not able to install MM on Ubuntu 18.04.
make command fails with the message below.
Any idea what can be wrong?
Thanks.
Petro.

MicroPoint.cpp:188:32: error: non-constant-expression cannot be narrowed from type ‘int’ to ‘unsigned char’ in
initializer list [-Wc++11-narrowing]
unsigned char buf = {‘C’, (positive ? 0xc0 : 0x80), ‘C’, 0x00};
^~~~~~~~~~~~~~~~~~~~~~~~
MicroPoint.cpp:188:32: note: insert an explicit cast to silence this issue
unsigned char buf = {‘C’, (positive ? 0xc0 : 0x80), ‘C’, 0x00};
^~~~~~~~~~~~~~~~~~~~~~~~
static_cast( )
1 error generated.
Makefile:528: recipe for target ‘MicroPoint.lo’ failed
make[2]: *** [MicroPoint.lo] Error 1
make[2]: Залишаю каталог “/home/petro/mm/micromanager/DeviceAdapters/MicroPoint”
Makefile:649: recipe for target ‘all-recursive’ failed
make[1]: *** [all-recursive] Error 1
make[1]: Залишаю каталог “/home/petro/mm/micromanager/DeviceAdapters”
Makefile:521: recipe for target ‘all-recursive’ failed
make: *** [all-recursive] Error 1

Hi Peter,

It may be more productive to post this on github (https://github.com/micro-manager/micro-manager). There is a pull request there related to this issue (https://github.com/micro-manager/micro-manager/pull/725) that was merged March 16, 2020. It changes exactly the line your compiler dislikes (among others), so where did you get the source code?

Thanks, I will have a look. I wander why I got my firs post in bold font…

I can’t reproduce the error on Debian 10 using the GitHub current master commit HEAD of c4427c714:

$ ./configure --prefix=$HOME/.apps/mm --disable-java-app --silent
...
$ make -C DeviceAdapters/MicroPoint/ MicroPoint.lo 
make: Entering directory '/home/omsai/src/micro-manager/DeviceAdapters/MicroPoint'
/bin/bash ../libtool  --tag=CXX   --mode=compile clang++ -DPACKAGE_NAME=\"Micro-Manager\" -DPACKAGE_TARNAME=\"micro-manager\" -DPACKAGE_VERSION=\"1.4\" -DPACKAGE_STRING=\"Micro-Manager\ 1.4\" -DPACKAGE_BUGREPORT=\"info@micro-manager.org\" -DPACKAGE_URL=\"\" -DPACKAGE=\"micro-manager\" -DVERSION=\"1.4\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\" -DHAVE_BOOST=/\*\*/ -DHAVE_BOOST_THREAD=/\*\*/ -DHAVE_BOOST_ASIO=/\*\*/ -DHAVE_BOOST_SYSTEM=/\*\*/ -DHAVE_BOOST_CHRONO=/\*\*/ -DHAVE_BOOST_DATE_TIME=/\*\*/ -DHAVE__BOOL=1 -DHAVE_STDBOOL_H=1 -DSTDC_HEADERS=1 -DHAVE_MEMSET=1 -I.    -I/home/omsai/src/micro-manager/DeviceAdapters/../MMDevice -pthread -I/usr/include -g -O2 -MT MicroPoint.lo -MD -MP -MF .deps/MicroPoint.Tpo -c -o MicroPoint.lo MicroPoint.cpp
libtool: compile:  clang++ -DPACKAGE_NAME=\"Micro-Manager\" -DPACKAGE_TARNAME=\"micro-manager\" -DPACKAGE_VERSION=\"1.4\" "-DPACKAGE_STRING=\"Micro-Manager 1.4\"" -DPACKAGE_BUGREPORT=\"info@micro-manager.org\" -DPACKAGE_URL=\"\" -DPACKAGE=\"micro-manager\" -DVERSION=\"1.4\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\" "-DHAVE_BOOST=/**/" "-DHAVE_BOOST_THREAD=/**/" "-DHAVE_BOOST_ASIO=/**/" "-DHAVE_BOOST_SYSTEM=/**/" "-DHAVE_BOOST_CHRONO=/**/" "-DHAVE_BOOST_DATE_TIME=/**/" -DHAVE__BOOL=1 -DHAVE_STDBOOL_H=1 -DSTDC_HEADERS=1 -DHAVE_MEMSET=1 -I. -I/home/omsai/src/micro-manager/DeviceAdapters/../MMDevice -pthread -I/usr/include -g -O2 -MT MicroPoint.lo -MD -MP -MF .deps/MicroPoint.Tpo -c MicroPoint.cpp  -fPIC -DPIC -o .libs/MicroPoint.o
mv -f .deps/MicroPoint.Tpo .deps/MicroPoint.Plo
make: Leaving directory '/home/omsai/src/micro-manager/DeviceAdapters/MicroPoint'
$ clang++ --version
clang version 7.0.1-8 (tags/RELEASE_701/final)
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin

HI,
At the end everything worked after I reloaded source from Git.