Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: update with latest help from cli applications #138

Merged
merged 1 commit into from
Aug 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
116 changes: 53 additions & 63 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,13 @@ The help message identifies required positional arguments and optional arguments
default values.

```
usage: mfpymake [-h] [-fc {ifort,mpiifort,gfortran,ftn,none}]
usage: mfpymake [-h] [-fc {ifort,mpiifort,gfortran,none}]
[-cc {gcc,clang,clang++,icc,icl,mpiicc,g++,cl,none}]
[-ar {ia32,ia32_intel64,intel64}] [-mc] [-dbl] [-dbg]
[-e] [-dr] [-sd] [-ff FFLAGS] [-cf CFLAGS]
[-sl {-lc,-lm}] [-mf] [-md] [-cs COMMONSRC]
[-ef EXTRAFILES] [-exf EXCLUDEFILES] [-so]
[-ad APPDIR] [-v] [--keep] [--zip ZIP] [--inplace]
[--networkx] [--mb] [-mbd]
[-ar {ia32,ia32_intel64,intel64}] [-mc] [-dbl] [-dbg] [-e]
[-dr] [-sd] [-ff FFLAGS] [-cf CFLAGS] [-sl {-lc,-lm}] [-mf]
[-md] [-cs COMMONSRC] [-ef EXTRAFILES] [-exf EXCLUDEFILES]
[-so] [-ad APPDIR] [-v] [--keep] [--zip ZIP] [--inplace]
[--networkx] [--meson] [--mesondir]
srcdir target

This is the pymake program for compiling fortran, c, and c++ source
Expand All @@ -76,79 +75,70 @@ positional arguments:

optional arguments:
-h, --help show this help message and exit
-fc {ifort,mpiifort,gfortran,ftn,none}
Fortran compiler to use. (default is
gfortran)
-fc {ifort,mpiifort,gfortran,none}
Fortran compiler to use. (default is gfortran)
-cc {gcc,clang,clang++,icc,icl,mpiicc,g++,cl,none}
C/C++ compiler to use. (default is gcc)
-ar {ia32,ia32_intel64,intel64}, --arch {ia32,ia32_intel64,intel64}
Architecture to use for Intel and Microsoft
compilers on Windows. (default is intel64)
-mc, --makeclean Clean temporary object, module, and source
files when done. (default is False)
Architecture to use for Intel and Microsoft compilers
on Windows. (default is intel64)
-mc, --makeclean Clean temporary object, module, and source files when
done. (default is False)
-dbl, --double Force double precision. (default is False)
-dbg, --debug Create debug version. (default is False)
-e, --expedite Only compile out of date source files. Clean
must not have been used on previous build.
-e, --expedite Only compile out of date source files. Clean must not
have been used on previous build. (default is False)
-dr, --dryrun Do not actually compile. Files will be deleted, if
--makeclean is used. Does not work yet for ifort.
(default is False)
-dr, --dryrun Do not actually compile. Files will be
deleted, if --makeclean is used. Does not
work yet for ifort. (default is False)
-sd, --subdirs Include source files in srcdir
subdirectories. (default is None)
-sd, --subdirs Include source files in srcdir subdirectories.
(default is None)
-ff FFLAGS, --fflags FFLAGS
Additional Fortran compiler flags. Fortran
compiler flags should be enclosed in quotes
and start with a blank space or separated
from the name (-ff or --fflags) with a equal
sign (-ff='-O3'). (default is None)
Additional Fortran compiler flags. Fortran compiler
flags should be enclosed in quotes and start with a
blank space or separated from the name (-ff or
--fflags) with a equal sign (-ff='-O3'). (default is
None)
-cf CFLAGS, --cflags CFLAGS
Additional C/C++ compiler flags. C/C++
compiler flags should be enclosed in quotes
and start with a blank space or separated
from the name (-cf or --cflags) with a equal
sign (-cf='-O3'). (default is None)
Additional C/C++ compiler flags. C/C++ compiler flags
should be enclosed in quotes and start with a blank
space or separated from the name (-cf or --cflags)
with a equal sign (-cf='-O3'). (default is None)
-sl {-lc,-lm}, --syslibs {-lc,-lm}
Linker system libraries. Linker libraries
should be enclosed in quotes and start with a
blank space or separated from the name (-sl
or --syslibs) with a equal sign
(-sl='-libgcc'). (default is None)
-mf, --makefile Create a GNU make makefile. (default is
False)
-md, --makefile-dir GNU make makefile directory. (default is '.')
Linker system libraries. Linker libraries should be
enclosed in quotes and start with a blank space or
separated from the name (-sl or --syslibs) with a
equal sign (-sl='-libgcc'). (default is None)
-mf, --makefile Create a GNU make makefile. (default is False)
-md, --makefiledir GNU make makefile directory. (default is '.')
-cs COMMONSRC, --commonsrc COMMONSRC
Additional directory with common source
files. (default is None)
Additional directory with common source files.
(default is None)
-ef EXTRAFILES, --extrafiles EXTRAFILES
List of extra source files to include in the
compilation. extrafiles can be either a list
of files or the name of a text file that
contains a list of files. (default is None)
compilation. extrafiles can be either a list of files
or the name of a text file that contains a list of
files. (default is None)
-exf EXCLUDEFILES, --excludefiles EXCLUDEFILES
List of extra source files to exclude from
the compilation. excludefiles can be either a
list of files or the name of a text file that
contains a list of files. (default is None)
-so, --sharedobject Create shared object or dll on Windows.
(default is False)
-ad APPDIR, --appdir APPDIR
Target path that overides path defined target
path (default is None)
-v, --verbose Verbose output to terminal. (default is
List of extra source files to exclude from the
compilation. excludefiles can be either a list of
files or the name of a text file that contains a list
of files. (default is None)
-so, --sharedobject Create shared object or dll on Windows. (default is
False)
-ad APPDIR, --appdir APPDIR
Target path that overides path defined target path
(default is None)
-v, --verbose Verbose output to terminal. (default is False)
--keep Keep existing executable. (default is False)
--zip ZIP Zip built executable. (default is False)
--inplace Source files in srcdir are used directly.
(default is False)
--networkx Use networkx package to build Directed
Acyclic Graph use to determine the order
source files are compiled in. (default is
False)
--mb, --meson-build Use meson to build executable. (default is
--inplace Source files in srcdir are used directly. (default is
False)
-mbd, --mesonbuild-dir
meson directory. (default is '.')
--networkx Use networkx package to build Directed Acyclic Graph
use to determine the order source files are compiled
in. (default is False)
--meson Use meson to build executable. (default is False)
--mesondir meson directory. (default is '.')

Note that the source directory should not contain any bad
or duplicate source files as all source files in the source
Expand Down
21 changes: 12 additions & 9 deletions docs/build_apps.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,20 @@ and options can be determined by executing:

```console
$ make-program --help

