Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 288653
b: refs/heads/master
c: 6a5c13a
h: refs/heads/master
i:
  288651: 55e5914
v: v3
  • Loading branch information
Namhyung Kim authored and Arnaldo Carvalho de Melo committed Feb 13, 2012
1 parent 8472e87 commit bb572cc
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: d3665498955779e56453501a16f4ad084f798802
refs/heads/master: 6a5c13aff49ac9b3fea38d5f84b436718cb2780d
5 changes: 4 additions & 1 deletion trunk/tools/perf/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,10 @@ SCRIPT_SH += perf-archive.sh
grep-libs = $(filter -l%,$(1))
strip-libs = $(filter-out -l%,$(1))

$(OUTPUT)python/perf.so: $(PYRF_OBJS)
PYTHON_EXT_SRCS := $(shell grep -v ^\# util/python-ext-sources)
PYTHON_EXT_DEPS := util/python-ext-sources util/setup.py

$(OUTPUT)python/perf.so: $(PYRF_OBJS) $(PYTHON_EXT_SRCS) $(PYTHON_EXT_DEPS)
$(QUIET_GEN)CFLAGS='$(BASIC_CFLAGS)' $(PYTHON_WORD) util/setup.py \
--quiet build_ext; \
mkdir -p $(OUTPUT)python && \
Expand Down
17 changes: 17 additions & 0 deletions trunk/tools/perf/util/python-ext-sources
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#
# List of files needed by perf python extention
#
# Each source file must be placed on its own line so that it can be
# processed by Makefile and util/setup.py accordingly.
#

util/python.c
util/ctype.c
util/evlist.c
util/evsel.c
util/cpumap.c
util/thread_map.c
util/util.c
util/xyarray.c
util/cgroup.c
util/debugfs.c
8 changes: 4 additions & 4 deletions trunk/tools/perf/util/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@ def finalize_options(self):
build_lib = getenv('PYTHON_EXTBUILD_LIB')
build_tmp = getenv('PYTHON_EXTBUILD_TMP')

ext_sources = [f.strip() for f in file('util/python-ext-sources')
if len(f.strip()) > 0 and f[0] != '#']

perf = Extension('perf',
sources = ['util/python.c', 'util/ctype.c', 'util/evlist.c',
'util/evsel.c', 'util/cpumap.c', 'util/thread_map.c',
'util/util.c', 'util/xyarray.c', 'util/cgroup.c',
'util/debugfs.c'],
sources = ext_sources,
include_dirs = ['util/include'],
extra_compile_args = cflags,
)
Expand Down

0 comments on commit bb572cc

Please sign in to comment.