Remove tabs in shell script

Indentation by tab will cause a file listing for the current directory
before the command is executed, and that what not intended here.
Ignore version output

When creating CMake files for config mode, a separate version file is
generated; this should be on the ignore list as well if we are going
to build in-tree.
Allow DUNE paths to be specified in configure

Path to DUNE libraries are specified with the ROOT prefix, but with the
stem with the same name as the module -- in lowercase (otherwise; does
the hyphen uppercase to underscore?). This deviates somewhat from the
usual CMake convention of using uppercase all over the place.
Provide distclean target to remove CMake artifacts

If you are building in-tree (which is commonly done by dunecontrol),
it can be advantageous to have a target which is capable of cleaning
out all the files that CMake left without having to erase the entire
folder.
Display CMake command-line that is being executed

Since this is a compatibility script it will probably benefit people
seeing which underlaying CMake command is being executed (not at least
for debugging purposes)
Assume that all paths to modules are directories

Old implementation had a problem with the special case that you
specified a directory directly under the root (e.g. /usr); dirname
adds a trailing slash in that case.
Quote paths

Otherwise strange things will happen if they contain spaces
Provide ability to build in DUNE framework

dunecontrol will look for a file called dune.module and use the
information therein to determine which and in what sequences directories
should be built.

By specifying dune-common and dune-istl as dependencies here, we
ensure that those directories are available before opm-core. They are
not true dependencies; opm-core is usable without them, but if you are
using dunecontrol, then it is a good bet that dune-istl also is
available and desirable to use.
Ignore all user files from QtCreator

If you open the project in QtCreator again after having made changes
to CMakeLists.txt outside of it, it may create a new user file which
should be ignored just like the original.
Tip for enabling IDE debugging in QtCreator
Enable release mode from wrapper script

By using --disable-debug (--enable-debug is the default), release mode
can be toggled from the wrapper script.

Some IDEs, notably QtCreator requires this flag to be set when running
CMake, in order to enable debugging properly. Thus, it is explicitly
set (and printed) when using ./configure also.
Build tests as a separate target

It is very annoying having to build all the tests when you are
testing some code in the main library. Someone downloading the
library probably doesn't need the tests either, so these are left
out of the default target.
Explain why docs and tests are excluded by default
Escape backquote in help text

Otherwise this will of course be interpreted by the shell, which is not
the intention here.
Let SuiteSparse path be specified without config mode

Use the _ROOT suffix to direct the CMake module to use a particular path
to the SuiteSparse installation without also triggering config mode (by
convention CMake uses Foo_DIR as the name of the variable which
specifies where to look for another *project*).
Allow umfpack to be used as an alias for SuiteSparse

Most people will associate the use of SuiteSparse with "using UMFPACK"
since that is the component that is actively used.
Allow system installation to be used with dunecontrol
Annotate dependencies with version number
Set version number to 1.0 in anticipation of release
Supplement GNUInstallDirs to support multi-arch

Debian object code libraries are in directories which include the
platform name to allow several of these to co-exist. Other distros
such as Fedora uses a simpler naming scheme (e.g. "lib64/") which
is more backward-compatible.