Skip to content

Commit fe4e835

Browse files
committed
Hide/deactivate/warn Toml backend on nvcc compilers
ToruNiina/toml11#205
1 parent bfac95c commit fe4e835

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/config.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,20 +31,28 @@
3131
// @todo add TOML here
3232
std::map<std::string, bool> openPMD::getVariants()
3333
{
34+
// clang-format off
3435
return std::map<std::string, bool>{
3536
{"mpi", bool(openPMD_HAVE_MPI)},
3637
{"json", true},
38+
// https://github.com/ToruNiina/toml11/issues/205
39+
#if !defined(__NVCOMPILER_MAJOR__) || __NVCOMPILER_MAJOR__ >= 23
3740
{"toml", true},
41+
#endif
3842
{"hdf5", bool(openPMD_HAVE_HDF5)},
3943
{"adios1", false},
4044
{"adios2", bool(openPMD_HAVE_ADIOS2)}};
45+
// clang-format on
4146
}
4247

4348
std::vector<std::string> openPMD::getFileExtensions()
4449
{
4550
std::vector<std::string> fext;
4651
fext.emplace_back("json");
52+
// https://github.com/ToruNiina/toml11/issues/205
53+
#if !defined(__NVCOMPILER_MAJOR__) || __NVCOMPILER_MAJOR__ >= 23
4754
fext.emplace_back("toml");
55+
#endif
4856
#if openPMD_HAVE_ADIOS2
4957
fext.emplace_back("bp");
5058
#endif

0 commit comments

Comments
 (0)