Trying to test while configuring. But failed every time.

option, parallelism,...

Moderators: fgoudreault, mcote

Forum rules
Please have a look at ~abinit/doc/config/build-config.ac in the source package for detailed and up-to-date information about the configuration of Abinit 8 builds.
For a video explanation on how to build Abinit 7.x for Linux, please go to: http://www.youtube.com/watch?v=DppLQ-KQA68.
IMPORTANT: when an answer solves your problem, please check the little green V-like button on its upper-right corner to accept it.
Locked
Rommel
Posts: 6
Joined: Mon Oct 31, 2016 9:22 am

Trying to test while configuring. But failed every time.

Post by Rommel » Tue Nov 01, 2016 6:46 am

I tried to run test using ./runtests.py

But the following message came up. Do not know how to resolve this issue. Someone gave a solution to a similar problem in a different thread. But either I did not understand or may be his solution does not work. Please help me.

:':
''''
'''':
'''';
''''''
'''''' ,`
'`,'''' ::
:' '''' ::.
' '''' :::,
'' '''', ::::
' ''''' ::::,
`, '` :'''' .:::::
;;, ;' '''' :'` `:::::.
';;; ' ''''` ;'''` ,::::::
;;;;;: '' ''''' ' ''''':::::.
;;;;;;;, .' '''' ,' `:;:'''';, ''
';;;;;;;;':` ``:';;;;;;;;:, ''; ''
,';;;;;;;;;;;;;;;;;;;;;;;;;;;;;':,` ''
`.,:::;;;:::,,.` ,' .;;` : , ,, : ''
.+ `'''' ,'`'''''' ' '.'''''' ' ''''''
'' ;'''' ,''' '' ' '''` '' ' ''
'' ''''' ,'' '' ' '' '' ' ''
', ,: ,' `' ' '' :' ' ''
'' ,' ' ' '. ' ' ''
:' ' ' ' '. ' ' ''
'' '. ;' ' '. ' ' ''
'' '' '; ' '. ' ' ''
'. ''' ''' ' '. ' ' ,',
'' ;'''': ' '. ' ' ''';
''
': : . `````````
'' `,' `:::::::::::::::::::::::,`
; `:;;;;;;;:' .,::::::::
.;;;;;;:. , ' `:::::.
.;;;;;:` .+; :::,
:;;;;:` ,:`
:;;;;. ..
;;;;,
;;;;`
.;;;
:;;
;.
;

Running on nissar-HP-ProBook-4540s -- system Linux -- ncpus 4 -- Python 2.7.12+ -- runtests.py-0.5.2
Traceback (most recent call last):
File "./runtests.py", line 606, in <module>
sys.exit(main())
File "./runtests.py", line 375, in main
build_env = BuildEnvironment(build_dir_path)
File "/home/nissar/Documents/Program/abinit-8.0.8/tests/pymods/testsuite.py", line 957, in __init__
build_dir = find_top_build_tree(build_dir)
File "/home/nissar/Documents/Program/abinit-8.0.8/tests/pymods/testsuite.py", line 783, in find_top_build_tree
raise RuntimeError("Cannot find the ABINIT build tree after %s trials" % ntrials)
RuntimeError: Cannot find the ABINIT build tree after 10 trials

User avatar
gmatteo
Posts: 291
Joined: Sun Aug 16, 2009 5:40 pm

Re: Trying to test while configuring. But failed every time.

Post by gmatteo » Tue Nov 01, 2016 9:04 am

runtests.py cannot find the abinit executable in /home/nissar/Documents/Program/abinit-8.0.8/src/98_main/abinit

If you have build the code in a different directory e.g. in /home/nissar/Documents/Program/abinit-8.0.8/tmp
cd to tmp/tests with

cd /home/nissar/Documents/Program/abinit-8.0.8/tmp/tests

and run the script with

../../tests/runtests,py --help

Rommel
Posts: 6
Joined: Mon Oct 31, 2016 9:22 am

Re: Trying to test while configuring. But failed every time.

Post by Rommel » Wed Nov 02, 2016 5:50 am

I have the runtest.py file in /home/nissar/Documents/Program/abinit-8.0.8/tests directory. Though I opened a build directory under abinit-8.0.8 directory and inside the build directory somehow another test directory has been created which do not have runtest.py file. But still do not know how to link it with the executable file. I am new in Ubuntu and seek your help in this regard.

User avatar
gmatteo
Posts: 291
Joined: Sun Aug 16, 2009 5:40 pm

Re: Trying to test while configuring. But failed every time.

Post by gmatteo » Wed Nov 02, 2016 9:58 am

Though I opened a build directory under abinit-8.0.8 directory and inside the build directory somehow another test directory has been created which do not have runtest.py file


Right, the build directory does not contain runtests.py but the script is available in /home/nissar/Documents/Program/abinit-8.0.8/tests/runtests.py
and you can execute it provided that you specify its relative path (relative wrt to the directory in which you are working).
Your directory tree looks like:

abinit_home/
├── build
│   └── tests
└── tests
└── runtests.py


where build is the directory in which you have compiled abinit.
Open the terminal and go to abinit_home/build/tests i.e. the tests directory that does not contain runtests.py
Now you can invoke the python script in abinit_home/tests/ by typing:

../../tests/runtests.py

that corresponds to the absolute path abinit_home/tests/runtests.py
(/home/nissar/Documents/Program/abinit-8.0.8/tests/runtests.py in your particular case)

Rommel
Posts: 6
Joined: Mon Oct 31, 2016 9:22 am

Re: Trying to test while configuring. But failed every time.

Post by Rommel » Fri Nov 04, 2016 11:05 am

Thank you sir.

I ran tests by ./runtests.py -j 4 fast and ./runtests.py paral -n 2 -j 2.

Looks successful since it shows 11 succeeded.

I went to the abinit_home/build/src/98_main and wrote `make install`

I found the following errors: Makefile:3393: recipe for target 'install-binPROGRAMS' failed
make[1]: *** [install-binPROGRAMS] Error 1
make[1]: Leaving directory '/home/nissar/Documents/Program/abinit-8.0.8/build/src/98_main'
Makefile:3726: recipe for target 'install-am' failed
make: *** [install-am] Error 2

Is it a problem?
How to solve it?

User avatar
gmatteo
Posts: 291
Joined: Sun Aug 16, 2009 5:40 pm

Re: Trying to test while configuring. But failed every time.

Post by gmatteo » Sat Nov 05, 2016 10:33 am

make install should be executed in /home/nissar/Documents/Program/abinit-8.0.8/build/src.
You may need to use `sudo make install` if the executables and other files are installed in directories
for which you need root privileges (this is the usual case if you haven't specified the installation directory with configure --prefix=DIRPATH)

Rommel
Posts: 6
Joined: Mon Oct 31, 2016 9:22 am

Re: Trying to test while configuring. But failed every time.

Post by Rommel » Mon Nov 07, 2016 3:14 am

Thank you sir. At the same time I apologize for taking lot of your time.

After I went to abinit8.0.8/build/src I typed sudo make install.

But it is showing the following error.

use netcdf
1
Fatal Error: Can't open module file ‘netcdf.mod’ for reading at (1): No such file or directory
compilation terminated.
Makefile:922: recipe for target 'm_errors.o' failed
make[1]: *** [m_errors.o] Error 1
make[1]: Leaving directory '/home/nissar/Documents/Program/abinit-8.0.8/build/src/16_hideleave'
Makefile:930: recipe for target 'install-recursive' failed
make: *** [install-recursive] Error 1

How to solve it?

User avatar
pouillon
Posts: 651
Joined: Wed Aug 19, 2009 10:08 am
Location: Spain
Contact:

Re: Trying to test while configuring. But failed every time.

Post by pouillon » Thu Nov 24, 2016 12:05 pm

Just install NetCDF on your computer and make sure you have the Fortran module. It should be in /usr/include after installation.
Yann Pouillon
Simune Atomistics
Donostia-San Sebastián, Spain

Locked