[MITgcm-support] genmake2: going with the flow

Ed Hill ed at eh3.com
Tue Sep 23 10:13:28 EDT 2003


On Tue, 2003-09-23 at 03:26, Martin Losch wrote:
> Hi,
> 
> I am trying to keep up with your pace and want to learn how to use 
> genmake2, or is that too early? I am having all sorts of problems:
> 1. when I specify -optfile=$TOOLSDIR/build_options/linux_ifc I still 
> have to specify -fc=ifc to make things work. Is that intended?

Hi Martin,

Thank you for trying genmake2!  We have it working with a number of
compilers/platforms, so its probably not too early for others to try
it.  I'll try to answer the specific problems below:


> 2. with the command
>  >> ../../tools/genmake2 -optfile=../../tools/build_options/linux_ifc 
> -mods=../code -fc=ifc
> I get makefile
>  >> make depend
> ... (skipping the usual stuff)
> ../../tools/f90mkdepend >> Makefile
> echo: No match
>  >> make
> ... compile, compile, compile ...
> ... timer_stats.o -lPEPCF90
> make: o: Command not found
> make: [mitgcmuv] Error 127 (ignored)
>  >>
> There's no executable.

This error indicates that the name of either the compiler or linker is
missing and should be specified in the "optfile".


> 3. Apparently there no more .genmakerc. That's too bad, will that 
> possibility be put back into genmake2?

OK, I'll add this to the documentation.  The new "optfiles" are intended
to replace the old .genmakerc files.  And the optfiles given in
$ROOTDIR/tools/build_options/ are intended primarily as "good starting
points", not necessarily the best for your particular platform.  Some of
them have been tested and work on some machines and some are still in
need of work.  The trick is to take whatever options you were using in
your old .genmakerc file and convert them into one or more of the
new-style optfiles.

I'll bet that the options file at:

  MITgcm/tools/build_options/linux_ifc_ieee

is probably closer to what you want.


> 4. Do you already have documentation on how to use genmake2. The -help 
> option is not that help full. And simple options don't work, e.g.:
>  >> ../../tools/genmake2 -mods=../code
> ....
>  >>  make depend
> make[1]: Entering directory `/home/lincl/mlosch/head/channel/build2'
> ../../pkg/debug/chksum_tiled.F chksum_tiled.F
> make[1]: execvp: ../../pkg/debug/chksum_tiled.F: Permission denied
> make[1]: *** [chksum_tiled.F] Error 127
> make[1]: Leaving directory `/home/lincl/mlosch/head/channel/build2'
> make: *** [depend] Error 2

Documentation is available at:

  http://mitgcm.org/dev_docs/devel_HOWTO/

and I'll be adding to it in the coming week--especially based on your
comments here!


> If found it hard to understand genmake, but genmake2 is absolutely 
> impossible for me to comprehend, so I cannot track down these things 
> myself, or include, eg. a .genmakerc switch.

I'm very sorry that you find it counter-intuitive.  I'll do everything I
can to make the old .genmakerc to "optfiles" transition more
understandable in the documentation.

thanks,
Ed


> PS. my platform, etc.:
>  >> uname -a
> Linux lincl0 2.4.20-18.9bigmem #1 SMP Thu May 29 06:41:01 EDT 2003 i686 
> i686 i386 GNU/Linux
>  >> g77 -v
> Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/3.2.2/specs
> Configured with: ../configure --prefix=/usr --mandir=/usr/share/man 
> --infodir=/usr/share/info --enable-shared --enable-threads=posix 
> --disable-checking --with-system-zlib --enable-__cxa_atexit 
> --host=i386-redhat-linux
> Thread model: posix
> gcc version 3.2.2 20030222 (Red Hat Linux 3.2.2-5)
>  >> ifc -V
> Intel(R) Fortran Compiler for 32-bit applications, Version 7.1   Build 
> 20030813Z
> Copyright (C) 1985-2003 Intel Corporation.  All rights reserved.
> FOR NON-COMMERCIAL USE ONLY
> 
> GNU ld version 2.13.90.0.18 20030206
>    Supported emulations:
>     elf_i386
>     i386linux
> 
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://dev.mitgcm.org/mailman/listinfo/mitgcm-support
-- 
Edward H. Hill III, PhD
office:  MIT Dept. of EAPS;  Room 54-1424;  77 Massachusetts Ave.
            Cambridge, MA 02139-4307
email:   eh3 at mit.edu,  ed at eh3.com
URL:     http://web.mit.edu/eh3/
phone:   617-253-0098
fax:     617-253-4464
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://mitgcm.org/pipermail/mitgcm-support/attachments/20030923/85134d6b/attachment.sig>


More information about the MITgcm-support mailing list