Files
sysprof/Makefile.am
Soren Sandmann 4dd37d092c Communicate traces to userspace through shared memory instead of copying.
2006-10-22  Soren Sandmann <sandmann@daimi.au.dk>

	Communicate traces to userspace through shared memory instead of
	copying.

	* module/sysprof-module.c: Store the traces in a SysprofMmapArea.
	(sysprof_mmap): Implement this method.
	(sysprof_nopage): Implement this.
	(sysprof_read): Just reset the tail pointer and return zero.

	* module/sysprof-module.h (struct SysprofMmapArea): New
	structure.

	* collector.c (collector_stop): Unmap the device
	(in_dead_period): New function
	(on_read): Read the traces out of mmap()ed area instead of reading
	them. Call read() to prevent poll() from firing.
	(struct Collector): New members map_area and current.

	* Makefile.am (insert-module): Prefix modprobe with /sbin

	* collector.c (open_fd): mmap() the sysprof device.
2006-10-23 03:46:25 +00:00

95 lines
1.6 KiB
Makefile

SUBDIRS = $(MODULE_SUBDIR)
DIST_SUBDIRS = module
bin_PROGRAMS = sysprof-text
noinst_PROGRAMS = testelf
testelf_SOURCES = testelf.c demangle.c elfparser.c elfparser.h binparser.c binparser.h
testelf_CPPFLAGS = \
$(CORE_DEP_CFLAGS)
testelf_LDADD = $(CORE_DEP_LIBS)
if BUILD_GUI
bin_PROGRAMS += sysprof
endif
SYSPROF_CORE = \
binfile.h \
binfile.c \
binparser.h \
binparser.c \
collector.c \
collector.h \
demangle.c \
elfparser.c \
elfparser.h \
process.h \
process.c \
profile.h \
profile.c \
sfile.h \
sfile.c \
sformat.h \
sformat.c \
stackstash.h \
stackstash.c \
module/sysprof-module.h \
watch.h \
watch.c
#
# GUI version
#
if BUILD_GUI
sysprof_SOURCES = \
$(SYSPROF_CORE) \
treeviewutils.h \
treeviewutils.c \
sysprof.c
sysprof_CPPFLAGS = \
$(GUI_DEP_CFLAGS) \
-DDATADIR=\"$(pkgdatadir)\" \
-DPIXMAPDIR=\"$(pixmapsdir)\"
sysprof_LDADD = $(GUI_DEP_LIBS)
endif
udevdir = $(sysconfdir)/udev/rules.d
dist_udev_DATA = 60-sysprof.rules
pixmapsdir = $(datadir)/pixmaps
dist_pkgdata_DATA = sysprof.glade
dist_pixmaps_DATA = sysprof-icon.png
#
# Command line version
#
sysprof_text_SOURCES = \
$(SYSPROF_CORE) \
signal-handler.h \
signal-handler.c \
sysprof-text.c
sysprof_text_CPPFLAGS = \
$(CORE_DEP_CFLAGS)
sysprof_text_LDADD = $(CORE_DEP_LIBS)
#
# Module stuff
#
EXTRA_DIST = \
module/sysprof-module.c \
module/sysprof-module.h \
module/Makefile
insert-module:
/sbin/modprobe -r sysprof-module
/sbin/modprobe sysprof-module