【问题现象】
root@localhost src]# make VERBOSE=1
* Make Target is all
##### Making Directory /path/to/glimmer3.02/src/Common all #####
make[1]: Entering directory '/path/to/glimmer3.02/src/Common'
@@@@@@@@@@@@@@@@@@@ delcher.cc @@@@@@@@@@@@@@@@@@@@@
In file included from <built-in>:405:
<command line>:1:9: warning: '__cplusplus' macro redefined [-Wmacro-redefined]
#define __cplusplus 1
^
<built-in>:400:9: note: previous definition is here
#define __cplusplus 201402L
^
delcher.cc:284:8: error: use of undeclared identifier 'strlen'
n = strlen (s);
^
delcher.cc:404:10: error: use of undeclared identifier 'strlen'
len = strlen (s);
^
1 warning and 2 errors generated.
make[1]: *** [/path/to/glimmer3.02/src/c_make.gen:328: delcher.o] Error 1
make[1]: Leaving directory '/path/to/glimmer3.02/src/Common'
##### Making Directory /path/to/glimmer3.02/src/ICM all #####
make[1]: Entering directory '/path/to/glimmer3.02/src/ICM'
@@@@@@@@@@@@@@@@@@@ icm.cc @@@@@@@@@@@@@@@@@@@@@
【解决办法】
delcher.hh中头文件包含将#include <string>修改成#include <string.h>
【END】
如有疑问,欢迎评论区留言讨论~
【问题现象】
root@localhost src]# make VERBOSE=1
* Make Target is all
##### Making Directory /path/to/glimmer3.02/src/Common all #####
make[1]: Entering directory '/path/to/glimmer3.02/src/Common'
@@@@@@@@@@@@@@@@@@@ delcher.cc @@@@@@@@@@@@@@@@@@@@@
In file included from <built-in>:405:
<command line>:1:9: warning: '__cplusplus' macro redefined [-Wmacro-redefined]
#define __cplusplus 1
^
<built-in>:400:9: note: previous definition is here
#define __cplusplus 201402L
^
delcher.cc:284:8: error: use of undeclared identifier 'strlen'
n = strlen (s);
^
delcher.cc:404:10: error: use of undeclared identifier 'strlen'
len = strlen (s);
^
1 warning and 2 errors generated.
make[1]: *** [/path/to/glimmer3.02/src/c_make.gen:328: delcher.o] Error 1
make[1]: Leaving directory '/path/to/glimmer3.02/src/Common'
##### Making Directory /path/to/glimmer3.02/src/ICM all #####
make[1]: Entering directory '/path/to/glimmer3.02/src/ICM'
@@@@@@@@@@@@@@@@@@@ icm.cc @@@@@@@@@@@@@@@@@@@@@
【解决办法】
delcher.hh中头文件包含将#include <string>修改成#include <string.h>
【END】
如有疑问,欢迎评论区留言讨论~