-
-
Notifications
You must be signed in to change notification settings - Fork 57
Open
Description
On compiling on Mac using gcc 12.3.0 I get the following error. What is the best way around this?
MAC:~/Bmad/xraylib> make
/Applications/Xcode.app/Contents/Developer/usr/bin/make all-recursive
Making all in include
make[2]: Nothing to be done for `all'.
Making all in src
CC prdata-pr_data.o
CC libprdata_la-xrayvars.lo
CC libprdata_la-xrayglob.lo
CC libprdata_la-xrayfiles.lo
xrayfiles.c: In function 'XRayInitFromPath':
xrayfiles.c:59:45: error: implicit declaration of function 'xrl_strdup'; did you mean 'strdup'? [-Werror=implicit-function-declaration]
59 | MendelArraySorted[i].name = xrl_strdup(MendelArray[i].name);
| ^~~~~~~~~~
| strdup
xrayfiles.c:59:43: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
59 | MendelArraySorted[i].name = xrl_strdup(MendelArray[i].name);
| ^
xrayfiles.c:301:32: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
301 | error_lines[0] = xrl_strdup(line_name);
| ^
xrayfiles.c:314:53: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
314 | error_lines[nerror_lines-1] = xrl_strdup(line_name);
| ^
xrayfiles.c:350:32: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
350 | error_lines[0] = xrl_strdup(shell_name);
| ^
xrayfiles.c:363:53: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
363 | error_lines[nerror_lines-1] = xrl_strdup(shell_name);
| ^
xrayfiles.c:461:32: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
461 | error_lines[0] = xrl_strdup(line_name);
| ^
xrayfiles.c:474:53: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
474 | error_lines[nerror_lines-1] = xrl_strdup(line_name);
| ^
xrayfiles.c:517:32: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
517 | error_lines[0] = xrl_strdup(auger_name);
| ^
xrayfiles.c:530:53: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
530 | error_lines[nerror_lines-1] = xrl_strdup(auger_name);
| ^
cc1: some warnings being treated as errors
make[2]: *** [libprdata_la-xrayfiles.lo] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
Metadata
Metadata
Assignees
Labels
No labels