上传者: 42109125
|
上传时间: 2022-06-19 16:59:32
|
文件大小: 7KB
|
文件类型: ZIP
getevent
移植Android工具getevent到Linux,相应的文件位于system/core/toolbox中。
修改步骤如下:
getevent.c引用的头文件'input.h-labels.h'是用脚本'generate-input.h-labels.py'自动生成的,参数是'bionic/libc/kernel/uapi/linux/input-event-codes.h'(参考Android.mk),在命令行下输入下列命令
$ ./generate-input.h-labels.py /usr/include/linux/input-event-codes.h > input.h-labels.h
注释掉引用的'sys/limits.h>'
//#include
3.添加头文件'time.h',解决CLOCK_MONOTONIC定义问题,