Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

qt/5.15.2 #1759

Merged
merged 62 commits into from
Jan 27, 2021
Merged

qt/5.15.2 #1759

merged 62 commits into from
Jan 27, 2021

Conversation

ericLemanissier
Copy link
Contributor

@ericLemanissier ericLemanissier commented May 27, 2020

Specify library name and version: qt/5.15.2

this is a port of https://github.com/bincrafters/conan-qt/

  • I've read the guidelines for contributing.
  • I've followed the PEP8 style guides for Python code in the recipes.
  • I've used the latest Conan client version.
  • I've tried at least one configuration locally with the
    conan-center hook activated.

@conan-center-bot
Copy link
Collaborator

Some configurations of 'qt/5.15.0' failed in build 1 (a20703a5fd2695390df5dfc7b723f2e0f4402e95):

  • Linux x86_64, Release, gcc 5, libstdc++ . Options: qt:shared-True
    • Hooks errors detected:
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] The *.cmake files have to be placed in a folder declared as cpp_info.builddirs. Currently folders declared: [''] (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H019)
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] Found files:
      • [HOOK - conan-center.py] post_package(): ERROR: [DEFAULT PACKAGE LAYOUT (KB-H013)] Unknown folder 'doc' in the package (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H013)
      • [HOOK - conan-center.py] post_package(): ERROR: [DEFAULT PACKAGE LAYOUT (KB-H013)] Unknown folder 'plugins' in the package (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H013)
      • [HOOK - conan-center.py] post_package(): ERROR: [DEFAULT PACKAGE LAYOUT (KB-H013)] Unknown folder 'mkspecs' in the package (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H013)
    • Log download
    • Log error Download
    • Profile
  • Access to all the logs

@conan-center-bot
Copy link
Collaborator

Some configurations of 'qt/5.15.0' failed in build 2 (6e78c115b89b17bf7b9eaeb07e64d18f3dda9da4):

  • Linux x86_64, Release, gcc 5, libstdc++ . Options: qt:shared-True
    • Hooks errors detected:
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] The *.cmake files have to be placed in a folder declared as cpp_info.builddirs. Currently folders declared: [''] (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H019)
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] Found files:
      • [HOOK - conan-center.py] post_package(): ERROR: [DEFAULT PACKAGE LAYOUT (KB-H013)] Unknown folder 'doc' in the package (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H013)
      • [HOOK - conan-center.py] post_package(): ERROR: [DEFAULT PACKAGE LAYOUT (KB-H013)] Unknown folder 'plugins' in the package (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H013)
      • [HOOK - conan-center.py] post_package(): ERROR: [DEFAULT PACKAGE LAYOUT (KB-H013)] Unknown folder 'mkspecs' in the package (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H013)
    • Log download
    • Log error Download
    • Profile
  • Access to all the logs

@rweickelt
Copy link

@ericLemanissier:

Regarding DEFAULT_PACKAGE_LAYOUT:

  • you can use the configure option -plugindir (almost all top-level folders are configurable)
  • the mkspecs folder is not configurable. Do you have an idea?
  • doc folder should not be included in the package

Regarding CMAKE FILE NOT IN BUILD FOLDERS: Would it be enough to add lib/cmake to cpp_info.builddirs or is it required to list all leaf folders explicitly?

@conan-center-bot
Copy link
Collaborator

Some configurations of 'qt/5.15.0' failed in build 3 (fa16fd056a933bd43ffe51664075fa62b2a9812e):

  • Linux x86_64, Release, gcc 5, libstdc++ . Options: qt:shared-True
    • Hooks errors detected:
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] The *.cmake files have to be placed in a folder declared as cpp_info.builddirs. Currently folders declared: [''] (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H019)
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] Found files:
    • Log download
    • Log error Download
    • Profile
  • Access to all the logs

@rweickelt rweickelt mentioned this pull request May 28, 2020
@conan-center-bot
Copy link
Collaborator

Some configurations of 'qt/5.15.0' failed in build 4 (d9a8e89381ed6d5f7ba477f4bb4c74d9f32f4a5c):

  • Linux x86_64, Release, gcc 5, libstdc++ . Options: qt:shared-True
    • Hooks errors detected:
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] The *.cmake files have to be placed in a folder declared as cpp_info.builddirs. Currently folders declared: [''] (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H019)
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] Found files:
    • Log download
    • Log error Download
    • Profile
  • Access to all the logs

@conan-center-bot
Copy link
Collaborator

Some configurations of 'qt/5.15.0' failed in build 5 (773e22e721d234f47d7e67b2200727c3fe7997cc):

  • Linux x86_64, Release, gcc 5, libstdc++ . Options: qt:shared-True
    • Hooks errors detected:
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] The *.cmake files have to be placed in a folder declared as cpp_info.builddirs. Currently folders declared: [''] (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H019)
      • [HOOK - conan-center.py] post_package_info(): ERROR: [CMAKE FILE NOT IN BUILD FOLDERS (KB-H019)] Found files:
    • Log download
    • Log error Download
    • Profile
  • Access to all the logs

@conan-center-bot
Copy link
Collaborator

