4 on_high_sierra :or_older do
5 sha256 "4e937a6de4303a4928f0f42390d991b12a37659726d15b9da7e8072db74e1867"
7 url "https://www.earthsystemgrid.org/api/v1/dataset/ncl.#{version.no_dots}.dap/file/ncl_ncarg-#{version}-MacOS_10.13_64bit_gnu710.tar.gz",
8 verified: "earthsystemgrid.org/api/v1/dataset/"
10 on_mojave :or_newer do
11 sha256 "e2cd644f6b1bb41f55480b8818319e60c450998e31e5e489c69a5e84f3d1f359"
13 url "https://www.earthsystemgrid.org/api/v1/dataset/ncl.#{version.no_dots}.dap/file/ncl_ncarg-#{version}-MacOS_10.14_64bit_gnu730.tar.gz",
14 verified: "earthsystemgrid.org/api/v1/dataset/"
17 name "NCAR Command Language"
19 desc "Interpreted language for scientific data analysis and visualization"
20 homepage "https://www.ncl.ucar.edu/"
24 regex(/>Current\s*Version.*?v?(\d+(?:\.\d+)+)\s*?</i)
27 depends_on cask: "xquartz"
28 depends_on formula: "gcc"
29 depends_on macos: ">= :high_sierra"
31 artifact "include", target: "#{HOMEBREW_PREFIX}/ncl-#{version}/include"
32 artifact "bin", target: "#{HOMEBREW_PREFIX}/ncl-#{version}/bin"
33 artifact "lib", target: "#{HOMEBREW_PREFIX}/ncl-#{version}/lib"
36 system_command "/bin/mkdir", args: ["-p", "#{HOMEBREW_PREFIX}/ncl-#{version}"], sudo: true
39 uninstall delete: "#{HOMEBREW_PREFIX}/ncl-#{version}"
42 To use ncar-ncl, you must add the ${NCARG_ROOT}/bin directory
43 to your PATH environment variable.
45 For bash shell, add these lines to ~/.bash_profile:
47 export NCARG_ROOT="#{HOMEBREW_PREFIX}/ncl-#{version}"
48 export PATH="${NCARG_ROOT}/bin:${PATH}"
50 You may also need to modify your DYLD_FALLBACK_LIBRARY_PATH
53 export DYLD_FALLBACK_LIBRARY_PATH=$(dirname $(gfortran --print-file-name libgfortran.3.dylib)):$DYLD_FALLBACK_LIBRARY_PATH
55 For other information, please see:
56 https://www.ncl.ucar.edu/Download/macosx.shtml