Modernize conanfile.py

This commit updates the Uranium dependency in the Conan file and introduces an internationalization (i18n) option.
It refactor the devtool checks to check for the "enable_i18n" option instead.
Lastly, cleanups and adjustments are done in preparation for enabling i18n in the build process.

Contributes to CURA-10831
This commit is contained in:
Jelle Spijker 2023-11-12 11:00:21 +01:00
parent 1fb1fe9faa
commit 1216674728
No known key found for this signature in database
GPG Key ID: 034D1C0527888B65

View File

@ -318,6 +318,8 @@ class CuraConan(ConanFile):
continue continue
self.requires(req) self.requires(req)
for req in self.conan_data["requirements_internal"]: for req in self.conan_data["requirements_internal"]:
if not self.options.internal and "fdm_materials" in req:
continue
self.requires(req) self.requires(req)
self.requires("cpython/3.10.4") self.requires("cpython/3.10.4")
self.requires("boost/1.82.0") self.requires("boost/1.82.0")
@ -495,6 +497,7 @@ echo "CURA_APP_NAME={{ cura_app_name }}" >> ${{ env_prefix }}GITHUB_ENV
del self.info.options.cloud_api_version del self.info.options.cloud_api_version
del self.info.options.display_name del self.info.options.display_name
del self.info.options.cura_debug_mode del self.info.options.cura_debug_mode
self.options.rm_safe("i18n")
# TODO: Use the hash of requirements.txt and requirements-ultimaker.txt, Because changing these will actually result in a different # TODO: Use the hash of requirements.txt and requirements-ultimaker.txt, Because changing these will actually result in a different
# Cura. This is needed because the requirements.txt aren't managed by Conan and therefor not resolved in the package_id. This isn't # Cura. This is needed because the requirements.txt aren't managed by Conan and therefor not resolved in the package_id. This isn't