-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
135 changed files
with
18,666 additions
and
163 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
include AUTHORS | ||
include CMakeLists.txt | ||
include LICENSE | ||
include README.md | ||
include VERSION | ||
recursive-include src * | ||
recursive-include cmake * | ||
recursive-include tests * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
[build-system] | ||
requires = ["setuptools", "wheel", "scikit-build"] | ||
build-backend = "setuptools.build_meta" | ||
|
||
[project] | ||
name = "ectrans4py" | ||
dynamic = ["version"] | ||
dependencies=["numpy", "ctypesForFortran<2.0.0"] | ||
|
||
[tool.setuptools.dynamic] | ||
version = {attr = "ectrans4py.__version__"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import os | ||
import ast | ||
from skbuild import setup | ||
|
||
_version_file = os.path.join(os.path.dirname(os.path.abspath(__file__)), "VERSION") | ||
with open(_version_file, "r") as f: | ||
__version__ = f.read().strip() | ||
|
||
setup( | ||
name="ectrans4py", | ||
version=__version__, | ||
packages=['ectrans4py'], | ||
cmake_minimum_required_version="3.13", | ||
cmake_args=[ | ||
'-DENABLE_ETRANS=ON', | ||
'-DENABLE_ECTRANS4PY=ON', | ||
'-DENABLE_SINGLE_PRECISION=OFF', | ||
'-DENABLE_PROGRAMS=OFF', | ||
'-DENABLE_OMP=OFF', | ||
], | ||
package_dir={"": "src"}, | ||
cmake_install_dir="src/ectrans4py", | ||
setup_requires=["scikit-build", "setuptools"], | ||
install_requires=["numpy", "ctypesforfortran==1.1.3"], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
if(HAVE_ETRANS) | ||
# (using CMAKE_CURRENT_SOURCE_DIR is necessary because sources are in a different directory than the target library (trans_${prec})) | ||
ecbuild_list_add_pattern( | ||
LIST ectrans4py_src | ||
GLOB ${CMAKE_CURRENT_SOURCE_DIR}/*.F90 | ||
QUIET | ||
) | ||
|
||
set(HAVE_dp ${HAVE_DOUBLE_PRECISION}) | ||
set(prec dp) | ||
|
||
if(HAVE_${prec}) | ||
# Add sources | ||
target_sources(trans_${prec} PRIVATE ${ectrans4py_src}) | ||
endif() | ||
|
||
else() | ||
ecbuild_critical("To activate the ectrans Python interface, you must enable the ETRANS option.") | ||
endif() | ||
|
Oops, something went wrong.