Merged revisions 92443 via svnmerge from
[asterisk/asterisk.git] / build_tools / make_version_h
index 0b651ad..6d901c2 100755 (executable)
@@ -1,25 +1,17 @@
 #!/bin/sh
 if [ ! -f ../.flavor ]; then
 #!/bin/sh
 if [ ! -f ../.flavor ]; then
-    cat << END
-/*
- * version.h 
- * Automatically generated
- */
-#define ASTERISK_VERSION "${ASTERISKVERSION}"
-#define ASTERISK_VERSION_NUM ${ASTERISKVERSIONNUM}
-
-END
+    EXTRA=""
 else
     aadkver=`cat ../.version`
     aadkflavor=`cat ../.flavor`
 else
     aadkver=`cat ../.version`
     aadkflavor=`cat ../.flavor`
-    cat << END
+    EXTRA=" (${aadkflavor} ${aadkver})"
+fi
+cat << END
 /*
  * version.h 
  * Automatically generated
  */
 /*
  * version.h 
  * Automatically generated
  */
-#define ASTERISK_VERSION "${ASTERISKVERSION} (${aadkflavor} ${aadkver})"
+#define ASTERISK_VERSION "${ASTERISKVERSION}${EXTRA}"
 #define ASTERISK_VERSION_NUM ${ASTERISKVERSIONNUM}
 
 END
 #define ASTERISK_VERSION_NUM ${ASTERISKVERSIONNUM}
 
 END
-fi
-