mirror of https://github.com/CGAL/cgal
Take the version number from `public_release_name`
This commit is contained in:
parent
4f97bd5102
commit
21fedbf0ad
|
|
@ -253,10 +253,15 @@ if (NOT CGAL_CREATED_VERSION_NUM)
|
||||||
set(CGAL_CREATED_VERSION_NUM "${CGAL_MAJOR_VERSION}.${CGAL_MINOR_VERSION}")
|
set(CGAL_CREATED_VERSION_NUM "${CGAL_MAJOR_VERSION}.${CGAL_MINOR_VERSION}")
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
#read version.h and get the line with CGAL_VERSION
|
if(EXISTS "${CGAL_ROOT}/doc/public_release_name")
|
||||||
file(STRINGS "${CGAL_ROOT}/include/CGAL/version.h" CGAL_VERSION_LINE REGEX "CGAL_VERSION ")
|
file(STRINGS "${CGAL_ROOT}/doc/public_release_name" CGAL_VERSION_LINE)
|
||||||
#extract release id
|
string(REGEX REPLACE "CGAL-" "" CGAL_CREATED_VERSION_NUM "${CGAL_VERSION_LINE}")
|
||||||
string(REGEX MATCH "[0-9]+\\.[0-9]+\\.?[0-9]*" CGAL_CREATED_VERSION_NUM "${CGAL_VERSION_LINE}")
|
else()
|
||||||
|
#read version.h and get the line with CGAL_VERSION
|
||||||
|
file(STRINGS "${CGAL_ROOT}/include/CGAL/version.h" CGAL_VERSION_LINE REGEX "CGAL_VERSION ")
|
||||||
|
#extract release id
|
||||||
|
string(REGEX MATCH "[0-9]+\\.[0-9]+\\.?[0-9]*" CGAL_CREATED_VERSION_NUM "${CGAL_VERSION_LINE}")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
@ -264,6 +269,7 @@ endif()
|
||||||
# closely to the convoluted versioning code and can adapt without a
|
# closely to the convoluted versioning code and can adapt without a
|
||||||
# huge diff.
|
# huge diff.
|
||||||
set(CGAL_DOC_VERSION ${CGAL_CREATED_VERSION_NUM})
|
set(CGAL_DOC_VERSION ${CGAL_CREATED_VERSION_NUM})
|
||||||
|
message(CGAL_DOC_VERSION: ${CGAL_DOC_VERSION})
|
||||||
|
|
||||||
## generate how_to_cite files
|
## generate how_to_cite files
|
||||||
if(PYTHONINTERP_FOUND)
|
if(PYTHONINTERP_FOUND)
|
||||||
|
|
|
||||||
|
|
@ -154,6 +154,10 @@ foreach(pkg ${files})
|
||||||
process_package(${pkg})
|
process_package(${pkg})
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
if(EXISTS ${GIT_REPO}/Maintenance/release_building/public_release_name)
|
||||||
|
file(COPY "${GIT_REPO}/Maintenance/release_building/public_release_name"
|
||||||
|
DESTINATION "${release_dir}/doc")
|
||||||
|
endif()
|
||||||
|
|
||||||
#create VERSION
|
#create VERSION
|
||||||
file(WRITE ${release_dir}/VERSION "${CGAL_VERSION}")
|
file(WRITE ${release_dir}/VERSION "${CGAL_VERSION}")
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue