Skip to content

Commit

Permalink
prerelease version
Browse files Browse the repository at this point in the history
add prerelease version to get away from using major/minor/patch to
encode instability
  • Loading branch information
hanumantmk committed Mar 12, 2015
1 parent 4e71f41 commit 0139c97
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@ set (SOURCE_DIR "${PROJECT_SOURCE_DIR}/")
set (BSON_MAJOR_VERSION 1)
set (BSON_MINOR_VERSION 1)
set (BSON_MICRO_VERSION 3)
set (BSON_PRERELEASE_VERSION dev)
set (BSON_API_VERSION 1.0)
set (BSON_VERSION 1.1.3)
set (BSON_VERSION 1.1.3-dev)

set (CPACK_RESOURCE_FILE_LICENSE "${SOURCE_DIR}/COPYING")
set (CPACK_PACKAGE_VERSION_MAJOR ${BSON_MAJOR_VERSION})
Expand Down
2 changes: 1 addition & 1 deletion build/autotools/PrintBuildConfiguration.m4
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
AC_OUTPUT

if test $(( ${BSON_MINOR_VERSION} % 2 )) -eq 1; then
if test -n "$BSON_PRERELEASE_VERSION"; then
cat << EOF
*** IMPORTANT ***

Expand Down
5 changes: 4 additions & 1 deletion build/autotools/Versions.m4
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
m4_define([bson_major_version], [1])
m4_define([bson_minor_version], [1])
m4_define([bson_micro_version], [3])
m4_define([bson_version], [bson_major_version.bson_minor_version.bson_micro_version])
m4_define([bson_prerelease_version], [dev])

#m4_define([bson_version], [bson_major_version.bson_minor_version.bson_micro_version])
m4_define([bson_version], [bson_major_version.bson_minor_version.bson_micro_version-bson_prerelease_version])

# bump up by 1 for every micro release with no API changes, otherwise
# set to 0. after release, bump up by 1
Expand Down
2 changes: 2 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,13 @@ AC_SUBST(ACLOCAL_AMFLAGS, "-I build/autotools")
BSON_MAJOR_VERSION=bson_major_version
BSON_MINOR_VERSION=bson_minor_version
BSON_MICRO_VERSION=bson_micro_version
BSON_PRERELEASE_VERSION=bson_prerelease_version
BSON_API_VERSION=1.0
BSON_VERSION=bson_version
AC_SUBST(BSON_MAJOR_VERSION)
AC_SUBST(BSON_MINOR_VERSION)
AC_SUBST(BSON_MICRO_VERSION)
AC_SUBST(BSON_PRERELEASE_VERSION)
AC_SUBST(BSON_API_VERSION)
AC_SUBST(BSON_VERSION)

Expand Down

0 comments on commit 0139c97

Please sign in to comment.