version: generate RPM version from git
This unifies our RPM version handling, based on tags.
1) Tags are of form ctdb-<version>.
2) The first <version> starts with .1.
3) Devel versions end with .0.<patchnum>.<checksum>.devel to reliably
identify them.
This means that devel versions will correctly supersede releases and earlier
devels, but new releases will correctly supersede older devel RPMs.
Making a new release is as simple as creating a new git tag.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>