# Spack Build Error Message with nvhpc compiler

**URL:** https://gromacs.bioexcel.eu/t/spack-build-error-message-with-nvhpc-compiler/8968
**Category:** User discussions
**Created:** [April 23, 2024, 3:09pm UTC](https://gromacs.bioexcel.eu/t/spack-build-error-message-with-nvhpc-compiler/8968 "2024-04-23T15:09:36Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![br-kolgu](https://avatars.discourse-cdn.com/v4/letter/b/b782af/32.png) [@br-kolgu](https://gromacs.bioexcel.eu/u/br-kolgu)
#### Post date: [April 23, 2024, 3:09pm UTC](https://gromacs.bioexcel.eu/t/spack-build-error-message-with-nvhpc-compiler/8968/1 "2024-04-23T15:09:36Z")

</div>

GROMACS version: 2023.2  
GROMACS modification: No  
Here post your question  
Hi,  
I am trying to build gromacs with spack ( spack install gromacs%nvhpc +mpi +cuda cuda\_arch={cuda\_arch} +cufftmp) and I have tried nvhpc 23.5 and 24.3 versions and it didn’t build. I am getting the following error message during the build stage :

```auto
==> Installing gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml [30/30]
==> No binary for gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml found: installing from source
==> Using cached archive: /lustre/home/br-kolgu/spack/var/spack/cache/_source-cache/archive/bc/bce1480727e4b2bb900413b75d99a3266f3507877da4f5b2d491df798f9fcdae.tar.gz
==> Ran patch() for gromacs
==> gromacs: Executing phase: 'cmake'
==> gromacs: Executing phase: 'build'
==> Error: ProcessError: Command exited with status 2:
    'make' '-j16'

3 errors found in build log:
     422 NVC++-S-0000-Internal compiler error. c++ specific feature not expected 1 (/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-src/src/exte
            rnal/muparser/src/muParserBase.cpp: 1881)
     423 NVC++-S-0000-Internal compiler error. mkexpr: bad id -9808 (/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-src/src/external/muparser/src/mu
            ParserBase.cpp: 1881)
     424 NVC++-S-0094-Illegal type conversion required (/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-src/src/external/muparser/src/muParserBase.cpp: 
            1881)
     425 NVC++-S-0000-Internal compiler error. mkexpr: bad id -9808 (/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-src/src/external/muparser/src/mu
            ParserBase.cpp: 1881)
     426 NVC++-S-0094-Illegal type conversion required (/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-src/src/external/muparser/src/muParserBase.cpp: 
            1881)
     427 NVC++/x86-64 Linux 23.5-0: compilation completed with severe errors
  >> 428 make[2]: *** [_deps/muparser-build/CMakeFiles/muparser.dir/build.make:93: _deps/muparser-build/CMakeFiles/muparser.dir/src/muParserBase.cpp.o] Error 2
     429 make[2]: Leaving directory '/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-build-egcf5t2'
  >> 430 make[1]: *** [CMakeFiles/Makefile2:4317: _deps/muparser-build/CMakeFiles/muparser.dir/all] Error 2
     431 make[1]: *** Waiting for unfinished jobs....
     432 [3%] Building CXX object src/gromacs/CMakeFiles/thread_mpi.dir/__/external/thread_mpi/src/collective.cpp.o
     433 cd /tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-build-egcf5t2/src/gromacs && /lustre/home/br-kolgu/spack/lib/spack/env/nvhpc/nvc++ -DGMX_DOU
            BLE=0 -DHAVE_CONFIG_H -DTMPI_EXPORTS -DTMPI_USE_VISIBILITY -I/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-src/src/include -I/tmp/br-kolgu/sp
            ack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-build-egcf5t2/src/include -isystem /tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt
            5wuydprml/spack-src/src/external/thread_mpi/include -isystem /lustre/home/br-kolgu/spack/opt/spack/linux-rhel8-zen3/gcc-12.2.0/hwloc-2.9.1-7rs4cnwfpcd7wsnjwssqdgmxbd4cdtwi/include -isyste
            m /tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-src/src/external -isystem /lustre/home/br-kolgu/spack/opt/spack/linux-rhel8-zen3/gcc-12.2.0/f
            ftw-3.3.10-4vhqkrue44d4cbxjd7zt6kwhb6mtnmug/include -fast -O3 -DNDEBUG --c++17 -fPIC -mavx2 -mfma -MD -MT src/gromacs/CMakeFiles/thread_mpi.dir/__/external/thread_mpi/src/collective.cpp.o
             -MF CMakeFiles/thread_mpi.dir/ __/external/thread_mpi/src/collective.cpp.o.d -o CMakeFiles/thread_mpi.dir/__ /external/thread_mpi/src/collective.cpp.o -c /tmp/br-kolgu/spack-stage/spack-st
            age-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-src/src/external/thread_mpi/src/collective.cpp
     434 make[2]: Leaving directory '/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-build-egcf5t2'
     435 [3%] Built target scanner
     436 [3%] Building C object src/gromacs/CMakeFiles/tng_io_obj.dir/__/external/tng_io/src/compression/merge_sort.c.o

     ...

     503 [5%] Built target thread_mpi
     504 make[2]: Leaving directory '/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-build-egcf5t2'
     505 [5%] Built target options
     506 make[2]: Leaving directory '/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-build-egcf5t2'
     507 [5%] Built target tng_io_obj
     508 make[1]: Leaving directory '/tmp/br-kolgu/spack-stage/spack-stage-gromacs-2023.2-egcf5t2p57er6f3ix6ihkxt5wuydprml/spack-build-egcf5t2'
  >> 509 make: *** [Makefile:169: all] Error 2

```

---

<div class="post-metadata">

### Author: ![al42and](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/al42and/32/1393_2.png) [@al42and](https://gromacs.bioexcel.eu/u/al42and)
#### Post date: [April 24, 2024, 7:37pm UTC](https://gromacs.bioexcel.eu/t/spack-build-error-message-with-nvhpc-compiler/8968/2 "2024-04-24T19:37:09Z")

</div>

Hi!

GROMACS 2023 does not support compiling with NVC++. You can still use CUDA and CuFFTMp, just choose a different host compiler.

Building with NVHPC will be [possible](https://gitlab.com/gromacs/gromacs/-/commit/c79343982711d8cd90da856c7fb022c98c51ff5d) in GROMACS 2025, though.
