Creating Qt6 anaconda package always errors out
-
I am trying to package up our Qt6 based application using conda-build. The issue that I think I am running into is this warning message during the conda-build process.
This occurs on macOS systems probably because those tools are in an .app bundle instead of stand alone .exe like on Linunx and Windows. Is there any hope for a fix?
I can temporarily turn off the testing phase of the packaging but I would rather not do that.
WARNING: The install/build script(s) for simplnx deleted the following files (from dependencies) from the prefix: ['bin/Linguist6', 'bin/Assistant6', 'bin/qdbusviewer6', 'bin/pixeltool6', 'bin/Designer6'] This will cause the post-link checks to mis-report. Please try not to delete and files (DSOs in particular) from the prefix
and later on I then get this "test" failure.
I have looked through “conda” trying to find out how to put those dependencies in but at the moment I can’t even find a conda package that would install QtDesigner, QtAssistant and the other “missing” libraries. This is on macOS (intel and silicon variants). It seems to be happy on Windows.
I’ve tried all sorts of versions of conda, conda-build, mamba, boa, conda-build. Different versions of Qt6 (6.5.x and 6.6).
I’m not sure if this is a bug somewhere, user error on my part or how to fix this issue. The repo is at GitHub - BlueQuartzSoftware/simplnx: The backend algorithms and framework associated with DREAM3DNX, a data analysis program for materials science data analytics and the recipe directory is in the top level “conda” directory.
Thanks to anyone who might be able to shed some light on what I am probably doing wrong.
-
Hi and welcome to devnet,
Is Qt 6 a dependency of a dependency ? There's no mention of it in the recipe.
-
No. It is a direct dependency of our application. Our Meta.yaml looks like this:
{% set name = "DREAM3DNX" %} {% set version = "0.0.1" %} package: name: {{ name|lower }} version: {{ version }} source: - path: ../../simplnx folder: simplnx - git_url: https://github.com/BlueQuartzSoftware/EbsdLib git_rev: v1.0.26 folder: EbsdLib - git_url: https://github.com/BlueQuartzSoftware/H5Support git_rev: v1.0.13 folder: H5Support - git_url: https://github.com/martinmoene/expected-lite git_rev: v0.5.0 folder: expected-lite - git_url: https://github.com/fr00b0/nod git_rev: v0.5.2 folder: nod - git_url: https://github.com/martinmoene/span-lite git_rev: v0.10.3 folder: span-lite - url: https://raw.githubusercontent.com/BlueQuartzSoftware/simplnx-registry/9a5db7b5fa02b2495eb51654cbaab3c63820c779/ports/nod/CMakeLists.txt folder: nod - git_url: https://gitlab.kitware.com/vtk/vtk.git git_rev: v9.2.6 folder: vtk - git_url: https://github.com/insightsoftwareconsortium/ITK git_rev: v5.2.1 folder: itk - path: ../ folder: DREAM3DNX build: number: 0 script_env: - SIMPLNX_CMAKE_PRESET=conda-win # [win] - SIMPLNX_CMAKE_PRESET=conda-linux # [linux] - SIMPLNX_CMAKE_PRESET=conda-osx # [osx] - DREAM3DNX_OPTIONAL_SUFFIX=-Conda-{{ version }} - ITK_VERSION=5.2.1 requirements: build: - {{ compiler('cxx') }} - cmake >=3.19 - ninja - git host: - python {{ python }} - numpy >=1.16 - mypy - boost_mp11 - eigen - fmt =10 - hdf5 =1.12 - nlohmann_json - pybind11 >=2.10 - reproc-cpp - tbb - tbb-devel - zlib - sphinx - myst-parser - sphinx-markdown-tables - sphinx_rtd_theme - qt6-main =6.5.3 run: - python - numpy - fmt =10 - hdf5 =1.12 - reproc-cpp - tbb - zlib - qt6-main =6.5.3 about: home: https://www.dream3d.io/ license: Proprietary summary: DREAM3D-NX consists of data analysis tools (Filters) that allow for the construction of customized workflows (Pipelines) to analyze data.
-
I'm no expert in the anaconda or conda-forge ecosystem but where ever during the "conda install qt6-main" process that the sym links to the various Qt tools (Designer, Assistant and such) happens, those symlinks are not properly taken into account. Or maybe it is in the recipe to build the qt6-main package? At some point these symlinks are being created incorrectly.
I wonder if I can just create the proper symlinks as part of my build script, just to get by for now until this is tracked down.
-
I was able to add the following to the build.sh file:
if [[ $target_platform == osx-* ]]; then rm $PREFIX/bin/Linguist6 ln -s ../lib/qt6/bin/Linguist.app/Contents/MacOS/Assistant $PREFIX/bin/Linguist6 rm $PREFIX/bin/Assistant6 ln -s ../lib/qt6/bin/Assistant.app/Contents/MacOS/Assistant $PREFIX/bin/Assistant6 rm $PREFIX/bin/qdbusviewer6 ln -s ../lib/qt6/bin/qdbusviewer.app/Contents/MacOS/qdbusviewer $PREFIX/bin/qdbusviewer6 rm $PREFIX/bin/pixeltool6 ln -s ../lib/qt6/bin/pixeltool.app/Contents/MacOS/pixeltool $PREFIX/bin/pixeltool6 rm $PREFIX/bin/Designer6 ln -s ../lib/qt6/bin/Designer.app/Contents/MacOS/Designer $PREFIX/bin/Designer6 fi
This seemed to have cleared up the "test" failure issues. Just would like to track down how the symlinks are being created in the first place.
-
I was able to add the following to the build.sh file:
if [[ $target_platform == osx-* ]]; then rm $PREFIX/bin/Linguist6 ln -s ../lib/qt6/bin/Linguist.app/Contents/MacOS/Assistant $PREFIX/bin/Linguist6 rm $PREFIX/bin/Assistant6 ln -s ../lib/qt6/bin/Assistant.app/Contents/MacOS/Assistant $PREFIX/bin/Assistant6 rm $PREFIX/bin/qdbusviewer6 ln -s ../lib/qt6/bin/qdbusviewer.app/Contents/MacOS/qdbusviewer $PREFIX/bin/qdbusviewer6 rm $PREFIX/bin/pixeltool6 ln -s ../lib/qt6/bin/pixeltool.app/Contents/MacOS/pixeltool $PREFIX/bin/pixeltool6 rm $PREFIX/bin/Designer6 ln -s ../lib/qt6/bin/Designer.app/Contents/MacOS/Designer $PREFIX/bin/Designer6 fi
This seemed to have cleared up the "test" failure issues. Just would like to track down how the symlinks are being created in the first place.
@imikejackson are you sure your Linguist line is correct ?
For the original symlinks creation, I would check the qt6-main recipe.
-
@imikejackson are you sure your Linguist line is correct ?
For the original symlinks creation, I would check the qt6-main recipe.
if [[ $target_platform == osx-* ]]; then rm $PREFIX/bin/Linguist6 ln -s ../lib/qt6/bin/Linguist.app/Contents/MacOS/Assistant $PREFIX/bin/Linguist rm $PREFIX/bin/Assistant6 ln -s ../lib/qt6/bin/Assistant.app/Contents/MacOS/Assistant $PREFIX/bin/Assistant6 rm $PREFIX/bin/qdbusviewer6 ln -s ../lib/qt6/bin/qdbusviewer.app/Contents/MacOS/qdbusviewer $PREFIX/bin/qdbusviewer6 rm $PREFIX/bin/pixeltool6 ln -s ../lib/qt6/bin/pixeltool.app/Contents/MacOS/pixeltool $PREFIX/bin/pixeltool6 rm $PREFIX/bin/Designer6 ln -s ../lib/qt6/bin/Designer.app/Contents/MacOS/Designer $PREFIX/bin/Designer6 fi
-
if [[ $target_platform == osx-* ]]; then rm $PREFIX/bin/Linguist6 ln -s ../lib/qt6/bin/Linguist.app/Contents/MacOS/Assistant $PREFIX/bin/Linguist rm $PREFIX/bin/Assistant6 ln -s ../lib/qt6/bin/Assistant.app/Contents/MacOS/Assistant $PREFIX/bin/Assistant6 rm $PREFIX/bin/qdbusviewer6 ln -s ../lib/qt6/bin/qdbusviewer.app/Contents/MacOS/qdbusviewer $PREFIX/bin/qdbusviewer6 rm $PREFIX/bin/pixeltool6 ln -s ../lib/qt6/bin/pixeltool.app/Contents/MacOS/pixeltool $PREFIX/bin/pixeltool6 rm $PREFIX/bin/Designer6 ln -s ../lib/qt6/bin/Designer.app/Contents/MacOS/Designer $PREFIX/bin/Designer6 fi
-
Thanks for the links !