[Pw_forum] Re: [Pw forum] problem with compilation

Bachir Bouhafs bbouhafs at mail.com
Tue Sep 2 13:01:18 CEST 2003


Dear Sergey,
I still have problem with pwscf compilation, at the end of the output
of the make pw command, I get the following message:
In function cft_3
undefined reference to 'fftw_f77'
undefined reference to 'fftw_f77_create_plan'
In function cft_1
undefined reference to 'fftw_f77'
undefined reference to 'fftw_f77_create_plan'
In function cft_1s
undefined reference to 'fftw_f77'
undefined reference to 'fftw_f77_create_plan'
In function cft_2
undefined reference to 'fftw_f77'
undefined reference to 'fftw_f77_create_plan'
In function cft_2s
undefined reference to 'fftw_f77'
undefined reference to 'fftw_f77_create_plan'

also 
In function dscal
'__READFILE_NEW_in_RESTART_MODULE'


> What version did you download ? if fftw 3.something - bad idea,
use
> FFTW 2.1.5.
I have download the FFTW 2.1.5. version form www.fftw.org

>	 Have you succesfully compiled the FFTW package on your
machine?
Yes, the compliation was succesfull

>	 What is the result of	" nm /usr/local/lib/libfftw.a |
grep f77 "?
The result is as follows:

fftwf77.o:
000001d0 T fftw2d_f77_create_plan__
00000210 T fftw3d_f77_create_plan__
00000060 T fftw_f77__
00000000 T fftw_f77_create_plan__
00000040 T fftw_f77_destroy_plan__
000000b0 T fftw_f77_one__
00000280 T fftwnd_f77__
00000120 T fftwnd_f77_create_plan__
00000260 T fftwnd_f77_destroy_plan__
000002d0 T fftwnd_f77_one__

> (replace /usr/local/lib/ with  the name of the directory where
you
> installed the libfftw.a library)
Why may I replace this??

best regards
Bachir

----- Original Message -----
From: sprokuda at dnk.ru
Date: Mon, 1 Sep 2003 10:20:49 +0400
To: Bachir Bouhafs <pw forum at pwscf.org>
Subject: Re: [Pw forum] problem with compilation

> Dear Bachir!
> What version did you download ? if fftw 3.something - bad idea, use
> FFTW 2.1.5.
> I had just the same problem with a couple of weeks ago.
> As for the rest - ( undercores and manner of compiler to call the
> function) - see the manual. and a bit more ( the replies were given to
> me on the same problem)  :
> 1)
>     FFTW is written in C but fortran wrappers are also included.
> 
>     Have you succesfully compiled the FFTW package on your machine?
>     What is the result of  " nm /usr/local/lib/libfftw.a | grep f77 "?
> (replace /usr/local/lib/ with  the name of the directory where you
> installed the libfftw.a library)
>  
>     Different f77 compilers use different name convenctions in order to 
> call routines (lowercase,uppercase, add_one_underscore, 
> add_two_underscores...), the "configure" step of fftw figures out what 
> is your f77 compiler
> and use g77 if nothing else applies.
>     If you have a fortran compiler which is not in the list checked by
> the configure script, after the configure step but before actually 
> compiling the library (with the make command), you may need to edit the 
> fftw/config.h  file, look for the string
> /*********************** fortran wrapper configuration 
> *********************/
> and set the values appropriated for you fortran compiler.
> 
> In any case if you succesfully compiled the package, no matter which f77 
> compiler the configure script found,
> the "nm /usr/local/lib/libfftw.a | grep f77 " should find something.
> Then you only need to discover how your fortran compiler likes to call 
> routines (for instance by "nm pwscf.o"),  set  the fftw/config.h
> parameters accordingly and repeat the installation
> 
> 2)
>  First you have to download FFTW-sources
> (v.2.1.3) from www.fftw.org or www.netlib.org. Please
> be careful do not download the 3.0 version. It is not
> incompatible for the code. 
> 
> Then unpack it and go to the directory
> /your_FFTW_dir/fftw and edit the config.h file. At the
> end of the file please find lines which look the next
> ones (as should be). A line should be commented out. 
> 
> /* #undef FFTW_FORTRANIZE_LOWERCASE */
> #define FFTW_FORTRANIZE_LOWERCASE_UNDERSCORE 1
> /* #undef FFTW_FORTRANIZE_UPPERCASE */
> /* #undef FFTW_FORTRANIZE_UPPERCASE_UNDERSCORE */
> 
> Then just press "configure", "make", "make install".
> The last, you should link the fftw-bibrary you are
> being installed before the MKL one, i.e. -lfftw
> -lMKL..
> 
> Probably the above mentioned procedure is not required
> for the v.1.2 (PWSCF), but you have to check it.   
> 
> Exactly you do not need the FFTW.3.0 version and you
> can remove it. 
> 
> ALT Linux is RedHat based one, so it should work good.
> Your troubles go to FFTW.3.0. 
> 
> Any question, please let me know.
> 
> 
> regards, Sergey.
> 
> 
> _______________________________________________
> Pw_forum mailing list
> Pw_forum at pwscf.org
> http://www.democritos.it/mailman/listinfo/pw_forum



Dr. Bachir Bouhafs
Physics Department
University of Sidi Bel Abbes
22000 Sidi Bel Abbes, Algeria
Mobil:+213 (0)71 18 21 47
Fax:+213 48 54 11 52 
E-mail: bbouhafs at mail.com

-- 
__________________________________________________________
Sign-up for your own personalized E-mail at Mail.com
http://www.mail.com/?sr=signup

CareerBuilder.com has over 400,000 jobs. Be smarter about your job search
http://corp.mail.com/careers




More information about the users mailing list