Android上的SystemTap

Android上的SystemTap,android,linux,systemtap,Android,Linux,Systemtap,当我在android上执行命令“staprun”时,我遇到了以下问题: # /data/systemtap-1.0-omap/bin/staprun /data/local/msyscall_all.ko /data/systemtap-1.0-omap/bin/staprun: 1: Syntax error: "(" unexpected # 模块msyscall_all.ko与我的android运行的内核交叉编译 首先,我确信msyscall_all.ko完全正确,因为我使用命令'i

当我在android上执行命令“staprun”时,我遇到了以下问题:

# /data/systemtap-1.0-omap/bin/staprun /data/local/msyscall_all.ko
  /data/systemtap-1.0-omap/bin/staprun: 1: Syntax error: "(" unexpected
#
模块msyscall_all.ko与我的android运行的内核交叉编译

首先,我确信msyscall_all.ko完全正确,因为我使用命令'insomd'和'lsmod'来确保它是正确的

# lsmod
 omaplfb 8986 0 - Live 0xbf032000
 pvrsrvkm 137346 29 omaplfb, Live 0xbf000000
# insmod /data/local/msyscall_all.ko
# lsmod
  msyscall_all 1121778 0 - Live 0xbf037000
  omaplfb 8986 0 - Live 0xbf032000
  pvrsrvkm 137346 29 omaplfb, Live 0xbf000000
# 
第二,我遵循以下指示:

我的systemtap-1.0-omap已成功交叉编译!!然而,在我使用“adb push”将systemtap-1.0-omap推送到我的android设备并运行它之后,我得到了以下错误:

/data/systemtap-1.0-omap/bin/staprun:1:语法错误:“(意外的

当“staprun”在ubuntu上运行时,它给了我如何运行“staprun”的建议,当它在android设备上运行时,它出现了错误:

# /data/systemtap-1.0-omap/bin/staprun
  /data/systemtap-1.0-omap/bin/staprun: 1: Syntax error: "(" unexpected
# exit
ubuntu@ubuntu:~$ cd systemtap-1.0-omap/bin/
ubuntu@ubuntu:~/systemtap-1.0-omap/bin$ ./staprun 
ERROR: Need a module name or path to load.

./staprun [-v]  [-c cmd ] [-x pid] [-u user] [-A|-L|-d]
  [-b bufsize] [-o FILE [-D] [-S size[,N]]] MODULE [module-options]
  -v              Increase verbosity.
  -c cmd          Command 'cmd' will be run and staprun will
                  exit when it does.  The '_stp_target' variable
                  will contain the pid for the command.
  -x pid          Sets the '_stp_target' variable to pid.
  -o FILE         Send output to FILE. This supports strftime(3)
                  formats for FILE.
  -b buffer size  The systemtap module specifies a buffer size.
                  Setting one here will override that value.  The
                  value should be an integer between 1 and 4095 
                  which be assumed to be the buffer size in MB.
                  That value will be per-cpu in bulk mode.
  -L              Load module and start probes, then detach.
  -A              Attach to loaded systemtap module.
  -d              Delete a module.  Only detached or unused modules
                  the user has permission to access will be deleted. Use "*"
                  (quoted) to delete all unused modules.
  -D              Run in background. This requires '-o' option.
  -S size[,N]     Switches output file to next file when the size
                  of file reaches the specified size. The value
                  should be an integer greater than 1 which is
                  assumed to be the maximum file size in MB.
                  When the number of output files reaches N, it
                  switches to the first output file. You can omit
                  the second argument.
  MODULE can be either a module name or a module path.  If a
  module name is used, it is looked for in the following
  directory: /lib/modules/`uname -r`/systemtap
ubuntu@ubuntu:~/systemtap-1.0-omap/bin$ 

我已经尽了最大的努力,但我无法解决它!!

我今天解决了这个问题!!!很高兴!!请分享你是如何解决的。事实上,解决这个问题很容易。我一直认为我使用了一个错误的工具链,所以我从网上下载了另一个工具链,并替换了旧的工具链。它确实有效!