Skip to content
This repository was archived by the owner on Feb 26, 2025. It is now read-only.
This repository was archived by the owner on Feb 26, 2025. It is now read-only.

libcfu :: compilation error #58

@EricDeveaud

Description

@EricDeveaud

I'm trying to install Bamm from release tag 1.7.3 (https://github.com/Ecogenomics/BamM/archive/1.7.3.tar.gz)
on a centos-8.2 system, using gcc/9.2.0 and pythton/2.7.17

I have a compilation error while building libcfu

in order to have a smaller error log and for you to be abble to reproduce the problem
I've done the following

tar xf 1.7.3.tar.gz
cd BamM-1.7.3/c/libcfu
autoreconf -fiv
./configure
make

here is the errror I have

Making all in src
make[1]: Entering directory '/opt/gensoft/src/BamM/BamM-1.7.3/c/libcfu-0.03/src'
/opt/gensoft/exe/gcc/9.2.0/bin/gcc -DPACKAGE_NAME=\"libcfu\" -DPACKAGE_TARNAME=\"libcfu\" -DPACKAGE_VERSION=\"0.03\" -DPACKAGE_STRING=\"libcfu\ 0.03\" -DPACKAGE_BUGREPORT=\"mike@mikeimelfort.com\" -DPACKAGE_URL=\"\" -DPACKAGE=\"libcfu\" -DVERSION=\"0.03\" -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/\" -DSTDC_HEADERS=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -Dsize_t=unsigned\ int -DTIME_WITH_SYS_TIME=1 -DHAVE_STDLIB_H=1 -DHAVE_MALLOC=0 -Dmalloc=rpl_malloc -DHAVE_GETTIMEOFDAY=1 -DHAVE_MEMSET=1 -DHAVE_STRCASECMP=1 -DHAVE_STRNCASECMP=1 -I.  -I../include -I/opt/gensoft/exe/gcc/9.2.0/include -I/opt/gensoft/exe/libtool/2.4.6/include -I../include -std=gnu99 -W -pthread -g -fPIC -pthread -O2 -Wall -Wno-unused-but-set-variable -Wno-unused-function -pthread -g -O2 -MT cfuhash.o -MD -MP -MF .deps/cfuhash.Tpo -c -o cfuhash.o cfuhash.c
<command-line>: error: duplicate ‘unsigned’
<command-line>: error: two or more data types in declaration specifiers
cfuhash.c: In function ‘cfuhash_bencode_strings’:
cfuhash.c:879:28: warning: format ‘%zd’ expects argument of type ‘signed size_t’, but argument 4 has type ‘unsigned int’ [-Wformat=]
  879 |   snprintf(len_str, 32, "%zd:", (keys[i] ? strlen(keys[i]) : 0));
      |                          ~~^    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                            |                               |
      |                            long int                        unsigned int
      |                          %d
cfuhash.c:884:28: warning: format ‘%zd’ expects argument of type ‘signed size_t’, but argument 4 has type ‘unsigned int’ [-Wformat=]
  884 |   snprintf(len_str, 32, "%zd:", (val ? strlen(val) : 0));
      |                          ~~^    ~~~~~~~~~~~~~~~~~~~~~~~
      |                            |                       |
      |                            long int                unsigned int
      |                          %d
make[1]: *** [Makefile:431: cfuhash.o] Error 1

loog int vs unsigned int is not a prpble to fix using a cast, but I'm not abble to track down the duplicate unsigned error

can you help. ?

regards

Eric

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions