diff options
author | Peter Powell <petpow@saberuk.com> | 2012-07-11 20:38:17 +0100 |
---|---|---|
committer | attilamolnar <attilamolnar@hush.com> | 2012-07-27 00:14:43 +0200 |
commit | 746932587a11255e098c3b528afc6fcb4fc00902 (patch) | |
tree | bdf90455603eeda3e082c91b9797853fa2fb7f41 /configure | |
parent | 6dbcfc3858cf58fa457bf6990760083c8a051feb (diff) |
Don't hard code the branch version.
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -848,6 +848,11 @@ sub writefiles { chomp(my $incos = `uname -n -s -r`); chomp(my $version = `sh src/version.sh`); chomp(my $revision2 = getrevision()); + my $branch = "InspIRCd-0.0"; + if ($version =~ /^(InspIRCd-[0-9]+\.[0-9]+)\.[0-9]+/) + { + $branch = $1; + } if ($writeheader == 1) { print "Writing \e[1;32minspircd_config.h\e[0m\n"; @@ -933,6 +938,7 @@ print FILEHANDLE "#define MAXBUF " . ($config{MAXBUF}+2) . "\n"; open(FILEHANDLE, ">include/inspircd_version.h.tmp"); print FILEHANDLE <<EOF; +#define BRANCH "$branch" #define VERSION "$version" #define REVISION "$revision2" #define SYSTEM "$incos" |