NCAR / hrldas-release

HRLDAS (High Resolution Land Data Assimilation System) containing the Noah-MP Land Surface Model
35 stars 33 forks source link

Gfortran options don't build properly #33

Open espoelstra opened 4 years ago

espoelstra commented 4 years ago

The -fno-underscoring seems to cause a consistent failure when trying to build in an Ubuntu Docker container pretty much regardless of version (tested on several versions).

The hardcoded /opt/local/ paths also don't work under Debian/Ubuntu distributions, which I've worked around by doing a just in time sed to replace the full paths with just the executable name assuming they were installed in the $PATH by a package manager or the user adding those directories to the PATH manually.

Since libjasper-devel doesn't exist in Ubuntu versions newer than 16.04, it is also useful to grab the source tarball and compile that instead of polluting a newer distribution with a potentially incompatible package with invalid bindings. See #32 for the workarounds, which could possibly just be applied to the arch/user_build_options.gfortran.serial file if someone is able to test them on more distributions (should be easy enough using the Dockerfile and arguments in the README).