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

onnxruntime: ensure conan dependencies are used when versions are overriden #22155

Closed

Conversation

fdgStilla
Copy link
Contributor

Fix #22153


@fdgStilla fdgStilla changed the title CMake: ensure conan dependencies are used when versions are overriden onnxruntime: ensure conan dependencies are used when versions are overriden Jan 4, 2024
@valgur
Copy link
Contributor

valgur commented Jan 4, 2024

#20619 kind of already does the same by rewriting onnxruntime_external_deps.cmake entirely with a custom version.

@fdgStilla
Copy link
Contributor Author

fdgStilla commented Jan 4, 2024

@valgur I still see a harcoded version of the Protobuf in your new cmake file: find_package(Protobuf 3.21.12 REQUIRED CONFIG), shall we remove this and only rely on the version given by conan (if the version shall not be changed I guess it shall be in the validate method)

@conan-center-bot conan-center-bot added Failed Unexpected Error Missing dependencies Build failed due missing dependencies in Conan Center labels Jan 4, 2024
@conan-center-bot

This comment has been minimized.

@AbrilRBS
Copy link
Member

AbrilRBS commented Jan 7, 2024

Regenerating missing binaries now

@conan-center-bot conan-center-bot removed the Missing dependencies Build failed due missing dependencies in Conan Center label Jan 9, 2024
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

Copy link
Member

@AbrilRBS AbrilRBS left a comment

Choose a reason for hiding this comment

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

Hi! Sorry that this took so long to get addressed. As far as I can see these changes are looking good. If the recipe ever needs to ensure a version range for these dependencies, it should check it in its validate method :)

@conan-center-bot

This comment has been minimized.

@perseoGI
Copy link
Contributor

perseoGI commented Jun 6, 2024

Hi! Sorry that this took so long to get addressed. As far as I can see these changes are looking good. If the recipe ever needs to ensure a version range for these dependencies, it should check it in its validate method :)

Hi @fdgStilla, thanks for your contribution, could you confirm the library does not need those fixed dependency versions?

@perseoGI perseoGI self-assigned this Jun 6, 2024
@fdgStilla
Copy link
Contributor Author

We currently use the recipe with this change and we have been using this configuration for the last 6 months:

  • protobuf/3.21.12
  • onnxruntime/1.14.1
  • nlohmann_json/3.9.1
  • ms-gsl/4.0.0

I think I remember that it was not possible to change the major version of gsl to 3, I did not try to change the major version for the other versions, but we could improve the validate method in another PR. Currently onnxruntime is very difficult to integrate to a project because of the fixed version in the cmake.

@perseoGI
Copy link
Contributor

perseoGI commented Jun 6, 2024

Okey, thanks for your fast and your empirical proof, I'm approving this PR.
As you said, in the future we can add more validations on this recipe.

@conan-center-bot conan-center-bot added Failed Missing dependencies Build failed due missing dependencies in Conan Center labels Jun 7, 2024
@conan-center-bot

This comment has been minimized.

@AbrilRBS
Copy link
Member

AbrilRBS commented Jun 7, 2024

Biulding missing binary now

@conan-center-bot
Copy link
Collaborator

Conan v1 pipeline ❌

Failure in build 4 (d426715c16efe064748c6a11275299d74e5b6127):

  • onnxruntime/1.16.3:
    CI failed to create some packages (All logs)

    Logs for packageID 42ad6c6586243c991d33aa4848938d3f6c5f197e:
    [settings]
    arch=x86_64
    build_type=Release
    compiler=gcc
    compiler.libcxx=libstdc++11
    compiler.version=9
    os=Linux
    [options]
    onnxruntime:shared=False
    
    [...]
        libcurl/8.8.0 from 'conan-center' - Cache
        ms-gsl/4.0.0 from 'conan-center' - Cache
        nlohmann_json/3.11.3 from 'conan-center' - Cache
        nsync/1.26.0 from 'conan-center' - Cache
        onnx/1.14.1 from 'conan-center' - Cache
        onnxruntime/1.16.3 from local cache - Cache
        openssl/3.2.2 from 'conan-center' - Cache
        protobuf/3.21.12 from 'conan-center' - Cache
        re2/20230901 from 'conan-center' - Cache
        safeint/3.0.28 from 'conan-center' - Cache
        zlib/1.3.1 from 'conan-center' - Cache
    Packages
        abseil/20230802.1:b911f48570f9bb2902d9e83b2b9ebf9d376c8c56 - Download
        boost/1.83.0:ca891ed5c8e67ebb3e46639c100abdbca6d8b11e - Download
        bzip2/1.0.8:da606cf731e334010b0bf6e85a2a6f891b9f36b0 - Download
        cpuinfo/cci.20220618:68e6d7e93c8e2d1ca7d95689466cf63505529801 - Missing
        date/3.0.1:ee9dcfcc59d53340e130061169bad6431f37f10a - Download
        eigen/3.4.0:5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9 - Download
        flatbuffers/1.12.0:b911f48570f9bb2902d9e83b2b9ebf9d376c8c56 - Download
        libbacktrace/cci.20210118:6af9cc7cb931c5ad942174fd7838eb655717c709 - Download
        libcurl/8.8.0:79e4453c31472bfa2b9abed8a11038ea5426b569 - Download
        ms-gsl/4.0.0:5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9 - Download
        nlohmann_json/3.11.3:5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9 - Download
        nsync/1.26.0:b911f48570f9bb2902d9e83b2b9ebf9d376c8c56 - Download
        onnx/1.14.1:e272cba8022306b484e574fde780c94d29178f8c - Download
        onnxruntime/1.16.3:42ad6c6586243c991d33aa4848938d3f6c5f197e - Download
        openssl/3.2.2:3b92fb92d86b5880d7fcd3124cd3e37e04f7e25f - Download
        protobuf/3.21.12:7627fae1426bcc12a67dba7c7207b1bccf05e5fd - Download
        re2/20230901:71f75a619d45053abca4de3cee3a13da04027e8d - Download
        safeint/3.0.28:5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9 - Download
        zlib/1.3.1:6af9cc7cb931c5ad942174fd7838eb655717c709 - Download
    
    Installing (downloading, building) binaries...
    
    WARN: *** Conan 1 is legacy and on a deprecation path ***
    WARN: *** Please upgrade to Conan 2 ***
    WARN: openssl/3.2.2: requirement zlib/[>=1.2.11 <2] overridden by libcurl/8.8.0 to zlib/1.3.1 
    ERROR: Missing binary: cpuinfo/cci.20220618:68e6d7e93c8e2d1ca7d95689466cf63505529801
    cpuinfo/cci.20220618: WARN: Can't find a 'cpuinfo/cci.20220618' package for the specified settings, options and dependencies:
    - Settings: arch=x86_64, build_type=Release, compiler=gcc, compiler.version=9, os=Linux
    - Options: fPIC=True, log_level=default, shared=False
    - Dependencies: 
    - Requirements: 
    - Package ID: 68e6d7e93c8e2d1ca7d95689466cf63505529801
    
    ERROR: Missing prebuilt package for 'cpuinfo/cci.20220618'
    Use 'conan search cpuinfo/cci.20220618@ --table=table.html -r=remote' and open the table.html file to see available packages
    Or try to build locally from sources with '--build=cpuinfo'
    
    More Info at 'https://docs.conan.io/en/latest/faq/troubleshooting.html#error-missing-prebuilt-package'
    
  • onnxruntime/1.16.1:
    Didn't run or was cancelled before finishing

  • onnxruntime/1.16.2:
    Didn't run or was cancelled before finishing

  • onnxruntime/1.16.0:
    Didn't run or was cancelled before finishing

  • onnxruntime/1.15.1:
    Didn't run or was cancelled before finishing

  • onnxruntime/1.14.1:
    Didn't run or was cancelled before finishing


Note: To save resources, CI tries to finish as soon as an error is found. For this reason you might find that not all the references have been launched or not all the configurations for a given reference. Also, take into account that we cannot guarantee the order of execution as it depends on CI workload and workers availability.

@czoido
Copy link
Contributor

czoido commented Aug 21, 2024

Hi @fdgStilla,
Thanks a lot for the contribution. I think this should have been fixed after merging #23409
Please, have a look. I'm closing this as solved but please feel free to reopen or open an issue if you have any more questions.

@czoido czoido closed this Aug 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Failed Missing dependencies Build failed due missing dependencies in Conan Center
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[onnxruntime] build fails if we override the nlohmann_json/protobuf/gsl version
6 participants