[petsc-users] configure script for petsc

2010-04-23 Thread Stephan Kramer
Hi all,

I'm trying to write a portable configure script for our software that uses 
petsc, and needs to deal with petsc installations on a number of different 
platforms. In petsc 3.0 I could do

   make -f $(PETSC_DIR)/conf/base getlinklibs

and

   make -f $(PETSC_DIR)/conf/base getincludedirs

that would work for both installed petsc and petsc in its own build directory 
(provided PETSC_ARCH is set correctly of course). In petsc 3.1 conf/base seems 
to have disappeared, is the best
way to deal with this to make my own little makefile:

include ${PETSC_DIR}/conf/variables
include ${PETSC_DIR}/conf/rules

and use make -f my_own_little_makefile getlinklibs instead?

Cheers
Stephan


[petsc-users] configure script for petsc

2010-04-23 Thread Satish Balay
On Fri, 23 Apr 2010, Stephan Kramer wrote:

 Hi all,
 
 I'm trying to write a portable configure script for our software that uses
 petsc, and needs to deal with petsc installations on a number of different
 platforms. In petsc 3.0 I could do
 
   make -f $(PETSC_DIR)/conf/base getlinklibs
 
 and
 
   make -f $(PETSC_DIR)/conf/base getincludedirs
 
 that would work for both installed petsc and petsc in its own build
 directory (provided PETSC_ARCH is set correctly of course). In petsc 3.1
 conf/base seems to have disappeared, is the best
 way to deal with this to make my own little makefile:
 
 include ${PETSC_DIR}/conf/variables
 include ${PETSC_DIR}/conf/rules
 
 and use make -f my_own_little_makefile getlinklibs instead?

Yes - this way - you can add more stuff into this makefile - if needed.

If you just do getlinklibs and getincludedirs - then you can probably
just do:

make -f $(PETSC_DIR)/makefile getincludedirs

etc..

Satish


[petsc-users] configure script for petsc

2010-04-23 Thread Stephan Kramer
Satish Balay wrote:
 On Fri, 23 Apr 2010, Stephan Kramer wrote:
 
 Hi all,

 I'm trying to write a portable configure script for our software that uses
 petsc, and needs to deal with petsc installations on a number of different
 platforms. In petsc 3.0 I could do

   make -f $(PETSC_DIR)/conf/base getlinklibs

 and

   make -f $(PETSC_DIR)/conf/base getincludedirs

 that would work for both installed petsc and petsc in its own build
 directory (provided PETSC_ARCH is set correctly of course). In petsc 3.1
 conf/base seems to have disappeared, is the best
 way to deal with this to make my own little makefile:

 include ${PETSC_DIR}/conf/variables
 include ${PETSC_DIR}/conf/rules

 and use make -f my_own_little_makefile getlinklibs instead?
 
 Yes - this way - you can add more stuff into this makefile - if needed.
 
 If you just do getlinklibs and getincludedirs - then you can probably
 just do:
 
 make -f $(PETSC_DIR)/makefile getincludedirs

True, except the makefile doesn't make it into a prefix-installed
installation of petsc. Having my own makefile do it works fine -
  was just checking if this is indeed the recommended way

Thanks a lot
Cheers
Stephan


 
 etc..
 
 Satish
 


-- 
Stephan Kramer  s.kramer at imperial.ac.uk
Applied Modelling and Computation Group,
Department of Earth Science and Engineering,
Imperial College London


[petsc-users] configure script for petsc

2010-04-23 Thread Satish Balay
On Fri, 23 Apr 2010, Stephan Kramer wrote:

 Satish Balay wrote:
  On Fri, 23 Apr 2010, Stephan Kramer wrote:
  
   Hi all,
   
   I'm trying to write a portable configure script for our software that uses
   petsc, and needs to deal with petsc installations on a number of different
   platforms. In petsc 3.0 I could do
   
 make -f $(PETSC_DIR)/conf/base getlinklibs
   
   and
   
 make -f $(PETSC_DIR)/conf/base getincludedirs
   
   that would work for both installed petsc and petsc in its own build
   directory (provided PETSC_ARCH is set correctly of course). In petsc 3.1
   conf/base seems to have disappeared, is the best
   way to deal with this to make my own little makefile:
   
   include ${PETSC_DIR}/conf/variables
   include ${PETSC_DIR}/conf/rules
   
   and use make -f my_own_little_makefile getlinklibs instead?
  
  Yes - this way - you can add more stuff into this makefile - if needed.
  
  If you just do getlinklibs and getincludedirs - then you can probably
  just do:
  
  make -f $(PETSC_DIR)/makefile getincludedirs
 
 True, except the makefile doesn't make it into a prefix-installed
 installation of petsc. Having my own makefile do it works fine -
  was just checking if this is indeed the recommended way

Ah yes. There is no makefie that you can use in the prefix install. In
this case creating a temporary makefile is the way to go..

Satish