Skip to content

Commit

Permalink
Merge pull request #8 from bhill-slac/add-rpath-support
Browse files Browse the repository at this point in the history
Updated include_dirs to work for EPICS BASE >= 3.15 and added rpaths
  • Loading branch information
ZLLentz authored Feb 26, 2018
2 parents 54602a7 + 321e2a3 commit 4dd6dda
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,27 @@

if sys.platform == 'darwin':
libsrc = 'Darwin'
compiler = 'clang'
elif sys.platform.startswith('linux'):
libsrc = 'Linux'
compiler = 'gcc'
else:
libsrc = None

epics_inc = os.getenv("EPICS_BASE") + "/include"
epics_lib = os.getenv("EPICS_BASE") + "/lib/" + os.getenv("EPICS_HOST_ARCH")
numpy_inc = np.get_include()
numpy_lib = np.__path__[0]

pyca = Extension('pyca',
language='c++',
sources=['pyca/pyca.cc'],
include_dirs=['pyca', epics_inc, epics_inc + '/os/' + libsrc,
numpy_inc],
library_dirs=[epics_lib],
include_dirs=['pyca', epics_inc,
epics_inc + '/os/' + libsrc,
epics_inc + '/os/compiler/' + compiler,
numpy_inc],
library_dirs=[epics_lib,numpy_lib],
runtime_library_dirs=[epics_lib,numpy_lib],
libraries=['Com', 'ca'])

setup(name='pyca',
Expand Down

0 comments on commit 4dd6dda

Please sign in to comment.