hepmc3: pass root variant cxxstd as HEPMC3_CXX_STANDARD (#44806)
				
					
				
			* hepmc3: pass `root` variant `cxxstd` as `HEPMC3_CXX_STANDARD` * hepmc3: when @:3.2.3 +rootio, depends_on root cxxstd=11 * [@spackbot] updating style on behalf of wdconinc --------- Co-authored-by: wdconinc <wdconinc@users.noreply.github.com>
This commit is contained in:
		| @@ -44,7 +44,9 @@ class Hepmc3(CMakePackage): | ||||
|     ) | ||||
| 
 | ||||
|     depends_on("cmake@2.8.9:", type="build") | ||||
|     depends_on("root", when="+rootio") | ||||
|     with when("+rootio"): | ||||
|         depends_on("root") | ||||
|         depends_on("root cxxstd=11", when="@:3.2.3") | ||||
|     depends_on("protobuf", when="+protobuf") | ||||
|     depends_on("python", when="+python") | ||||
| 
 | ||||
| @@ -62,7 +64,7 @@ def cmake_args(self): | ||||
|             self.define("HEPMC3_ENABLE_TEST", self.run_tests), | ||||
|         ] | ||||
| 
 | ||||
|         if "+python" in spec: | ||||
|         if spec.satisfies("+python"): | ||||
|             py_ver = spec["python"].version.up_to(2) | ||||
|             args.extend( | ||||
|                 [ | ||||
| @@ -71,7 +73,11 @@ def cmake_args(self): | ||||
|                 ] | ||||
|             ) | ||||
| 
 | ||||
|         if "+rootio" in spec: | ||||
|         if spec.satisfies("+rootio"): | ||||
|             args.append(self.define("ROOT_DIR", spec["root"].prefix)) | ||||
|             if spec.satisfies("@3.2.4:"): | ||||
|                 args.append( | ||||
|                     self.define("HEPMC3_CXX_STANDARD", spec["root"].variants["cxxstd"].value) | ||||
|                 ) | ||||
| 
 | ||||
|         return args | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Wouter Deconinck
					Wouter Deconinck