CompPhysVienna / n2p2

n2p2 - A Neural Network Potential Package
https://compphysvienna.github.io/n2p2/
GNU General Public License v3.0
217 stars 82 forks source link

'install' fails with target 'libnnpif' #115

Closed yurivict closed 2 years ago

yurivict commented 3 years ago

After make libnnpif make install fails:

gmake[1]: Entering directory '/disk-samsung/freebsd-ports/science/n2p2/work/n2p2-2.1.4/src'
ln -s /disk-samsung/freebsd-ports/science/n2p2/work/n2p2-2.1.4/src/../lib/libnnp.so /disk-samsung/freebsd-ports/science/n2p2/work/local/lib/libnnp.so;  ln -s /disk-samsung/freebsd-ports/science/n2p2/work/n2p2-2.1.4/src/../lib/libnnpif.so /disk-samsung/freebsd-ports/science/n2p2/work/local/lib/libnnpif.so;  ln -s /disk-samsung/freebsd-ports/science/n2p2/work/n2p2-2.1.4/src/../lib/libnnptrain.so /disk-samsung/freebsd-ports/science/n2p2/work/local/lib/libnnptrain.so;
ln: /disk-samsung/freebsd-ports/science/n2p2/work/local/lib/libnnp.so: No such file or directory
ln: /disk-samsung/freebsd-ports/science/n2p2/work/local/lib/libnnpif.so: No such file or directory
ln: /disk-samsung/freebsd-ports/science/n2p2/work/local/lib/libnnptrain.so: No such file or directory
gmake[1]: *** [makefile:191: install] Error 1

I think that this is because it's built static libs instead.

yurivict commented 3 years ago

The install target is expected to install files into $(DESTDIR)$(PREFIX). Libraries should be installed into the lib subdirectory there.

fireballpoint1 commented 2 years ago

@yurivict for my purposes i did the following :

cd src

edit makefile and change these variables to these values:

# Installation directory for binaries.
INSTALL_BIN=/usr/local/bin
Installation directory for libraries.
INSTALL_LIB=/usr/lib

You will need to run make install with sudo but the installation should be straight forward.