Hi,
 I am running cmake version 2.4.7.
grep -i kpic /usr/share/cmake-2.4/Modules/Platform/* came back empty. 
I do not have FFLAGS or CCFLAGS set. 
I set export FC='ifort -O2" before calling cmake in a new build directory as 
suggested in the installation instructions. 
  Doing a grep check on the build tree, I found that -KPIC was set as an option 
to ifort in the link.txt, relink.txt and flags.make files in the 
bindings/f77/CMakefiles/plplotf77d.dir/ and 
bindings/f95/CMakefiles/plplotf95d.dir/ subdirectories. I did a new build and 
changed -KPIC to -fPIC in those files, and the compilation and install ran 
cleanly. 
I would like to thank you for your assistance in getting this to work.
Recif 

--- On Thu, 7/10/08, Alan W. Irwin <[EMAIL PROTECTED]> wrote:

> From: Alan W. Irwin <[EMAIL PROTECTED]>
> Subject: Re: [Plplot-general] Problems compiling plplot-5.9.0
> To: "R C" <[EMAIL PROTECTED]>
> Cc: plplot-general@lists.sourceforge.net
> Date: Thursday, July 10, 2008, 5:57 PM
> Hi Recif:
> 
> On 2008-07-10 05:28-0700 R C wrote:
> 
> > Hi,
> > Installing python-gnome2-dev fixed the compilation
> problem.
> 
> Good.
> 
> > However, 'make install' seemed to warn about
> the -K option to ifort. As I
> had mentioned in my earlier email, I changed the -KPIC flag
> to -fPIC in a
> couple of places
> (bindings/f77/CMakefiles/plplotf77d.dir/flags.make and
> bindings/f95/CMakefiles/plplotf95d.dir/flags.make). Are
> there other files I
> need to modify?
> 
> I think to cure the symptom you will have to use find and
> grep a lot in the
> build tree to search for -KPIC.
> 
> However, I don't understand why your Ubuntu system is
> using -KPIC at all.
> 
> Here are all the possibilities where that flag might be set
> on my Debian
> testing version of cmake (2.4.8).
> 
> grep -i kpic /usr/share/cmake-2.4/Modules/Platform/*.cmake
> /usr/share/cmake-2.4/Modules/Platform/SCO_SV.cmake:SET(CMAKE_SHARED_LIBRARY_C_FLAGS
> "-Kpic -belf")
> /usr/share/cmake-2.4/Modules/Platform/SCO_SV.cmake:SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS
> "-Kpic -belf")
> /usr/share/cmake-2.4/Modules/Platform/SunOS.cmake:
> SET(CMAKE_SHARED_LIBRARY_C_FLAGS "-KPIC") 
> /usr/share/cmake-2.4/Modules/Platform/SunOS.cmake:
> SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS "-KPIC")
> 
> For CMake 2.6 which I built for myself, the results are
> 
> grep -i kpic
> ~software/cmake/install/share/cmake-2.6/Modules/Platform/*
> /home/software/cmake/install/share/cmake-2.6/Modules/Platform/Linux-SunPro-C.cmake:SET(CMAKE_SHARED_LIBRARY_C_FLAGS
> "-KPIC")
> /home/software/cmake/install/share/cmake-2.6/Modules/Platform/Linux-SunPro-CXX.cmake:SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS
> "-KPIC")
> /home/software/cmake/install/share/cmake-2.6/Modules/Platform/Linux-SunPro-Fortran.cmake:SET(CMAKE_SHARED_LIBRARY_Fortran_FLAGS
> "-KPIC")
> /home/software/cmake/install/share/cmake-2.6/Modules/Platform/SCO_SV.cmake:SET(CMAKE_SHARED_LIBRARY_C_FLAGS
> "-Kpic -belf")
> /home/software/cmake/install/share/cmake-2.6/Modules/Platform/SCO_SV.cmake:SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS
> "-Kpic -belf")
> /home/software/cmake/install/share/cmake-2.6/Modules/Platform/SunOS.cmake:
> SET(CMAKE_SHARED_LIBRARY_C_FLAGS "-KPIC") 
> /home/software/cmake/install/share/cmake-2.6/Modules/Platform/SunOS.cmake:
> SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS "-KPIC")
> 
> IOW, -KPIC should only be set if you have a SCO or SunOS
> platform for
> CMake-2.4 and SCO, SunOS, or Linux-SunPro, for cmake 2.6. 
> It's possible your
> Ubuntu system is being misidentified as one of those, but I
> doubt it.
> 
> What version of cmake do you have, and what are the
> equivalent grep results?
> 
> Are you incorrectly setting -KPIC in some other way through
> an environment
> variable?  You could do that by, e.g.,
> 
> export FC='ifort -KPIC'
> 
> CMake may also pay attention to other environment variables
> like FFLAGS (or
> maybe FCFLAGS) so make sure you have not set those
> environment variables to
> something that is interfering.
> 
> Are you specifying ifort compile flags in any other way
> (via -D options to
> the cmake command, for example)?
> 
> For each of your tests do you run the cmake command in an
> empty build tree
> so there is no possibility that stale files from previous
> builds are
> affecting your results?
> 
> 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 libLASi project
> (unifont.org/lasi); the Loads of
> Linux Links project (loll.sf.net); and the Linux Brochure
> Project
> (lbproject.sf.net).
> __________________________
> 
> Linux-powered Science
> __________________________

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Plplot-general mailing list
Plplot-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-general

Reply via email to