[CPMD-list] Compilation of cpmd2cube
Axel Kohlmeyer
axel.kohlmeyer at theochem.ruhr-uni-bochum.de
Wed May 26 07:38:31 CEST 2004
On Tue, 25 May 2004 kohsj at ihpc.a-star.edu.sg wrote:
AK> Dr. Axel,
AK>
AK> I've used the attached "Makefile" to recompile. The following message
AK> appeared after "make" command was given:
AK>
AK>
AK> make: *** No rule to make target `kinds.F', needed by `kinds.o'. Stop.
AK>
AK>
AK> Is there anything amiss? Thanks!
no, i messed up. the makefile was from a developer version
of cpmd2cube and the files have been renamed since.
please try the attached re-redited version.
sorry for the mess,
axel.
AK>
AK>
AK> Adrian.
AK>
AK>
AK>
AK>
AK> ----- Original Message -----
AK> From: Axel Kohlmeyer <axel.kohlmeyer at theochem.ruhr-uni-bochum.de>
AK> Date: Tuesday, May 25, 2004 5:01 pm
AK> Subject: Re: [CPMD-list] Compilation of cpmd2cube
AK>
AK> On Tue, 25 May 2004 kohsj at ihpc.a-star.edu.sg wrote:
AK>
AK> AK> Dear all,
AK> AK>
AK> AK> Thank you very much for all your helpful replies. I'm using IBM
AK> p690AK> AIX 5L v.5.1 (Dr. Kohlmeyer is right). I've followed your
AK> AK> instructions to delete and replace the necessary flags, and the
AK> AK> "object files". What was left with is this:
AK>
AK> noooooo. you should delete the .o files in your compile directory not
AK> in the makesfile. hrmph, i always forget to word my replies
AK> carefully...
AK> please try the attached makefile. this is for a newer version of
AK> cpmd2cube, but it should work nevertheless
AK>
AK> axel.
AK>
AK> AK>
AK> AK> .SUFFIXES: .o .F90
AK> AK>
AK> AK> ## IBM / AIX
AK> AK> FC = xlf90
AK> AK> FFLAGS = -WF,"-D__AIX,-DFFT_ESSL" -qsuffix=cpp=F90 -O3 -
AK> qarch=pwr2 -qtune=pwr2
AK> ^^^^^^^
AK> this is the main
AK> culprit.
AK> you have a power4 cpu in your machine, yet you tell the compiler
AK> to
AK> compiler for power2 (exclusively)
AK>
AK> AK> LFLAGS = -O2 -qtune=pwr2 -bmaxdata:1500000000 -bmaxstack:1500000000
AK> ^^^^^^^^^^
AK> this is wrong but not
AK> AK> LIBS = -L/rzu/aix/lib -lessl
AK> AK> #LIBS = -L${HOME}/lib/fftw/lib -lfftw-double
AK> AK>
AK> AK> ##############
AK> AK>
AK> AK> EXE = cpmd2cube
AK> AK>
AK> AK> #############################
AK> AK>
AK> AK> $(EXE):
AK> AK> $(FC) -o $(EXE) $(LFLAGS) $(LIBS)
AK> AK>
AK> AK> .F90.o:
AK> AK> $(FC) -c $(FFLAGS) $*.F90
AK> AK>
AK> AK> clean:
AK> AK> rm -f *.o *.mod
AK> AK>
AK> AK>
AK> AK> I've removed the ones for CRAY, HITACHI etc... upon
AK> recompiling, the following message came out:
AK> AK>
AK> AK>
AK> AK> xlf90 -o cpmd2cube -O2 -qtune=pwr2 -bmaxdata:1500000000 -
AK> bmaxstack:1500000000 l
AK> AK> ld: 0711-317 ERROR: Undefined symbol: .main
AK>
AK> AK> ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain
AK> more information.
AK> AK> make: *** [cpmd2cube] Error 8
AK>
AK> AK>
AK> AK>
AK> AK>
AK> AK> What was wrong? Thanks again :).
AK> AK>
AK> AK>
AK> AK> Adrian.
AK> AK>
AK> AK>
AK> AK>
AK> AK>
AK> AK>
AK> AK> ----- Original Message -----
AK> AK> From: Axel Kohlmeyer <axel.kohlmeyer at theochem.ruhr-uni-bochum.de>
AK> AK> Date: Tuesday, May 25, 2004 3:06 pm
AK> AK> Subject: Re: [CPMD-list] Compilation of cpmd2cube
AK> AK>
AK> AK>
AK> AK> On Tue, 25 May 2004 kohsj at ihpc.a-star.edu.sg wrote:
AK> AK>
AK> AK> AK> Dear Sir,
AK> AK> AK>
AK> AK> AK> Thanks a lot for clarifying on the compilation part. I
AK> managed to
AK> AK> AK> compile the cpmd2cube by simply typing "make" within the
AK> AK> AK> "cpmd2cube-v0.1.1" folder (with no changes made to the
AK> cpmd2cubeAK> AK> "Makefile").
AK> AK> AK>
AK> AK> AK> Afterwhich, I've tried to convert the binary DENSITY file
AK> generatedAK> AK> from the h2o exercise (this is in order to display
AK> the Kohn-Sham
AK> AK> AK> Orbitals), using the following command:
AK> AK> AK>
AK> AK> AK> > ./cpmd2cube DENSITY
AK> AK> AK>
AK> AK> AK> The following error message came out:
AK> AK> AK>
AK> AK> AK> Illegal instruction (core dumped)
AK> AK>
AK> AK> that usually means you have compiled for the wrong platform.
AK> AK> my guess is, you are running on an AIX machine, right?
AK> AK>
AK> AK> if yes, please remove the -qarch=pwr2 flags,
AK> AK> replace -lesslp2 with -lessl, delete all object files,
AK> AK> and recompile.
AK> AK>
AK> AK> oh and olegs comment about havin to use -dens or -rho
AK> AK> applies as well.
AK> AK>
AK> AK> axel.
AK> AK>
AK> AK> AK>
AK> AK> AK> Why is this so? The manual (S. 10.1.2) mentioned the
AK> conversion of
AK> AK> AK> WANNIER files only, am I missing or misinterpreting
AK> anything?
AK> AK> ThanksAK> for your attention.
AK> AK> AK>
AK> AK> AK>
AK> AK> AK> Adrian
AK> AK> AK>
AK> AK>
AK> AK> --
AK> AK>
AK> AK>
AK> AK>
AK> =======================================================================AK> Dr. Axel Kohlmeyer e-mail: axel.kohlmeyer at rub.de
AK> AK> Lehrstuhl fuer Theoretische Chemie Phone: ++49
AK> (0)234/32-26673
AK> AK> Ruhr-Universitaet Bochum - NC 03/53 Fax: ++49
AK> (0)234/32-14045
AK> AK> D-44780 Bochum http://www.theochem.ruhr-uni-
AK> bochum.de/~axel.kohlmeyer/AK>
AK> =======================================================================AK>
AK> AK>
AK> AK> _______________________________________________
AK> AK> CPMD-list mailing list
AK> AK> CPMD-list at cpmd.org
AK> AK> http://www.cpmd.org/mailman/listinfo/cpmd-list
AK> AK>
AK> AK>
AK>
AK> --
AK>
AK>
AK> =======================================================================
AK> Dr. Axel Kohlmeyer e-mail: axel.kohlmeyer at rub.de
AK> Lehrstuhl fuer Theoretische Chemie Phone: ++49 (0)234/32-26673
AK> Ruhr-Universitaet Bochum - NC 03/53 Fax: ++49 (0)234/32-14045
AK> D-44780 Bochum http://www.theochem.ruhr-uni-bochum.de/~axel.kohlmeyer/
AK> =======================================================================
AK>
AK>
AK>
--
=======================================================================
Dr. Axel Kohlmeyer e-mail: axel.kohlmeyer at rub.de
Lehrstuhl fuer Theoretische Chemie Phone: ++49 (0)234/32-26673
Ruhr-Universitaet Bochum - NC 03/53 Fax: ++49 (0)234/32-14045
D-44780 Bochum http://www.theochem.ruhr-uni-bochum.de/~axel.kohlmeyer/
=======================================================================
-------------- next part --------------
#-----------------------------------------------------------------------------#
# Makefile for cpmd2cube.x
# Configuration: IBM-AIX
# Creation of Makefile: May 26 2004
# on Linux monteverdi.theochem.ruhr-uni-bochum.de 2.4.20-20.7 #1 Mon Aug 18 15:05:54 EDT 2003 i686 unknown
# Author: monteverdi.theochem.ruhr-uni-bochum.de!akohlmey
#----------------------------------------------------------------------------
#
SHELL = /bin/sh
#
#--------------- Configuration
FC = xlf90
FFLAGS = -WF,"-D__AIX,-DFFT_ESSL" -qsuffix=cpp=F90 -O -qmaxmem=32768
LFLAGS = -O -bmaxdata:32768000000 -bmaxstack:1500000000
LIBS = -lessl
#--------------- End of Configuration
##############
EXE = cpmd2cube.x
OBJECTS = \
kinds.o periodic_table.o util.o grids.o cpmd2cube.o \
main.o grid_types.o atom_types.o readwrites.o \
fftsg_lib.o fft_tools.o fftsg.o
CFGDEST = .
CFGMACH = IBM-AIX
SRC=.
VPATH = $(SRC)
#############################
$(EXE): $(OBJECTS)
$(FC) -o $(EXE) $(LFLAGS) $(OBJECTS) $(LIBS)
#############################
clean:
rm -f *.o *.mod *.L *~
# Create a new makefile with new dependencies but retain the configuration.
reconfig:
( cd $(SRC) ; ./Configure -r -m -SRC=$(SRC) -DEST=$(CFGDEST) $(CFGMACH) ; cd $(CFGDEST) )
#############################
atom_types.o: atom_types.F90
$(FC) -c $(FFLAGS) $*.F90
cpmd2cube.o: cpmd2cube.F90
$(FC) -c $(FFLAGS) $*.F90
fft_tools.o: fft_tools.F90
$(FC) -c $(FFLAGS) $*.F90
grid_types.o: grid_types.F90
$(FC) -c $(FFLAGS) $*.F90
grids.o: grids.F90
$(FC) -c $(FFLAGS) $*.F90
main.o: main.F90
$(FC) -c $(FFLAGS) $*.F90
periodic_table.o: periodic_table.F90
$(FC) -c $(FFLAGS) $*.F90
readwrites.o: readwrites.F90
$(FC) -c $(FFLAGS) $*.F90
util.o: util.F90
$(FC) -c $(FFLAGS) $*.F90
kinds.o: kinds.F90
$(FC) -c $(FFLAGS) $*.F90
fftsg.o: fftsg.F90
$(FC) -c $(FFLAGS) $*.F90
fftsg_lib.o: fftsg_lib.F90
$(FC) -c $(FFLAGS) $*.F90
# Dependencies
atom_types.o: kinds.o \
periodic_table.o
cpmd2cube.o: atom_types.o \
fft_tools.o \
grid_types.o \
grids.o \
kinds.o \
periodic_table.o \
readwrites.o \
util.o
fft_tools.o: grid_types.o \
fftsg_lib.o \
kinds.o
grid_types.o: kinds.o
grids.o: grid_types.o \
kinds.o \
util.o
main.o: cpmd2cube.o
periodic_table.o: kinds.o
readwrites.o: atom_types.o \
grid_types.o \
kinds.o
util.o: kinds.o
More information about the CPMD-list
mailing list