Try to use backports for python2. Reverse priority order for netcdf_c++

This commit is contained in:
Guilhem Lavaux 2018-03-24 22:00:36 +01:00
parent 3c976b8f8d
commit 7353701ad2
2 changed files with 6 additions and 2 deletions

View File

@ -210,7 +210,7 @@ ELSE(INTERNAL_NETCDF)
find_path(NETCDF_INCLUDE_PATH NAMES netcdf.h) find_path(NETCDF_INCLUDE_PATH NAMES netcdf.h)
find_path(NETCDFCPP_INCLUDE_PATH NAMES netcdfcpp.h netcdf) find_path(NETCDFCPP_INCLUDE_PATH NAMES netcdfcpp.h netcdf)
find_library(NETCDF_LIBRARY netcdf) find_library(NETCDF_LIBRARY netcdf)
find_library(NETCDFCPP_LIBRARY NAMES netcdf_c++ netcdf_c++4) find_library(NETCDFCPP_LIBRARY NAMES netcdf_c++4 netcdf_c++)
SET(CONFIGURE_CPP_FLAGS "${CONFIGURE_CPP_FLAGS} -I${NETCDF_INCLUDE_PATH} -I${NETCDFCPP_INCLUDE_PATH}") SET(CONFIGURE_CPP_FLAGS "${CONFIGURE_CPP_FLAGS} -I${NETCDF_INCLUDE_PATH} -I${NETCDFCPP_INCLUDE_PATH}")
endif (INTERNAL_NETCDF) endif (INTERNAL_NETCDF)

View File

@ -1,7 +1,11 @@
from .config import install_prefix from .config import install_prefix
import subprocess import subprocess
import os import os
try:
from tempfile import TemporaryDirectory from tempfile import TemporaryDirectory
except:
from backports.tempfile import TemporaryDirectory
import h5py as h5 import h5py as h5
import numpy as np import numpy as np
import weakref import weakref