Comments (9)
Hi David, good to hear from you!
I am not sure how you ran into that: looking at the code, this is only possible if the SWIG
pre-processor macro is defined. Could you attach the config.log
file please? Thanks
from xraylib.
And good to know that xraylib is alive and well. I use it all the time! -- Cheers, David
from xraylib.
Not seeing anything unusual in there at first glance.
Could you re-run your build with make V=1
? This should show the full compiler invocations.
Do you have a CFLAGS
or CPPFLAGS
environment variable set?
from xraylib.
I don't have these flags set.
MAC:~/Bmad/xraylib> make V=1
/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
/bin/sh ../libtool --tag=CC --mode=compile /opt/local/bin/gcc -DHAVE_CONFIG_H -I. -I.. -I../include -I../include -I.. -Werror=deprecated -Werror=deprecated-declarations -Werror=implicit -Werror=unused-function -Werror=parentheses -Werror=unused-result -g -O2 -MT libprdata_la-xrayfiles.lo -MD -MP -MF .deps/libprdata_la-xrayfiles.Tpo -c -o libprdata_la-xrayfiles.lo `test -f 'xrayfiles.c' || echo './'`xrayfiles.c
libtool: compile: /opt/local/bin/gcc -DHAVE_CONFIG_H -I. -I.. -I../include -I../include -I.. -Werror=deprecated -Werror=deprecated-declarations -Werror=implicit -Werror=unused-function -Werror=parentheses -Werror=unused-result -g -O2 -MT libprdata_la-xrayfiles.lo -MD -MP -MF .deps/libprdata_la-xrayfiles.Tpo -c xrayfiles.c -fno-common -DPIC -o .libs/libprdata_la-xrayfiles.o
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
from xraylib.
I am unable to reproduce this, sorry.
If you remove #ifndef SWIG
and one of the #endif
s in include/xraylib-aux.h, does compilation succeed then?
from xraylib.
No change with #ifndef SWIG
removed.
from xraylib.
Note: This is a recent issue for Mac since in the past I have not had a problem. I am using OS 14.1.2 with Xcode 15.0.1.
from xraylib.
If I remove the #ifndef _XRAYLIB_AUX_H
the compile gets further.
from xraylib.
I have been unable to reproduce this. AFAICT this looks like an issue with the preprocessor. Does switching to a different version of GCC (or LLVM/clang) make a difference?
from xraylib.
Related Issues (20)
- New language bindings for Go and Rust HOT 1
- questions about installation with meson HOT 4
- Cross-compilation issue with prdata HOT 3
- Error returned when extrapolating cross section values HOT 5
- static lib for MS VSC++
- TypeError in python bindings using numpy ints HOT 5
- Difference in #shells between xraylib and xmimsimdata.h5 HOT 3
- EdgeEnergy shell is invalid HOT 2
- Issue with python example xrlexample5.py (numpy: int64 vs int) HOT 2
- How to install xraylib package in win10? HOT 3
- Repository for Win installer can't be reached HOT 2
- lvserver packages offline HOT 1
- The photoelectric cross sections of Hydrogen HOT 3
- can't open xraylib-web, and build php failed HOT 1
- Non-zero return despite error for PM3_auger_cascade_kissel and PM4_auger_cascade_kissel HOT 2
- The value of the photoionization cross section of hydrogen at energies above 1 keV HOT 1
- How to cross-compile the xraylib code to used on Android HOT 1
- Version in PyPI HOT 10
- Failed to build with numpy v2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xraylib.