Commit Graph

6 Commits

Author SHA1 Message Date
Mark Olesen
c2697f466d CONFIG: update c++ standard, some compiler rules (partially addresses #2209)
- migrate to c++14 for most compilers *except* gcc.
  There are still many systems in use with gcc-4.8.5, which does not
  support c++14.

- initial rules for nvidia compilers (pgi is will soon be defunct).
  Not fully tested...

CONFIG: provide fallback value for the user directory name

- in containers may have an unset USER env variable.
  Default to 'user' to prevent ugly looking directory names.
2021-10-21 15:31:05 +02:00
Mark Olesen
5a5fd1a43c COMP: sign check to avoid warnings about new[] range 2021-04-27 12:28:35 +02:00
Mark Olesen
9423d2bd83 CONFIG: improve support for compiler/link options (#1830)
- introduce WM_COMPILE_CONTROL variable to convey control information
  into the build rules.

  The convention (as per spack):
      - '+' to select a feature
      - '~' to deselect a feature

  Eg, to select the gold linker, and disable openmp
  (spaces are not required):

      WM_COMPILE_CONTROL="+gold ~openmp"

CONFIG: accept FOAM_EXTRA_LDFLAGS for AMD, gold, Mingw linkers

CONFIG: generalize PROJECT_LIBS (-ldl used almost universally)
2020-09-07 09:45:51 +02:00
Mark Olesen
739bc3c4af COMP: add -pthread compile/link dependency for std::thread (#614) 2020-02-07 11:06:06 +01:00
Mark Olesen
89fb73d2a3 COMP: disable some compiler warnings
- The -Wno-deprecated-copy flag for gcc-9.2.0

  In the future we may indeed wish to explicitly request default
  generated constructors and assignment operators, but at the moment
  these are still acceptable.

- The -Wno-alloc-size-larger-than flag for mingw compilations

  Related to differences in PTRDIFF_MAX vs SIZE_MAX on the target.
  Several issues related to this can be found in the gcc bug reports
  and on stackoverflow etc.
2019-12-11 20:42:11 +01:00
Mark Olesen
a54aff9d26 COMP: add wmake rules for mingw (#1238) 2019-04-28 13:36:50 +02:00