usage: make-program [-h] [--release_precision]
[-fc {ifort,mpiifort,gfortran,ftn,none}]
[-cc {gcc,clang,clang++,icc,icx,icl,mpiicc,g++,cl,none}]
[-dr] [-ff FFLAGS] [-cf CFLAGS] [-ad APPDIR] [-v] [--keep]
[--zip ZIP]
[-fc {ifort,mpiifort,gfortran,none}]
[-cc {gcc,clang,clang++,icc,icl,mpiicc,g++,cl,none}] [-dr]
[-ff FFLAGS] [-cf CFLAGS] [-ad APPDIR] [-v] [--keep]
[--zip ZIP] [--meson]
targets

Download and build USGS MODFLOW and related programs.

positional arguments:
targets Program(s) to build. Options: crt, gridgen, gsflow,
libmf6, mf2000, mf2005, mf6, mflgr, mfnwt, mfusg, mp6,
mp7, mt3dms, mt3dusgs, prms, sutra, swtv4, triangle,
targets Program(s) to build. Options: crt, gridgen, libmf6,
mf2000, mf2005, mf6, mflgr, mfnwt, mfusg, mfusg_gsi,
mp6, mp7, mt3dms, mt3dusgs, sutra, swtv4, triangle,
vs2dt, zbud6, zonbud3, zonbudusg, :. Specifying the
target to be ':' will build all of the programs.

Expand All @@ -29,9 +30,9 @@ optional arguments:
precision version of the program for programs where
the standard_switch and double_switch in
usgsprograms.txt is True. default is True.
-fc {ifort,mpiifort,gfortran,ftn,none}
-fc {ifort,mpiifort,gfortran,none}
Fortran compiler to use. (default is gfortran)
-cc {gcc,clang,clang++,icc,icx,icl,mpiicc,g++,cl,none}
-cc {gcc,clang,clang++,icc,icl,mpiicc,g++,cl,none}
C/C++ compiler to use. (default is gcc)
-dr, --dryrun Do not actually compile. Files will be deleted, if
--makeclean is used. Does not work yet for ifort.
Expand All @@ -53,6 +54,7 @@ optional arguments:
-v, --verbose Verbose output to terminal. (default is False)
--keep Keep existing executable. (default is False)
--zip ZIP Zip built executable. (default is False)
--meson Use meson to build executable. (default is False)

Examples:

Expand All @@ -64,6 +66,7 @@ Examples:

Download and compile all programs in the ./temp subdirectory:
$ make-program : --appdir temp

```

`make-program` can be used to build MODFLOW 6, MODFLOW-2005, MODFLOW-NWT, MODFLOW-USG, MODFLOW-LGR, MODFLOW-2000,
Expand Down
Loading