diff --git a/LIBSTELL/Sources/Modules/fieldlines_input_mod.f90 b/LIBSTELL/Sources/Modules/fieldlines_input_mod.f90 index a6c2a32e..6716e789 100644 --- a/LIBSTELL/Sources/Modules/fieldlines_input_mod.f90 +++ b/LIBSTELL/Sources/Modules/fieldlines_input_mod.f90 @@ -119,7 +119,7 @@ SUBROUTINE read_fieldlines_input(filename, istat) END IF READ(iunit,NML=fieldlines_input,IOSTAT=istat) IF (istat /= 0) THEN - WRITE(6,'(A)') 'ERROR reading namelist BEAMS3D_INPUT from file: ',TRIM(filename) + WRITE(6,'(A)') 'ERROR reading namelist FIELDLINES_INPUT from file: ',TRIM(filename) backspace(iunit) read(iunit,fmt='(A)') line write(6,'(A)') 'Invalid line in namelist: '//TRIM(line) diff --git a/SHARE/make_macports.inc b/SHARE/make_macports.inc index 00fb8a6f..d2c22695 100644 --- a/SHARE/make_macports.inc +++ b/SHARE/make_macports.inc @@ -27,10 +27,19 @@ ####################################################################### FLAGS_R = -O2 -g -fexternal-blas -fbacktrace -fcheck=all,no-array-temps FLAGS_D = -O0 -g -fexternal-blas -fbacktrace -fcheck=all,no-array-temps -fbounds-check - LIBS = -L/usr/lib -L/opt/local/lib -lopenblas -lscalapack + LIBS = -L/usr/lib -L/opt/local/lib -lscalapack -framework Accelerate FLAGS_R += -fallow-argument-mismatch FLAGS_D += -fallow-argument-mismatch +####################################################################### +# Check for Accelerate Framework/OpenBLAS +####################################################################### +ifneq ("$(wildcard /opt/local/lib/libopenblas*)","") + LIBS += -L/opt/local/lib -lopenblas +else + LIBS += -framework Accelerate +endif + ####################################################################### # MPI Options diff --git a/build_all b/build_all index 92cd7285..896ecb9e 100755 --- a/build_all +++ b/build_all @@ -65,7 +65,4 @@ do done # make a dynamic library -make pystel -#cd LIBSTELL -#make shared_release -#cd .. +#make pystel diff --git a/makefile b/makefile index bcd31fc1..f9a43f74 100644 --- a/makefile +++ b/makefile @@ -39,8 +39,8 @@ endif pystel: libstell$(SHARED_EXT) @echo 'Building pySTEL' - @cd pySTEL; python3 setup.py install --user - + @cd pySTEL; pip install . + libstell$(SHARED_EXT): @cd LIBSTELL; make shared_release diff --git a/pySTEL/pyproject.toml b/pySTEL/pyproject.toml new file mode 100644 index 00000000..126dd034 --- /dev/null +++ b/pySTEL/pyproject.toml @@ -0,0 +1,28 @@ +[build-system] +requires = ["setuptools"] +build-backend = "setuptools.build_meta" + +[project] +name = "pySTEL" +dynamic = ["version"] +description = "Python library for interfacing with STELLOPT" +readme = "README.md" +authors = [ + { name = "Samuel A. Lazerson", email = "lazersos@gmail.com" }, +] +dependencies = [ + "contourpy", + "gmsh", + "matplotlib", + "numpy", + "numpy-stl", + "pyqt5", + "pyvtk", + "scipy", + "vtk", + "pyyaml" +] + +[project.urls] +Homepage = "https://github.com/PrincetonUniversity/STELLOPT" + diff --git a/pySTEL/setup.py b/pySTEL/setup.py index 0e0a5c03..7ba9f693 100644 --- a/pySTEL/setup.py +++ b/pySTEL/setup.py @@ -14,5 +14,5 @@ scripts = ['VMECplot.py','FIELDLINESplot.py','vmec_util.py',\ 'boozer_util.py','coils_util.py','fieldlines_util.py'], install_requires=['numpy','matplotlib','PyQt5','scipy', \ - 'contourpy','vtk','numpy-stl','gmsh'] + 'contourpy','PyVTK','numpy-stl','gmsh','vtk'] )