-
Notifications
You must be signed in to change notification settings - Fork 567
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add build recipe for tempestremap library #4174
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
# Note that this script can accept some limited command-line arguments, run | ||
# `julia build_tarballs.jl --help` to see a usage message. | ||
using BinaryBuilder, Pkg | ||
|
||
name = "TempestRemap" | ||
version = v"2.1.1" | ||
sources = [ | ||
ArchiveSource("https://github.com/ClimateGlobalChange/tempestremap/archive/refs/tags/v$(version).tar.gz", | ||
"f5ea21f82b358ba127550fc1f49e701cba0379d22ce030c274135109f678b980"), | ||
] | ||
|
||
script = raw""" | ||
cd ${WORKSPACE}/srcdir/tempestremap* | ||
|
||
export CPPFLAGS="-I${includedir}" | ||
export LDFLAGS="-L${libdir}" | ||
export LDFLAGS_MAKE="${LDFLAGS}" | ||
CONFIGURE_OPTIONS="" | ||
|
||
autoreconf -fiv | ||
mkdir -p build && cd build | ||
|
||
../configure \ | ||
--prefix=${prefix} \ | ||
--host=${target} \ | ||
--with-blas=blastrampoline \ | ||
--with-lapack=blastrampoline \ | ||
--with-netcdf=${prefix} \ | ||
--with-hdf5=${prefix} \ | ||
--enable-shared \ | ||
--disable-static | ||
|
||
make LDFLAGS="${LDFLAGS_MAKE}" -j${nproc} all | ||
make install | ||
|
||
install_license ../LICENSE | ||
""" | ||
|
||
# Note: We are restricted to the platforms that NetCDF supports, the library is Unix only | ||
platforms = [ | ||
Platform("x86_64", "linux"), | ||
Platform("aarch64", "linux"; libc="glibc"), | ||
Platform("x86_64", "macos"), | ||
] | ||
platforms = expand_cxxstring_abis(platforms) | ||
|
||
products = [ | ||
LibraryProduct("libTempestRemap", :libTempestRemap), | ||
ExecutableProduct("AnalyzeMap", :AnalyzeMap_exe), | ||
ExecutableProduct("ApplyOfflineMap", :ApplyOfflineMap_exe), | ||
ExecutableProduct("CalculateDiffNorms", :CalculateDiffNorms_exe), | ||
ExecutableProduct("CoarsenRectilinearData", :CoarsenRectilinearData_exe), | ||
ExecutableProduct("ConvertExodusToSCRIP", :ConvertExodusToSCRIP_exe), | ||
ExecutableProduct("ConvertSCRIPToExodus", :ConvertSCRIPToExodus_exe), | ||
ExecutableProduct("GenerateCSMesh", :GenerateCSMesh_exe), | ||
ExecutableProduct("GenerateGLLMetaData", :GenerateGLLMetaData_exe), | ||
ExecutableProduct("GenerateICOMesh", :GenerateICOMesh_exe), | ||
ExecutableProduct("GenerateLambertConfConicMesh", :GenerateLambertConfConicMesh_exe), | ||
ExecutableProduct("GenerateOfflineMap", :GenerateOfflineMap_exe), | ||
ExecutableProduct("GenerateOverlapMesh", :GenerateOverlapMesh_exe), | ||
ExecutableProduct("GenerateOverlapMesh_v1", :GenerateOverlapMesh_v1_exe), | ||
ExecutableProduct("GenerateRLLMesh", :GenerateRLLMesh_exe), | ||
ExecutableProduct("GenerateRectilinearMeshFromFile", :GenerateRectilinearMeshFromFile_exe), | ||
ExecutableProduct("GenerateStereographicMesh", :GenerateStereographicMesh_exe), | ||
ExecutableProduct("GenerateTestData", :GenerateTestData_exe), | ||
ExecutableProduct("GenerateTransectMesh", :GenerateTransectMesh_exe), | ||
ExecutableProduct("GenerateTransposeMap", :GenerateTransposeMap_exe), | ||
ExecutableProduct("GenerateUTMMesh", :GenerateUTMMesh_exe), | ||
ExecutableProduct("GenerateVolumetricMesh", :GenerateVolumetricMesh_exe), | ||
ExecutableProduct("MeshToTxt", :MeshToTxt_exe), | ||
ExecutableProduct("RestructureData", :RestructureData_exe), | ||
ExecutableProduct("ShpToMesh", :ShpToMesh_exe), | ||
ExecutableProduct("VerticalInterpolate", :VerticalInterpolate_exe), | ||
] | ||
|
||
dependencies = Dependency[ | ||
Dependency("libblastrampoline_jll"), | ||
Dependency("NetCDF_jll"), | ||
Dependency("HDF5_jll"), | ||
# The following is adapted from NetCDF_jll | ||
Dependency("LibCURL_jll"), | ||
# The following libraries are dependencies of LibCURL_jll which is now a | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Are you sure this is still needed? I thought this had been fixed, but I'm not 100% sure There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I can try again locally without the libcurl deps, but adding these fixed all the issues I had. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ok, let's go with this then. |
||
# stdlib, but the stdlib doesn't explicitly list its dependencies | ||
Dependency("LibSSH2_jll"), | ||
Dependency("MbedTLS_jll", v"2.24.0"), | ||
Dependency("nghttp2_jll"), | ||
] | ||
|
||
build_tarballs(ARGS, name, version, sources, script, platforms, products, dependencies; | ||
julia_compat="1.7", | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we also support
Platform("aarch64", "macos")
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does
NetCDF_jll
work on aarch64? if it does then yesThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doesn't look like it? https://github.com/JuliaBinaryWrappers/NetCDF_jll.jl#platforms
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's limited by HDF5....
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there is no end-date to a long time I guess.... #567