Skip to content

Commit 9dc076e

Browse files
committed
update
1 parent e6e7a57 commit 9dc076e

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

setup.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -728,11 +728,8 @@ def _populate_hdf5_info(dirstosearch, inc_dirs, libs, lib_dirs):
728728
"Topic :: Software Development :: Libraries :: Python Modules",
729729
"Topic :: System :: Archiving :: Compression",
730730
"Operating System :: OS Independent"],
731-
#packages=['netCDF4'],
732731
packages=find_namespace_packages(where="src"),
733732
package_dir={'':'src'},
734-
#data_files=[('netCDF4',data_files)], # doesn't work with pip install
735-
#include_package_data = True,
736733
package_data={"netCDF4.plugins": ["lib__nc*"]},
737734
ext_modules=ext_modules,
738735
**setuptools_extra_kwargs)

src/netCDF4/__init__.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
__all__ =\
1515
['Dataset','Variable','Dimension','Group','MFDataset','MFTime','CompoundType','VLType','date2num','num2date','date2index','stringtochar','chartostring','stringtoarr','getlibversion','EnumType','get_chunk_cache','set_chunk_cache']
1616
# if HDF5_PLUGIN_PATH not set, point to package path if plugins live there
17+
pluginpath = os.path.join(__path__[0],'plugins')
1718
if 'HDF5_PLUGIN_PATH' not in os.environ and\
18-
(os.path.exists(os.path.join(os.path.join(__path__[0],'plugins'),'lib__nczhdf5filters.so')) or\
19-
os.path.exists(os.path.join(os.path.join(__path__[0],'plugins'),'lib__nczhdf5filters.dylib'))):
20-
os.environ['HDF5_PLUGIN_PATH']=os.path.join(__path__[0],'plugins')
19+
(os.path.exists(os.path.join(pluginpath,'lib__nczhdf5filters.so')) or\
20+
os.path.exists(os.path.join(pluginpath,'lib__nczhdf5filters.dylib'))):
21+
os.environ['HDF5_PLUGIN_PATH']=pluginpath

0 commit comments

Comments
 (0)