Skip to content
This repository was archived by the owner on Jan 7, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
MANIFEST
root_numpy/src/*.html
build
dist
coverage
*.pyc
*.tar.gz
*.egg
*.egg-info
*.so
*.o
.DS_Store
*.pyc
root_numpy/src/*.html
*.d
*.pcm
.DS_Store
.coverage
cover
.project
.Rhistory
.pydevproject
MANIFEST
13 changes: 6 additions & 7 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,14 @@


def root_flags(root_config='root-config'):
root_inc = subprocess.Popen([root_config, '--incdir'],
stdout=subprocess.PIPE).communicate()[0].strip()
root_cflags = subprocess.Popen([root_config, '--cflags'],
stdout=subprocess.PIPE).communicate()[0].strip().split(' ')
root_ldflags = subprocess.Popen([root_config, '--libs'],
stdout=subprocess.PIPE).communicate()[0].strip().split(' ')
return root_inc, root_ldflags
return root_cflags, root_ldflags

try:
root_inc, root_ldflags = root_flags()
root_cflags, root_ldflags = root_flags()
except OSError:
rootsys = os.getenv('ROOTSYS', None)
if rootsys is None:
Expand All @@ -54,7 +54,7 @@ def root_flags(root_config='root-config'):
"Is ROOT installed and setup properly?")
try:
root_config = os.path.join(rootsys, 'bin', 'root-config')
root_inc, root_ldflags = root_flags(root_config)
root_cflags, root_ldflags = root_flags(root_config)
except OSError:
raise RuntimeError(
"ROOTSYS is {0} but running {1} failed".format(
Expand All @@ -68,9 +68,8 @@ def root_flags(root_config='root-config'):
language='c++',
include_dirs=[
np.get_include(),
root_inc,
'root_numpy/src'],
extra_compile_args=['-Wno-unused-function'],
extra_compile_args=root_cflags + ['-Wno-unused-function'],
extra_link_args=root_ldflags + ['-lTreePlayer'])

# check for custom args
Expand Down