mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-13 21:37:13 +02:00
dev: version from file to cmake and python (#1025)
- renamed conda-recipe folder - added a check to see if build and install folder exists in build.sh (conda recipe) - created VERSION file that has '0.0.0'for developer but can be updated using update_version.py that takes in a version. The script checks for semantic versioning and updates VERSION file - VERSION file also copied along with py files to slsdet in python cmakelist and build_pylib.sh (for conda), also copied in root folder for installations (for no coding purpose) - init.py and setup.py reads this file to get the version (a bit differently to find the VERSION file) - VERSION file read into cmake to get the version and also added to compile definition. So RELEASE removed from versionAPI.h (using SLS_DET_VERSION compile definiton instead) and also removed updateRelease script. - conda getting project version from environment variable SLS_DET_VERSION that is set in build_pylib.sh prior. - added 3.13 python to conda build - anything related to ctb removed from release notes as users will always use developer - sets 0.0.0 to VERSION file by running update_version.py without an argument
This commit is contained in:
@ -49,7 +49,6 @@ set( PYTHON_FILES
|
||||
slsdet/temperature.py
|
||||
slsdet/lookup.py
|
||||
slsdet/utils.py
|
||||
|
||||
)
|
||||
|
||||
foreach(FILE ${PYTHON_FILES})
|
||||
@ -58,7 +57,6 @@ foreach(FILE ${PYTHON_FILES})
|
||||
|
||||
endforeach(FILE ${PYTHON_FILES})
|
||||
|
||||
|
||||
configure_file( scripts/basic.py
|
||||
${CMAKE_BINARY_DIR}/basic.py
|
||||
)
|
||||
@ -66,6 +64,9 @@ configure_file( scripts/test_virtual.py
|
||||
${CMAKE_BINARY_DIR}/test_virtual.py
|
||||
)
|
||||
|
||||
configure_file( ${CMAKE_SOURCE_DIR}/VERSION
|
||||
${CMAKE_BINARY_DIR}/bin/slsdet/VERSION
|
||||
)
|
||||
|
||||
if(SLS_INSTALL_PYTHONEXT)
|
||||
install(TARGETS _slsdet
|
||||
@ -74,4 +75,5 @@ if(SLS_INSTALL_PYTHONEXT)
|
||||
)
|
||||
|
||||
install(FILES ${PYTHON_FILES} DESTINATION ${CMAKE_INSTALL_PREFIX}/python/slsdet)
|
||||
install(FILES ../VERSION DESTINATION ${CMAKE_INSTALL_PREFIX}/python/slsdet)
|
||||
endif()
|
Reference in New Issue
Block a user