checking for final PCIACCESS support... yes checking nvml.h usability... no checking nvml.h presence... no checking for nvml.h... no configure: WARNING: Specified --enable-nvml switch, but could not configure: WARNING: find appropriate support configure: error: Cannot continue !!! Please attach the following file when seeking support: !!! /var/tmp/portage/sys-apps/hwloc-2.3.0/work/hwloc-2.3.0-abi_x86_64.amd64/config.log * ERROR: sys-apps/hwloc-2.3.0::gentoo failed (configure phase): * econf failed Reproducible: Always Steps to Reproduce: 1.USE="-cuda nvml" 2.emerge hwloc 3. Actual Results: Works when USE="cuda nvml" Expected Results: USE="nvml" should also require USE="cuda" in ebuild?
It'd be good to still include logs and emerge --info when reporting build failures, but indeed: /opt/cuda/include/nvml.h with USE=cuda: configure:25792: checking nvml.h presence configure:25792: x86_64-pc-linux-gnu-gcc -E -I/opt/cuda/include conftest.c configure:25792: $? = 0 configure:25792: result: yes without: configure:25792: x86_64-pc-linux-gnu-gcc -E conftest.c conftest.c:121:10: fatal error: nvml.h: No such file or directory
(In reply to Ionen Wolkens from comment #1) > It'd be good to still include logs and emerge --info when reporting build > failures, but indeed: > > /opt/cuda/include/nvml.h > > with USE=cuda: > configure:25792: checking nvml.h presence > configure:25792: x86_64-pc-linux-gnu-gcc -E -I/opt/cuda/include conftest.c > configure:25792: $? = 0 > configure:25792: result: yes > > without: > configure:25792: x86_64-pc-linux-gnu-gcc -E conftest.c > conftest.c:121:10: fatal error: nvml.h: No such file or directory Seemed very redundant given the referring bug.
quoting > the NVIDIA Management Library (NVML) for NVML device discovery. > It is included in CUDA since version 8.0. > Older NVML releases were available within the NVIDIA GPU Deployment Kit
Still present in version 2.6.0, as of today.
Created attachment 879007 [details] Sandbox log
Still present in 2.9.2
Hit this yesterday and has taken a while to work out what is going on. Without the cuda USE flag enabled, hwloc does not depend on nvidia-cuda-toolkit which provides nvml.h: # equery f nvidia-cuda-toolkit|grep nvml\.h /opt/cuda/targets/x86_64-linux/include/nvml.h It also will not add /opt/cuda to the compile paths to find it: if use cuda ; then append-cflags "-I${ESYSROOT}/opt/cuda/include" append-cppflags "-I${ESYSROOT}/opt/cuda/include" local -x LDFLAGS="${LDFLAGS}" append-ldflags "-L${ESYSROOT}/opt/cuda/$(get_libdir)" fi so, even if you work out that nvidia-cuda-toolkit is needed and emerge it, it still fails with the above if USE="cuda" is not enabled. There is a further problem on stable profiles where the cuda USE flag is masked. This suggests that, not only should the nvml USE flag require cuda, but the nvml USE flag should also be masked on stable, as with other examples in package.use.stable.mask (e.g. cudnn for media-libs/opencv)