CacheLib icon indicating copy to clipboard operation
CacheLib copied to clipboard

ERROR: flag 'logtostderr' was defined more than once

Open KYUNGSOO-LEE opened this issue 2 years ago • 3 comments

I built cachelib. Below was my development environment.

  • Cachelib Ver: v2023.01.16.00
  • OS: Ubuntu 16.04
  • Build Command: ./contrib/build.sh -d -j -v -T
  1. I ran unit tests code with command "nice make -j". Running error is occurred in some unit tests, e,g. "shm-test-test_shm", "benchmark-test-BucketMutexBecnch". The error message: ERROR: flag 'logtostderr' was defined more than once (in files '/data/scott/programs/CacheLib/cachelib/external/glog/src/logging.cc' and 'src/logging.cc').

  2. I built the examples code, e.g. simple_cache with "./built.sh". I ran the example, ./build/simple_cache. The error message: ERROR: flag 'logtostderr' was defined more than once (in files '/data/scott/programs/CacheLib/cachelib/external/glog/src/logging.cc' and 'src/logging.cc').

How can I fix it?

KYUNGSOO-LEE avatar Jan 18 '23 06:01 KYUNGSOO-LEE

We don't support ubuntu 16.04. If you could, please update to Ubuntu 18.04 or newer. Your logs seem to suggest you're pulling in two separate glog installation as dependencies. Can you provide more details on what is this src/logging.cc?

therealgymmy avatar Jan 31 '23 19:01 therealgymmy

I'm sorry. It was a typo. OS version is 20.04. "logging.cc" is only one in Cachelib. There is "cachelib/external/glog/src/logging.cc". I think logging.cc is crashed during dynamic linking. This error is not occurred in release mode compiling.

KYUNGSOO-LEE avatar Jan 31 '23 23:01 KYUNGSOO-LEE

I'm sorry. It was a typo. OS version is 20.04. "logging.cc" is only one in Cachelib. There is "cachelib/external/glog/src/logging.cc". I think logging.cc is crashed during dynamic linking. This error is not occurred in release mode compiling.

Did you solve it?I met the same problem

zzzzq-0000 avatar Mar 15 '23 07:03 zzzzq-0000