Comments (6)
@rabbl, there is some non-standard Fortran in MODFLOW-NWT at the moment. You should be able to just fix those issues in the source code, which is what I had to do. I don't remember the details, but I don't think they were difficult to fix.
from pymake.
@langevin-usgs, sorry, but I'm not very familiar with fortran.
Compiling on debian with pymake comes the following error-message:
gfortran -O2 -fbacktrace -ffpe-summary=overflow -c ./src_temp/gsol7.f -o ./obj_temp/gsol7.o -I./obj_temp -J./mod_temp
./src_temp/gsol7.f:326.25:
USE, INTRINSIC :: IEEE_ARITHMETIC
1
Fatal Error: Can't find an intrinsic module named 'ieee_arithmetic' at (1)
Traceback (most recent call last):
File "make_mfnwt.py", line 42, in <module>
make_mfnwt()
File "make_mfnwt.py", line 32, in make_mfnwt
expedite=False, dryrun=False, double=False, debug=False)
File "/usr/local/lib/python2.7/dist-packages/pymake/pymake.py", line 633, in main
expedite, dryrun, double, debug, fflags)
File "/usr/local/lib/python2.7/dist-packages/pymake/pymake.py", line 357, in compile_with_gnu
subprocess.check_call(cmdlist, shell=shellflg)
File "/usr/lib/python2.7/subprocess.py", line 540, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['gfortran', '-O2', '-fbacktrace', '-ffpe-summary=overflow', '-c', './src_temp/gsol7.f', '-o', './obj_temp/gsol7.o', '-I./obj_temp', '-J./mod_temp']' returned non-zero exit status 1
In the sourcecode on ./src_temp/gsol7.f:326.25 there is the following:
C-------CONJUGATE GRADIENT ITERATIVE SOLVER
SUBROUTINE GSOL_CGAP(NCORESM,NCORESV,
2 IPC,ICNVG,ISOLN,NOUTER,NINNER,
3 HCLOSE,RCLOSE,ETA,NR,NNZ,DAMP,IA,JA,A,
4 NRLU,NNZLU,NJLU,NJW,NWLU,JLU,IU,JW,WLU,Mi,
5 X,B,X0,DSCALE1,DSCALE2,
6 D,P,Q,Z,T)
USE, INTRINSIC :: IEEE_ARITHMETIC
IMPLICIT NONE
What could I change to fix this?
Thanks for helping
from pymake.
@rabbl I'm not sure if it's an option for you, but IEEE_ARITHMETIC was added at GCC version 5 (https://gcc.gnu.org/gcc-5/changes.html). Even so, you'll run into a crash that I fixed by changing a data type in gwf2swr7_NWT.f (that itself will generate some warnings but make will succeed).
14351: DOUBLEPRECISION, INTENT(INOUT) :: T1
change to
14351: REAL, INTENT(INOUT) :: T1
because https://gcc.gnu.org/onlinedocs/gfortran/SECNDS.html.
from pymake.
Thanks @mjigmond for your suggestions. Debian brings gcc 4.9 with it and I had some problems installing the 5.0 version.
I have solved the issue with compiling and using modflow-owhm for my use case and its compiling and running as expected.
from pymake.
The latest release of MODFLOW-NWT (v 1.1.1) available on the web includes changes so that it will compile with gfortran. I have updated the make_mfnwt.py script in the examples directory. I have also added functionality to create a makefile (-mf or --makefile option) with pymake. It works for gfortran on windows or mac (and presumably linux) and for ifort on mac (and presumably linux). It may be a little fragile but I will be doing more testing to clean up some deficiencies.
from pymake.
The make_mfnwt.py script seems to be working now (at least on my mac), due to the use of all standard Fortran in the latest NWT release. Readme.md has been updated to reflect this.
Still need to add a NWT build to the autotesting, but that is a separate issue.
from pymake.
Related Issues (20)
- pip install HOT 1
- pymake-created makefile for building shared lib HOT 2
- Pymake fails to install if numpy isn't being installed manually first HOT 5
- No gsflow make capabilites? HOT 3
- module directory HOT 1
- directory\ncollect2: error: ld returned 1 exit status
- python 2.7 with ifort on Linux
- Functions output their docstring by default?!
- using pymake without setup.py HOT 2
- pymake stalling on windows HOT 8
- On windows mf2000 exe writes unformatted binary files
- Pymake() class improvements
- autotest functionality
- pip install https://github.com/modflowpy/pymake/zipball/master gives an error in a clean conda env.
- compile error mt3dms mac
- Conflict with PyPi pymake? HOT 4
- malloc error running mf6.2 on mac HOT 2
- Could you please offer me the swtv4? HOT 2
- Trying to use pymake for MODPATH 7: AttributeError: module 'pymake.pymake' has no attribute 'parser'. HOT 4
- mf2005 not compiling on MacOS Monterey HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pymake.