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

[bug] "ERROR: win_bash=True but tools.microsoft.bash:subsystem configuration not defined" even though it's defined by a build requirement #15317

Closed
SpaceIm opened this issue Dec 21, 2023 · 4 comments · Fixed by #15319
Assignees
Milestone

Comments

@SpaceIm
Copy link
Contributor

SpaceIm commented Dec 21, 2023

Environment details

  • Operating System+version: Windows 11
  • Compiler+version: MinGW GCC 13.2.0
  • Conan version: 2.0.15
  • Python version: 3.11.1

Steps to reproduce

conan install --requires libcurl/8.4.0 -b missing

Logs

libcurl/8.4.0: Sources downloaded from 'conancenter'
ERROR: win_bash=True but tools.microsoft.bash:subsystem configuration not defined
@SpaceIm
Copy link
Contributor Author

SpaceIm commented Dec 21, 2023

It's worth noting that libcurl recipe defines self.win_bash=True in build requirements if Windows and not msvc, and adds msys2 to build requirements in this case if tools.microsoft.bash:path is not defined (and I don't define this conf in my profile, command line or global.conf). msys2 defines tools.microsoft.bash:subsystem in its package_info(), so it shouldn't fail, and actually it didn't fail before conan 2.0.15 (just tested again with conan 2.0.14, and it builds fine).

https://github.com/conan-io/conan-center-index/blob/cc5692484d667b48e10aec754d498379f2e3ed71/recipes/libcurl/all/conanfile.py#L213-L216

All conancenter recipes which need a shell at build time on Windows rely on this pattern, so it could break many recipes.

@memsharded memsharded added this to the 2.0.16 milestone Dec 21, 2023
@SpaceIm SpaceIm changed the title [bug] ERROR: win_bash=True but tools.microsoft.bash:subsystem configuration not defined [bug] "ERROR: win_bash=True but tools.microsoft.bash:subsystem configuration not defined" even though it's defined by a build requirement Dec 21, 2023
@memsharded memsharded self-assigned this Dec 21, 2023
@memsharded
Copy link
Member

memsharded commented Dec 21, 2023

I have just tried with my profile:

[settings]
os=Windows
compiler=gcc
compiler.version=11
compiler.libcxx=libstdc++11
arch=x86_64
build_type=Release


[buildenv]
PATH=+(path)C:\ws\msys64\mingw64\bin

And it didn't fail. Update: it doesnt fail in libcurl, it fails in openssl build

@fdgStilla
Copy link
Contributor

I get the same error from a fresh conan install in CI with another package: openh264

But after playing with a little with the conan version from/to 2.0.14 and 2.0.15, now I don't have the issue even with the last version of conan 2.0.15...

@memsharded
Copy link
Member

We are considering a revert or a fix asap, keep tuned.

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

Successfully merging a pull request may close this issue.

3 participants