Extract common parts of blackoil and incomp. state

Put the identical parts of the simulator state into a base class that
they can be referenced from when adressing the common fields.
Search in build/ sub-dir if only suite root is given

If the package suite was given (e.g. DUNE_ROOT=/blum), then the code
set up the root for each individual package automatically (e.g.
DUNE_COMMON_ROOT=/blum/dune-common), but the path which was then
activated did not get the local build sub-directory (e.g. if we are
building opm-autodiff in /frub/opm-autodiff/build, then the local
build directory is "build/"), and thus this was not appended to the
library search path. The result was that the source was found (because
the root pointed to a valid source tree), but the library was not
(because it is "hidden" in the subdirectory).
Only add build sub-directory if it is actually used

Otherwise the search will cascade down one level too many.
Only add parent directories for actual variants

Otherwise we'll inadvertedly add the root directory and will probably
find the system implementation underneath there.
fix syntax error in configure shell script

strangly enough, it seems to work like it was in some circumstances...
Merge pull request #436 from rolk/436_searchdir

Search in build/ sub-dir if only suite root is given
Merge pull request #420 from rolk/420_state

Refactor BlackoilState and TwophaseState to have a common interface for writing
Merge pull request #439 from andlaus/fix_configure_syntax_error

fix syntax error in configure shell script
Merge remote-tracking branch 'upstream/master' into opm-parser-integrate