summaryrefslogtreecommitdiff
path: root/packages/oprofile
diff options
context:
space:
mode:
authorJohn Lee <john_lee@openmoko.org>2008-05-23 09:10:35 +0000
committerJohn Lee <john_lee@openmoko.org>2008-05-23 09:10:35 +0000
commit14dda1dd17204a6720792103382088511ac08505 (patch)
tree5bc25034ff48cf902686344009c3dac19c40b529 /packages/oprofile
parente91a812ac4a6b1dd9d3cd9aef1f87c33deaa5085 (diff)
oprofile: make opcontrol compatible with busybox 'kill'
Diffstat (limited to 'packages/oprofile')
-rw-r--r--packages/oprofile/oprofile/opcontrol-busybox-compat.patch49
-rw-r--r--packages/oprofile/oprofile_0.9.3.bb16
2 files changed, 59 insertions, 6 deletions
diff --git a/packages/oprofile/oprofile/opcontrol-busybox-compat.patch b/packages/oprofile/oprofile/opcontrol-busybox-compat.patch
new file mode 100644
index 0000000000..d394e016c5
--- /dev/null
+++ b/packages/oprofile/oprofile/opcontrol-busybox-compat.patch
@@ -0,0 +1,49 @@
+Index: oprofile-0.9.3/utils/opcontrol
+===================================================================
+--- oprofile-0.9.3.orig/utils/opcontrol 2008-05-23 16:54:21.000000000 +0800
++++ oprofile-0.9.3/utils/opcontrol 2008-05-23 00:47:38.000000000 +0800
+@@ -908,7 +908,7 @@
+ return
+ fi
+
+- kill -s 0 `cat $LOCK_FILE` 2>/dev/null
++ kill -0 `cat $LOCK_FILE` 2>/dev/null
+ if test "$?" -ne 0; then
+ echo "Detected stale lock file. Removing." >&2
+ rm -f "$LOCK_FILE"
+@@ -919,7 +919,7 @@
+ echo "Stopping profiling."
+ echo 0 >/dev/oprofile/enable
+ fi
+- kill -s USR2 `cat $LOCK_FILE` 2>/dev/null
++ kill -usr2 `cat $LOCK_FILE` 2>/dev/null
+ }
+
+
+@@ -932,7 +932,7 @@
+ return
+ fi
+
+- kill -s 0 `cat $LOCK_FILE` 2>/dev/null
++ kill -0 `cat $LOCK_FILE` 2>/dev/null
+ if test "$?" -ne 0; then
+ echo "Detected stale lock file. Removing." >&2
+ rm -f "$LOCK_FILE"
+@@ -1274,7 +1274,7 @@
+ {
+
+ if test -f "$LOCK_FILE"; then
+- kill -s 0 `cat $LOCK_FILE` 2>/dev/null
++ kill -0 `cat $LOCK_FILE` 2>/dev/null
+ if test "$?" -eq 0; then
+ return;
+ else
+@@ -1341,7 +1341,7 @@
+ if test "$KERNEL_SUPPORT" = "yes"; then
+ echo 1 >$MOUNT/enable
+ fi
+- kill -s USR1 `cat $LOCK_FILE` 2>/dev/null
++ kill -USR1 `cat $LOCK_FILE` 2>/dev/null
+ echo "Profiler running."
+ }
+
diff --git a/packages/oprofile/oprofile_0.9.3.bb b/packages/oprofile/oprofile_0.9.3.bb
index d758b97549..977907e305 100644
--- a/packages/oprofile/oprofile_0.9.3.bb
+++ b/packages/oprofile/oprofile_0.9.3.bb
@@ -1,11 +1,15 @@
-SECTION = "devel"
DESCRIPTION = "OProfile is a system-wide profiler for Linux systems, capable \
of profiling all running code at low overhead."
+SECTION = "devel"
LICENSE = "GPL"
DEPENDS = "popt binutils"
+PR = "r1"
SRC_URI = "${SOURCEFORGE_MIRROR}/oprofile/oprofile-${PV}.tar.gz \
- file://acinclude.m4"
+ file://acinclude.m4 \
+ file://opcontrol-busybox-compat.patch;patch=1 \
+ "
+
S = "${WORKDIR}/oprofile-${PV}"
inherit autotools
@@ -14,12 +18,12 @@ inherit autotools
# Should add the oprofile kernel modules, for those with 2.4
# kernels, as a seperate .oe file.
EXTRA_OECONF = "--with-kernel-support \
- --without-x \
- --disable-werror "
+ --without-x \
+ --disable-werror "
do_configure () {
- cp ${WORKDIR}/acinclude.m4 ${S}/
- autotools_do_configure
+ cp ${WORKDIR}/acinclude.m4 ${S}/
+ autotools_do_configure
}
# Available config options
# --enable-abi enable abi portability code (default is disabled)