Re-add the automatically generated version.h, so that modules can include for

making build time decisions for cross asterisk version compatibility


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@104245 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Russell Bryant
2008-02-26 20:19:03 +00:00
parent 0036cde5f3
commit 8d90438b42
2 changed files with 34 additions and 3 deletions

25
build_tools/make_version_h Executable file
View File

@@ -0,0 +1,25 @@
#!/bin/sh
if [ ! -f ../.flavor ]; then
cat << END
/*
* version.h
* Automatically generated
*/
#define ASTERISK_VERSION "${ASTERISKVERSION}"
#define ASTERISK_VERSION_NUM ${ASTERISKVERSIONNUM}
END
else
aadkver=`cat ../.version`
aadkflavor=`cat ../.flavor`
cat << END
/*
* version.h
* Automatically generated
*/
#define ASTERISK_VERSION "${ASTERISKVERSION} (${aadkflavor} ${aadkver})"
#define ASTERISK_VERSION_NUM ${ASTERISKVERSIONNUM}
END
fi