summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormoloney <moloney.brendan@gmail.com>2023-11-15 00:13:21 -0800
committerGitHub <noreply@github.com>2023-11-15 09:13:21 +0100
commit84e33b496ff1a49a23a46b299036cd674ae510d1 (patch)
tree1c8db73215df85dbedc6fe3ae61447556d0f1f1a
parentde850e97e882de6bfffa53ce5ccd45d69cc788ce (diff)
downloadspack-84e33b496ff1a49a23a46b299036cd674ae510d1.tar.gz
spack-84e33b496ff1a49a23a46b299036cd674ae510d1.tar.bz2
spack-84e33b496ff1a49a23a46b299036cd674ae510d1.tar.xz
spack-84e33b496ff1a49a23a46b299036cd674ae510d1.zip
mrtrix3: fix some issues w/ 3.0.3 and add 3.0.4 (#41036)
-rw-r--r--var/spack/repos/builtin/packages/mrtrix3/fix_includes.patch26
-rw-r--r--var/spack/repos/builtin/packages/mrtrix3/package.py11
2 files changed, 34 insertions, 3 deletions
diff --git a/var/spack/repos/builtin/packages/mrtrix3/fix_includes.patch b/var/spack/repos/builtin/packages/mrtrix3/fix_includes.patch
new file mode 100644
index 0000000000..667e412acc
--- /dev/null
+++ b/var/spack/repos/builtin/packages/mrtrix3/fix_includes.patch
@@ -0,0 +1,26 @@
+--- ./configure.orig 2023-11-12 14:48:25.802025918 -0800
++++ ./configure 2023-11-12 14:48:56.177057419 -0800
+@@ -571,10 +571,7 @@
+ try:
+ flags = []
+ for flag in shlex.split (execute ([ 'pkg-config' ] + pkg_config_flags.split(), RunError)[1]):
+- if flag.startswith ('-I'):
+- flags += [ '-idirafter', flag[2:] ]
+- else:
+- flags += [ flag ]
++ flags += [ flag ]
+ return flags
+ except Exception:
+ log('error running "pkg-config ' + pkg_config_flags + '"\n\n')
+@@ -1323,10 +1320,7 @@
+ for entry in qt:
+ if entry[0] != '$' and not entry == '-I.':
+ entry = entry.replace('\"','').replace("'",'')
+- if entry.startswith('-I'):
+- qt_cflags += [ '-idirafter', entry[2:] ]
+- else:
+- qt_cflags += [ entry ]
++ qt_cflags += [ entry ]
+
+ qt = qt_ldflags + qt_libs
+ qt_ldflags = []
diff --git a/var/spack/repos/builtin/packages/mrtrix3/package.py b/var/spack/repos/builtin/packages/mrtrix3/package.py
index 2a59d7ec22..53bf19ae53 100644
--- a/var/spack/repos/builtin/packages/mrtrix3/package.py
+++ b/var/spack/repos/builtin/packages/mrtrix3/package.py
@@ -17,21 +17,26 @@ class Mrtrix3(Package):
git = "https://github.com/MRtrix3/mrtrix3.git"
version(
- "3.0.3",
- sha256="6ec7d5a567d8d7338e85575a74565189a26ec8971cbe8fb24a49befbc446542e",
+ "3.0.4",
+ sha256="f1d1aa289cfc3e46e3a8eca93594b23d061c6d50a0cd03727433a7e2cd14f71a",
preferred=True,
)
+ version("3.0.3", sha256="6ec7d5a567d8d7338e85575a74565189a26ec8971cbe8fb24a49befbc446542e")
version("2017-09-25", commit="72aca89e3d38c9d9e0c47104d0fb5bd2cbdb536d")
depends_on("python@2.7:", type=("build", "run"))
depends_on("py-numpy", type=("build", "run"))
depends_on("glu")
depends_on("qt+opengl@4.7:")
- depends_on("eigen")
+ # MRTrix <= 3.0.3 can't build with eigen >= 3.4 due to conflicting declarations
+ depends_on("eigen@3.3", when="@3.0.3")
+ depends_on("eigen@3.4:", when="@3.0.4:")
depends_on("zlib-api")
depends_on("libtiff")
depends_on("fftw")
+ patch("fix_includes.patch", when="@3.0.3:3.0.4")
+
conflicts("%gcc@7:", when="@2017-09-25") # MRtrix3/mrtrix3#1041
def install(self, spec, prefix):