Failure in build 6 (badf9f845e62cc1a5d8ec2f3b2b433e5091c2f28):
qt/5.15.0:

  • Error processing recipe: Linux x86_64, Release, gcc 5, libstdc++ . Options: qt:shared-True
    Unexpected error happened:
ERROR: qt/5.15.0: Error in config_options() method, line 182
	raise self.ConanInvalidConfiguration('Linux is not yet supported')
	AttributeError: 'QtConan' object has no attribute 'ConanInvalidConfiguration'

@conan-center-bot
Copy link
Collaborator

Some configurations of 'qt/5.15.0' failed in build 7 (756e0d1a975fbe1658b19b1cad9c31706ff3c16f):

  • Macos x86_64, Debug, apple-clang 9.1, libc++ . Options: qt:shared-True
  • Access to all the logs
  • Windows x86_64, Debug, Visual Studio 14, MTd. Options: qt:shared-False
    • Hooks errors detected:
      • [HOOK - conan-center.py] post_package(): ERROR: [PDB FILES NOT ALLOWED (KB-H017)] The conan-center repository doesn't allow PDB files (https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#KB-H017)
      • [HOOK - conan-center.py] post_package(): ERROR: [PDB FILES NOT ALLOWED (KB-H017)] Found files:
    • Log download
    • Log error Download
    • Profile
  • Access to all the logs

@conan-center-bot
Copy link
Collaborator

Some configurations of 'qt/5.15.0' failed in build 8 (9aeaec5f6ea5bec59aa90348406660f183907cbf):

@conan-center-bot
Copy link
Collaborator

All green in build 9 (7fb2b46478248648ee396a7f0172a42c997e33d4)! 😊

@ericLemanissier
Copy link
Contributor Author

So it seems I could successfully move mkspecs, plugins etc to the bin folder using -archdatadir -datadir and -sysconfdir arguments.
Regarding cmake, I simply deleted all the files, because they would be flagged by https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#kb-h016-cmake-modules-config-files. we probably want to add qt to the exceptions to this rule, otherwise there is no way to consume this package from cmake.
I keep the draft status for this PR, because it cannot be built under linux until #1605 is merged, but the PR is otherwise open for reviews.

@rweickelt
Copy link

Regarding cmake, I simply deleted all the files, because they would be flagged by https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#kb-h016-cmake-modules-config-files. we probably want to add qt to the exceptions to this rule, otherwise there is no way to consume this package from cmake

It can be consumed just fine with Qbs. Joke aside, I thought that the rule is to add all folders containing .cmake files into cpp_info.builddirs. Does that not work here?

I keep the draft status for this PR, because it cannot be built under linux until #1605 is merged, but the PR is otherwise open for reviews.

👍

@ericLemanissier
Copy link
Contributor Author

https://github.com/conan-io/conan-center-index/wiki/Error-Knowledge-Base#kb-h016-cmake-modules-config-files says The binary package cannot contain module or config CMake files ("Find*.cmake", "Config.cmake", "-config.cmake"). and it is what the hook enforces: https://github.com/conan-io/hooks/blob/master/hooks/conan-center.py#L614-L625
The only way out is to be added to the exclusion list

@conan-center-bot
Copy link
Collaborator

An unexpected error happened and has been reported. Help is on its way! 🏇

@danimtb
Copy link
Member

danimtb commented Jan 27, 2021

relaunched

@conan-center-bot
Copy link
Collaborator

All green in build 74 (0c10c0cf75e0547c134515b78999d799b407dc41)! 😊

if not self.options.shared:
args.insert(0, "-static")
if self.settings.compiler == "Visual Studio":
if self.settings.compiler.runtime == "MT" or self.settings.compiler.runtime == "MTd":
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if self.settings.compiler.runtime == "MT" or self.settings.compiler.runtime == "MTd":
if str(self.settings.compiler.runtime) in ["MT", "MTd"]:

Copy link
Member

@uilianries uilianries left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great Job! The most complex recipe that we have so far

@conan-center-bot conan-center-bot merged commit 322994b into conan-io:master Jan 27, 2021
@intelligide
Copy link
Contributor

@ericLemanissier
Copy link
Contributor Author

Many thanks to all reviewers, contributors, and also thanks to @osechet and @lucienboillod who did the early work on this recipe !

image
(for qt 6)

@boussaffawalid
Copy link
Contributor

I tried to run conan install qt/5.15.2@ and I got the error

ERROR: qt/5.15.2: Error in configure() method, line 233
        config.read(os.path.join(self.recipe_folder, "qtmodules%s.conf" % self.version))
        AttributeError: 'QtConan' object has no attribute 'recipe_folder'

@ericLemanissier
Copy link
Contributor Author

are you running conan < 1.28.0 ?

@boussaffawalid
Copy link
Contributor

@ericLemanissier yes, I updated to latest conan version and now it works. Thanks!
Maybe as an improvement, add a check for the minimum required conan version.

@ericLemanissier
Copy link
Contributor Author

Well, required_conan_version was implemented in conan 1.28.0 too, so adding required_conan_version = ">=1.28.0" does not make much sense (other than documentation)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infrastructure Waiting on tools or services belonging to the infra
Projects
None yet
Development

Successfully merging this pull request may close these issues.