Skip to content

Commit

Permalink
Update for setup.py and init.
Browse files Browse the repository at this point in the history
Added 'has_openmp_support' module bool variable.
  • Loading branch information
EricEngle-NOAA committed Apr 2, 2024
1 parent d36d5b0 commit 79242f8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,10 +230,12 @@ def find_library(name, dirs=None, static=False):
"""# This file is generated by grib2io-interps's setup.py
# It contains configuration information when building this package.
grib2io_interp_version = '%(grib2io_interp_version)s'
has_openmp_support = %(has_openmp_support)s
"""
a = open('src/grib2io_interp/__config__.py','w')
cfgdict = {}
cfgdict['grib2io_interp_version'] = VERSION
cfgdict['has_openmp_support'] = needs_openmp
try:
a.write(cnt % cfgdict)
finally:
Expand Down
1 change: 1 addition & 0 deletions src/grib2io_interp/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"""

from .__config__ import grib2io_interp_version as __version__
from .__config__ import has_openmp_support

def get_openmp_threads():
"""
Expand Down

0 comments on commit 79242f8

Please sign in to comment.