Commit Graph

7 Commits

Author SHA1 Message Date
Roland Kaufmann
3df0f06f45 Use OPM_MACROS_ROOT to locate build scripts
By using a separate variable for this we can easily grep for where
the build system depends on its own location, and also change the
policy regarding this later.

Note that there is no opm-macros module; this is a "psuedo"-module
which links to an additional one (currently, the one we're in)
2013-08-14 21:26:28 +02:00
Roland Kaufmann
6149756f3c Only build before library target if there is any 2013-08-08 10:09:08 +02:00
Roland Kaufmann
e3638f770f Safe-guard against version mismatch
The version declared for the build system (in dune.module) is checked
against what is in the source (e.g. opm/core/version.h) and if these
don't match, then issue an author warning.

This will help us keep the two version numbers in sync., since it
becomes very obvious when we don't. The benefit for this is to not have
the build system start mucking with the code just to dump some static
information in there.
2013-08-02 10:24:49 +02:00
Roland Kaufmann
1a04ae5125 Make project buildable also without Git
If Git is not found, revert to just dumping the label into the code.
(We currently have no way of getting the SHA into the tarball).
2013-07-31 15:08:51 +02:00
Roland Kaufmann
6f43c7587f Don't update version info in Debug mode
It gets tiresome to rebuild the project everytime one makes changes to
any of the unit tests. We don't likely publish results based on the
debug code anyway, so tracking the version number there is not such a
pressing issue.
2013-07-31 13:14:30 +02:00
Roland Kaufmann
764c3c8e60 Make sure that version info is updated before building code
Otherwise, the library may be declared "done" before the version number
process have had any change to touch files it depends upon. This ensures
that the version number is correct before we start building the library.
2013-07-31 12:58:12 +02:00
Roland Kaufmann
928a67b77f Write version information into header file
Akin to config.h, we write project-version.h whenever the VCS sha hash
of the project changes. This file can then be included to embed this
into the project. Since this changes more frequently, we choose another
file than config.h. Care is also taken to not rewrite the header if the
information doesn't change, but the project is rebuilt.
2013-07-31 12:04:07 +02:00