Change create_new_release to use CGALConfigVersion.cmake as input

This commit is contained in:
Laurent Rineau
2020-05-06 13:36:38 +02:00
parent 4092727cf8
commit abf414df81
7 changed files with 18 additions and 8 deletions
+10 -3
View File
@@ -180,9 +180,13 @@ else
fi
# Set the major/minor/bugfix release numbers
NUMBERS_DIR=${SOURCES_DIR}/Maintenance/release_building
MAJOR_NUMBER=`cat ${NUMBERS_DIR}/MAJOR_NUMBER` # 2 digits max
MINOR_NUMBER=`cat ${NUMBERS_DIR}/MINOR_NUMBER` # 2 digits max
BUGFIX_NUMBER=`cat ${NUMBERS_DIR}/BUGFIX_NUMBER` # 1 digit max
if [ -f ${NUMBERS_DIR}/MAJOR_NUMBER ]; then
MAJOR_NUMBER=`cat ${NUMBERS_DIR}/MAJOR_NUMBER` # 2 digits max
MINOR_NUMBER=`cat ${NUMBERS_DIR}/MINOR_NUMBER` # 2 digits max
BUGFIX_NUMBER=`cat ${NUMBERS_DIR}/BUGFIX_NUMBER` # 1 digit max
else
eval $(cmake -DCGALCONFIGVERSIONFILE=${SOURCES_DIR}/CGALConfigVersion.cmake -P ${SOURCES_DIR}/Scripts/developer_scripts/create_new_release_evaluate_versions.cmake 2>&1)
fi
# Do not show the bugfix number if it is 0.
if [ x"$BUGFIX_NUMBER" != "x0" ]; then
@@ -302,6 +306,9 @@ if [ -n "$DO_PUBLIC" ]; then
else
public_release_name="CGAL-${public_release_version}"
fi
if ! [ -f ${NUMBERS_DIR}/MAJOR_NUMBER ]; then
eval $(cmake -DCGALCONFIGVERSIONFILE=${SOURCES_DIR}/CGALConfigVersion.cmake -P ${SOURCES_DIR}/Scripts/developer_scripts/create_new_release_evaluate_versions.cmake 2>&1)
fi
cmake -DGIT_REPO=${SOURCES_DIR} -DPUBLIC="ON" -DDESTINATION="${DESTINATION}" -DCGAL_VERSION="${public_release_version}" -DCGAL_VERSION_NR="${release_number}" -DVERBOSE="${VERBOSE}" -P ${SOURCES_DIR}/Scripts/developer_scripts/cgal_create_release_with_cmake.cmake
pushd "${DESTINATION}/${public_release_name}"
@@ -0,0 +1,6 @@
include(${CGALCONFIGVERSIONFILE})
message("MAJOR_NUMBER=${CGAL_MAJOR_VERSION}
MINOR_NUMBER=${CGAL_MINOR_VERSION}
BUGFIX_NUMBER=${CGAL_BUGFIX_VERSION}
public_release_version=${CGAL_VERSION_PUBLIC_RELEASE_VERSION}
public_release_name=${CGAL_VERSION_PUBLIC_RELEASE_NAME}")