Comments (4)
I found gcc works well by the definition: FC=ifort CC=icc CXX=icpc. Does it mean that gcc can not compile the project?
If I install dftd4-python in /home/gp/anaconda3, "from dftd4.ase import DFTD4" will cause:
Traceback (most recent call last):
File "/home/gp/anaconda3/lib/python3.7/site-packages/dftd4/libdftd4.py", line 32, in
from ._libdftd4 import ffi, lib
ImportError: /home/gp/anaconda3/lib/python3.7/site-packages/dftd4/libdftd4.cpython-37m-x86_64-linux-gnu.so: undefined symbol: iso_c_binding_mp_c_null_ptrDuring handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "", line 1, in
File "/home/gp/anaconda3/lib/python3.7/site-packages/dftd4/ase.py", line 86, in
from .interface import DispersionModel, DampingParam
File "/home/gp/anaconda3/lib/python3.7/site-packages/dftd4/interface.py", line 22, in
from .libdftd4 import (
File "/home/gp/anaconda3/lib/python3.7/site-packages/dftd4/libdftd4.py", line 34, in
raise ImportError("dftd4 C extension unimportable, cannot use C-API")
ImportError: dftd4 C extension unimportable, cannot use C-API
If I install dftd4-python in other paths, "from dftd4.ase import DFTD4" will cause:
Traceback (most recent call last):
File "", line 1, in
ModuleNotFoundError: No module named 'dftd4'
Conda does not finish install because of the inconsistent libs, pip has compilation errors.
How could I install dftd4-python correctly?
from dftd4.
meson setup _build -Dpython_version=3 -Dfortran_link_args=-qopenmp
The option -qopenmp
is specific to Intel Fortran compilers, especially adding the option -Dfortran_link_args=-qopenmp
to the configuration step is only required when building against the MKL with Intel 2021. Note that you must build against the MKL-RT library to build a Python extension module, therefore this option is not needed here.
ImportError: /home/gp/anaconda3/lib/python3.7/site-packages/dftd4/libdftd4.cpython-37m-x86_64-linux-gnu.so: undefined symbol: iso_c_binding_mp_c_null_ptr
It looks like you are mixing up an Intel compiled binary with a GCC compiled binary, the Fortran runtime will mismatch and therefore you can't find the required symbols. It is important to use the matching C compiler to compile the Python extension module you used for compiling the Fortran library.
from dftd4.
Thank you, Sebastian. It should be because that my compiler configuration was confused as you wrote. I am trying to correct it.
from dftd4.
The build system from DFT-D4 got several improvements since this issue was opened. Feel free to open a new issue if this is still relevant.
from dftd4.
Related Issues (20)
- Bug in poscar parser with single character/number in lines HOT 1
- vasp6.4.1+dftd4 compiled error HOT 1
- Error in OMP parallelized parts HOT 2
- Build fails: meson-python: error: The dftd4 package is split between purelib and platlib: 'purelib/dftd4/__init__.py' and 'platlib/dftd4/_libdftd4.cpython-39.so', a "pure: false" argument may be missing in meson.build. It is recommended to set it in "import('python').find_installation()" HOT 1
- The 3.6.0 release isn't on PYPI HOT 4
- Failed to build VASP 6.2.1 with DFT-D4 3.6.0 using ifort 2023.1.0 HOT 2
- Failed to link targets when building VASP+DFTD4 HOT 5
- Segfault when structure is large HOT 4
- Segfault when above ~700 atoms using ASE HOT 5
- Add r2SCAN-3c and wB97X-3c parameters HOT 3
- Do vasp implementations of DFT-D3 and D4 contain the ATM three-body term? HOT 2
- Non-zero D4 interaction energy in dissociation limit HOT 7
- Spurious forces for PdAg system HOT 3
- Changes from older version of dftd4 HOT 1
- Duplicate `-qopenmp` flag in dftd4.pc file. HOT 4
- Inquiry on Fortran Compiler Version Matching Requirements for Building Vasp with dftd4 Support. HOT 1
- About the `Skipped` testing examples. HOT 1
- About the directory `libdftd4.a.p`. HOT 1
- Applying vdW Dispersion Correction in DFPT Calculations with DFT-D4. HOT 1
- ld is unable to find library during linking process
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 dftd4.