mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-25 15:44:04 -06:00
Use umbase 0.1.5
Contributes to CURA-9365
This commit is contained in:
parent
e92e815226
commit
3609871ba6
1 changed files with 7 additions and 11 deletions
18
conanfile.py
18
conanfile.py
|
@ -31,7 +31,7 @@ class CuraConan(ConanFile):
|
||||||
|
|
||||||
# FIXME: Remove specific branch once merged to main
|
# FIXME: Remove specific branch once merged to main
|
||||||
# Extending the conanfile with the UMBaseConanfile https://github.com/Ultimaker/conan-ultimaker-index/tree/CURA-9177_Fix_CI_CD/recipes/umbase
|
# Extending the conanfile with the UMBaseConanfile https://github.com/Ultimaker/conan-ultimaker-index/tree/CURA-9177_Fix_CI_CD/recipes/umbase
|
||||||
python_requires = "umbase/0.1.4@ultimaker/testing"
|
python_requires = "umbase/0.1.5@ultimaker/testing"
|
||||||
python_requires_extend = "umbase.UMBaseConanfile"
|
python_requires_extend = "umbase.UMBaseConanfile"
|
||||||
|
|
||||||
options = {
|
options = {
|
||||||
|
@ -138,8 +138,7 @@ class CuraConan(ConanFile):
|
||||||
cura_digital_factory_url = self._digital_factory_url))
|
cura_digital_factory_url = self._digital_factory_url))
|
||||||
|
|
||||||
def _generate_pyinstaller_spec(self, location, entrypoint_location, icon_path, entitlements_file):
|
def _generate_pyinstaller_spec(self, location, entrypoint_location, icon_path, entitlements_file):
|
||||||
channel = "" if not self.channel else self.channel
|
pyinstaller_metadata = self._um_data()["pyinstaller"]
|
||||||
pyinstaller_metadata = self._um_data(self.version, channel)["pyinstaller"]
|
|
||||||
datas = [(str(self._base_dir.joinpath("conan_install_info.json")), ".")]
|
datas = [(str(self._base_dir.joinpath("conan_install_info.json")), ".")]
|
||||||
for data in pyinstaller_metadata["datas"].values():
|
for data in pyinstaller_metadata["datas"].values():
|
||||||
if "package" in data: # get the paths from conan package
|
if "package" in data: # get the paths from conan package
|
||||||
|
@ -225,8 +224,7 @@ class CuraConan(ConanFile):
|
||||||
raise ConanInvalidConfiguration("Only versions 5+ are support")
|
raise ConanInvalidConfiguration("Only versions 5+ are support")
|
||||||
|
|
||||||
def requirements(self):
|
def requirements(self):
|
||||||
channel = "" if not self.channel else self.channel
|
for req in self._um_data()["requirements"]:
|
||||||
for req in self._um_data(self.version, channel)["requirements"]:
|
|
||||||
self.requires(req)
|
self.requires(req)
|
||||||
|
|
||||||
def layout(self):
|
def layout(self):
|
||||||
|
@ -243,11 +241,10 @@ class CuraConan(ConanFile):
|
||||||
vr.generate()
|
vr.generate()
|
||||||
|
|
||||||
if self.options.devtools:
|
if self.options.devtools:
|
||||||
channel = "" if not self.channel else self.channel
|
|
||||||
entitlements_file = "'{}'".format(Path(self.source_folder, "packaging", "dmg", "cura.entitlements"))
|
entitlements_file = "'{}'".format(Path(self.source_folder, "packaging", "dmg", "cura.entitlements"))
|
||||||
self._generate_pyinstaller_spec(location = self.generators_folder,
|
self._generate_pyinstaller_spec(location = self.generators_folder,
|
||||||
entrypoint_location = "'{}'".format(Path(self.source_folder, self._um_data(self.version, channel)["runinfo"]["entrypoint"])).replace("\\", "\\\\"),
|
entrypoint_location = "'{}'".format(Path(self.source_folder, self._um_data()["runinfo"]["entrypoint"])).replace("\\", "\\\\"),
|
||||||
icon_path = "'{}'".format(Path(self.source_folder, "packaging", self._um_data(self.version, channel)["pyinstaller"]["icon"][str(self.settings.os)])).replace("\\", "\\\\"),
|
icon_path = "'{}'".format(Path(self.source_folder, "packaging", self._um_data()["pyinstaller"]["icon"][str(self.settings.os)])).replace("\\", "\\\\"),
|
||||||
entitlements_file = entitlements_file if self.settings.os == "Macos" else "None")
|
entitlements_file = entitlements_file if self.settings.os == "Macos" else "None")
|
||||||
|
|
||||||
def imports(self):
|
def imports(self):
|
||||||
|
@ -343,10 +340,9 @@ echo "CURA_VERSION_FULL={{ cura_version_full }}" >> ${{ env_prefix }}GITHUB_ENV
|
||||||
self._generate_cura_version(Path(self._site_packages, "cura"))
|
self._generate_cura_version(Path(self._site_packages, "cura"))
|
||||||
|
|
||||||
entitlements_file = "'{}'".format(Path(self.cpp_info.res_paths[2], "dmg", "cura.entitlements"))
|
entitlements_file = "'{}'".format(Path(self.cpp_info.res_paths[2], "dmg", "cura.entitlements"))
|
||||||
channel = "" if not self.channel else self.channel
|
|
||||||
self._generate_pyinstaller_spec(location = self._base_dir,
|
self._generate_pyinstaller_spec(location = self._base_dir,
|
||||||
entrypoint_location = "'{}'".format(Path(self.cpp_info.bin_paths[0], self._um_data(self.version, channel)["runinfo"]["entrypoint"])).replace("\\", "\\\\"),
|
entrypoint_location = "'{}'".format(Path(self.cpp_info.bin_paths[0], self._um_data()["runinfo"]["entrypoint"])).replace("\\", "\\\\"),
|
||||||
icon_path = "'{}'".format(Path(self.cpp_info.res_paths[2], self._um_data(self.version, channel)["pyinstaller"]["icon"][str(self.settings.os)])).replace("\\", "\\\\"),
|
icon_path = "'{}'".format(Path(self.cpp_info.res_paths[2], self._um_data()["pyinstaller"]["icon"][str(self.settings.os)])).replace("\\", "\\\\"),
|
||||||
entitlements_file = entitlements_file if self.settings.os == "Macos" else "None")
|
entitlements_file = entitlements_file if self.settings.os == "Macos" else "None")
|
||||||
|
|
||||||
def package(self):
|
def package(self):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue