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

include could not find load file: RezBuild error on Windows #974

Open
spsalefeve opened this issue Nov 11, 2020 · 1 comment
Open

include could not find load file: RezBuild error on Windows #974

spsalefeve opened this issue Nov 11, 2020 · 1 comment
Labels
bug cmake CMake builds

Comments

@spsalefeve
Copy link
Contributor

spsalefeve commented Nov 11, 2020

We're currently using an old version of rez (2.49.0) and would like to update to 2.68.4. Everything wees to be fine with the new version on Linux, but we can't build with Cmake anymore on Windows.
The first error is:

CMake Error at CMakeLists.txt:7 (include):
  include could not find load file:

    RezBuild

and other error follows indicating the Rez environment variables for Cmake are not set.
It appears the reasons for this error are:

  • our cmake package has visualstudio in its build_requires
  • our visualstudio contains the following code:
 if building:
        cmd = 'call "{executable}" x64'
        cmd = cmd.format(executable=os.path.join(expandvars("{root}"), "bin", "msvcEnv.bat"))
        command(cmd)
  • rez now sets the build environment in post_actions_callback instead of actions_callback and it's too late

Would it be reasonable to use again actions_callback at this line when building?
Or do yo know any other way to run cmake via rez on Windows?
I tried to use vswhere as mentionned here but it doesn't return any installPath.

Pull Request

@spsalefeve
Copy link
Contributor Author

Hello,
Could this PR be merged? It would enable us to update our very old rez on Windows!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug cmake CMake builds
Projects
None yet
Development

No branches or pull requests

2 participants