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] latest conan 2.3.0-git does not install fftw #16166

Closed
mmomtchev opened this issue Apr 27, 2024 · 2 comments · Fixed by conan-io/conan-center-index#23792
Closed

[bug] latest conan 2.3.0-git does not install fftw #16166

mmomtchev opened this issue Apr 27, 2024 · 2 comments · Fixed by conan-io/conan-center-index#23792

Comments

@mmomtchev
Copy link

Describe the bug

Ubuntu 22.04, Python 3.10, latest conan git

How to reproduce it

pip install git+https://github.com/conan-io/conan
conan install --requires fftw/3.3.10 --build='*'
-------- Installing package fftw/3.3.10 (1 of 1) --------
fftw/3.3.10: Building from source
fftw/3.3.10: Package fftw/3.3.10:80a0f31ebf64b0a37a0c0545fe0f924772616e2c
fftw/3.3.10: Copying sources to build folder
fftw/3.3.10: Building your package in /home/mmom/.conan2/p/b/fftw5da396d5fe88f/b
fftw/3.3.10: Calling generate()
fftw/3.3.10: Generators folder: /home/mmom/.conan2/p/b/fftw5da396d5fe88f/b/build/Release/generators
fftw/3.3.10: CMakeToolchain generated: conan_toolchain.cmake
fftw/3.3.10: CMakeToolchain generated: /home/mmom/.conan2/p/b/fftw5da396d5fe88f/b/build/Release/generators/CMakePresets.json
fftw/3.3.10: CMakeToolchain generated: /home/mmom/.conan2/p/b/fftw5da396d5fe88f/b/src/CMakeUserPresets.json
fftw/3.3.10: Generating aggregated env files
fftw/3.3.10: Generated aggregated env files: ['conanbuild.sh', 'conanrun.sh']
fftw/3.3.10: Calling build()
fftw/3.3.10: apply_conandata_patches(): No patches defined in conandata
fftw/3.3.10: Running CMake.configure()
fftw/3.3.10: RUN: cmake -G "Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE="generators/conan_toolchain.cmake" -DCMAKE_INSTALL_PREFIX="/home/mmom/.conan2/p/b/fftw5da396d5fe88f/p" -DCMAKE_POLICY_DEFAULT_CMP0091="NEW" -DCMAKE_BUILD_TYPE="Release" -DENABLE_FLOAT="ON" -DENABLE_LONG_DOUBLE="OFF" -DENABLE_QUAD_PRECISION="OFF" "/home/mmom/.conan2/p/b/fftw5da396d5fe88f/b/src"
CMake Error at /usr/share/cmake-3.22/Modules/CMakeDetermineSystem.cmake:130 (message):
  Could not find toolchain file: generators/conan_toolchain.cmake
Call Stack (most recent call first):
  CMakeLists.txt:7 (project)


CMake Error: CMake was unable to find a build program corresponding to "Unix Makefiles".  CMAKE_MAKE_PROGRAM is not set.  You probably need to select a different build tool.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!

fftw/3.3.10: ERROR: 
Package '80a0f31ebf64b0a37a0c0545fe0f924772616e2c' build failed
fftw/3.3.10: WARN: Build folder /home/mmom/.conan2/p/b/fftw5da396d5fe88f/b/build/Release/single
ERROR: fftw/3.3.10: Error in build() method, line 117
	cmake.configure(variables=variables)
	ConanException: Error 1 while executing

conan is not in the right directory - there is a single subdirectory.

conan 2.2.3 installs this package.

@memsharded
Copy link
Member

Thanks for reporting this @mmomtchev

It seems that this recipe is overriding the build_folder:

@property
    def build_folder(self):
        bf = super().build_folder
        return os.path.join(bf, self._current_precision) if self._current_precision else bf

I think this is not allowed. The Conan attributes are not modifiable/overrideables from user side: https://docs.conan.io/2/reference/conanfile.html

Public attributes and methods, like build(), self.package_folder, are reserved for Conan. Don’t use public members for custom fields or methods in the recipes.

So far this seems a recipe bug. I guess this doesn't happen with other ConanCenter recipes, does it?

@memsharded
Copy link
Member

It was a recipe issue, solved by conan-io/conan-center-index#23792

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.

2 participants