summaryrefslogblamecommitdiff
path: root/var/spack/repos/builtin/packages/intel-tbb/intel-tbb.nvhpc-remove-flags.2019.patch
blob: eb1ffff9a74ad72f8dde6f947f6a5632407aa24f (plain) (tree)








































                                                                                   
diff -Naur spack-src/build/linux.gcc.inc spack-src.patched/build/linux.gcc.inc
--- spack-src/build/linux.gcc.inc	2018-08-29 10:37:51.000000000 -0400
+++ spack-src.patched/build/linux.gcc.inc	2021-07-28 15:52:03.235813820 -0400
@@ -27,7 +27,9 @@
 WARNING_KEY = -Wall
 TEST_WARNING_KEY = -Wshadow -Wcast-qual -Woverloaded-virtual -Wnon-virtual-dtor
 
-WARNING_SUPPRESS = -Wno-parentheses
+# Skip for nvhpc compilers
+#WARNING_SUPPRESS = -Wno-parentheses
+WARNING_SUPPRESS = 
 DYLIB_KEY = -shared
 EXPORT_KEY = -Wl,--version-script,
 LIBDL = -ldl
@@ -63,10 +65,11 @@
 
 # gcc 6.0 and later have -flifetime-dse option that controls
 # elimination of stores done outside the object lifetime
-ifneq (,$(shell gcc -dumpversion | egrep  "^([6-9])"))
-    # keep pre-contruction stores for zero initialization
-    DSE_KEY = -flifetime-dse=1
-endif
+# Skip for nvhpc compilers
+#ifneq (,$(shell gcc -dumpversion | egrep  "^([6-9])"))
+#    # keep pre-contruction stores for zero initialization
+#    DSE_KEY = -flifetime-dse=1
+#endif
 
 ifeq ($(cfg), release)
         CPLUS_FLAGS = $(ITT_NOTIFY) -g -O2 -DUSE_PTHREAD
@@ -149,7 +152,9 @@
 # Setting tbbmalloc data.
 #------------------------------------------------------------------------------
 
-M_CPLUS_FLAGS = $(CPLUS_FLAGS) -fno-rtti -fno-exceptions
+# Drop -fno-rtti flag for nvhpc compilers
+#M_CPLUS_FLAGS = $(CPLUS_FLAGS) -fno-rtti -fno-exceptions
+M_CPLUS_FLAGS = $(CPLUS_FLAGS) -fno-exceptions
 
 #------------------------------------------------------------------------------
 # End of setting tbbmalloc data.