From 71430b35520ca193a4a2d0a61ffd779e3562df9b Mon Sep 17 00:00:00 2001 From: Rodrigo Arias Mallo Date: Mon, 29 Jun 2020 17:32:30 +0200 Subject: [PATCH] Add mercurium mcxx compiler --- bsc/mcxx/default.nix | 54 ++++++++++++++++++++++++++++++++++++++++++++ default.nix | 4 ++++ 2 files changed, 58 insertions(+) create mode 100644 bsc/mcxx/default.nix diff --git a/bsc/mcxx/default.nix b/bsc/mcxx/default.nix new file mode 100644 index 0000000..0424b32 --- /dev/null +++ b/bsc/mcxx/default.nix @@ -0,0 +1,54 @@ +{ stdenv +, fetchgit +, autoreconfHook +, nanos6 +, gperf +, python +, gfortran +, pkg-config +, sqlite +, flex +, bison +, gcc +}: + +stdenv.mkDerivation rec { + name = "mcxx"; + #version attribute ignored when using fetchgit: + #version = "2.2.0-70a299cf"; + + # Use patched Extrae version + src = fetchgit { + url = "https://github.com/bsc-pm/mcxx"; + rev = "70a299cfeb1f96735e6b9835aee946451f1913b2"; + sha256 = "1n8y0h47jm2ll67xbz930372xkl9647z12lfwz2472j3y86yxpmw"; + }; + + enableParallelBuilding = true; + + # Use full path for the backend compilers + preConfigure = '' + export GCC=${gcc}/bin/gcc + export GXX=${gcc}/bin/g++ + export GFORTRAN=${gfortran}/bin/gfortran + ''; + + buildInputs = [ + autoreconfHook + nanos6 + gperf + python + gfortran + pkg-config + sqlite.dev + bison + flex + gcc + ]; + + configureFlags = [ + "--enable-ompss-2" + "--with-nanos6=${nanos6}" + ]; + +} diff --git a/default.nix b/default.nix index 229cede..eda3cde 100644 --- a/default.nix +++ b/default.nix @@ -43,6 +43,10 @@ let mpi = mpi; }; + mcxx = callPackage ./bsc/mcxx/default.nix { + nanos6 = nanos6-git; + }; + nanos6 = callPackage ./bsc/nanos6/default.nix { extrae = extrae; };