[petsc-dev] petsc makefiles
Blaise A Bourdin
bourdin at lsu.edu
Thu Jul 20 21:46:54 CDT 2017
> On Jul 20, 2017, at 6:49 PM, Jed Brown <jed at jedbrown.org> wrote:
>
> Blaise A Bourdin <bourdin at lsu.edu> writes:
>
>> Hi,
>>
>> Is there a way in petsc makefiles to figure out how to link a shared / dynamic library
>> i.e. if I want to know how to do
>> $CC -shared *.o lib.so
>> vs.
>> $CC -dynamiclib *.o lib.dylib
>> what variable gives me the extension .so vs .dylib and the linker option -shared vs -dynamiclib
>
> See SL_LINKER_FUNCTION and SL_LINKER_SUFFIX, e.g., as used from gmakefile.
Cool.
>
>> How about doing the same thing in BuildSystem (I need to build a shared library for exodus)?
>
> Isn't the Exodus build system capable of that?
My understanding is that we use a repackaged version of exodus 5.24 with a crappy makefile. More recent version (6.0+) use cmake and automatically build the shared library. I seem to have issues with the latest release’s python bindings. AS soon as I can figure out what the problem is, I can rewrite the BuildSystem exodus module for the most recent version
>
>> Also, is there a way to know the family of compiler I am using (gnu vs intel vs something else)?
>> The long line fortran compiler options for fortran and ifort are of course different, and the default behavior opposite…
>
> That option goes into FC_FLAGS.
Of course. One of the many perks of the new fortran setup
Blaise
--
Department of Mathematics and Center for Computation & Technology
Louisiana State University, Baton Rouge, LA 70803, USA
Tel. +1 (225) 578 1612, Fax +1 (225) 578 4276 http://www.math.lsu.edu/~bourdin
More information about the petsc-dev
mailing list