From: Alan W. I. <ir...@be...> - 2006-05-15 08:31:53
|
On 2006-05-15 14:20+0900 Valery Pipin wrote: > After export F77=3Dgfortran export FC=3Dgfortran and > export F77FLAGS=3D'-O3' export FCFLAGS=3D'-O3' > > I've get > /bin/sh ../../libtool --mode=3Dcompile gfortran -I. -O3 -c -o sfstubsf95.= lo > sfstubsf95.f95 > gfortran -I. -O3 -c sfstubsf95.f95 -fPIC -o .libs/sfstubsf95.o > In file sfstubsf95.f95:69 > > module plplot > 1 > In file sfstubs.f95:227 > > Included at sfstubsf95.f95:66 > > common /plplot/ tr > 2 > Error: Global name 'plplot' at (1) is already being used as a COMMON at (= 2) > make[4]: *** [sfstubsf95.lo] =EF=DB=C9=C2=CB=C1 1 > > Then I replaced the corresponding name of common block in sfstubs.f95 > from common /plplot/ to common /plplot1/. > After this compilation and checks for f95 goes smoothly. Good. That makes four (actually probably five) platforms where gfortran is working. I have just now put in a similar fix for the nameclash into CVS i= n response to somebody else's report on the plplot-devel list. When it becomes available for anon cvs (bindings/f95/sfstubs.f and some of the fortran 95 examples should change), please try it out. > The common blocks is obsolete in F90-95. I would recommend to use > "USE" . Noted, but not implemented yet. I would like to change this whole area of the API to use proper callbacks (where the API of the function or subroutin= e name being passed as an argument of the library routine is fully specified)= =2E Is this C-like approach available in fortran 95 (perhaps with the interface statement)? If so, then a number of different routines (e.g., plcon0, plcon1, etc) could be replaced by one routine (plcont) in the fortran 95 interface, and there will be no more need for the common block. > This experiment was on altlinux where we have gfortran-4.1. I shall chec= k my > dapper part this afternoon. > > For intel fortran I've get the linkage error: > /bin/sh ../../libtool --mode=3Dlink ifort -I. -O3 -o =2E... I don't want to discourage you; your experiments with ifort may eventually pay off. However, from what I have heard from the libtool experts, we are limited to just gfortran for now because libtool is not yet ready for full fortran 9x support. Once libtool is improved in this respect (hopefully within a few months from now), then the plplot fortran 95 interface should be able to support commercial fortran compilers such as ifort, pgf90, and the absoft fortran compiler. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); PLplot scientific plotting software package (plplot.org); the Yorick front-end to PLplot (yplot.sf.net); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ |