Skip to content
Snippets Groups Projects
Commit b22b9987 authored by Elliott Hughes's avatar Elliott Hughes
Browse files

Fix the generated getevent labels.

Some of the less-used stuff stayed behind in input.h, so we need to
parse both files.

Change-Id: Iff2b6e3fc4f5a6584169d12f16427b4f235da21a
Test: manual inspection of the generated file.
parent 54c12196
Branches
Tags
No related merge requests found
......@@ -73,7 +73,7 @@ $(TOOLS_H):
$(LOCAL_PATH)/getevent.c: $(intermediates)/input.h-labels.h
UAPI_INPUT_EVENT_CODES_H := bionic/libc/kernel/uapi/linux/input-event-codes.h
UAPI_INPUT_EVENT_CODES_H := bionic/libc/kernel/uapi/linux/input.h bionic/libc/kernel/uapi/linux/input-event-codes.h
INPUT_H_LABELS_H := $(intermediates)/input.h-labels.h
$(INPUT_H_LABELS_H): PRIVATE_LOCAL_PATH := $(LOCAL_PATH)
# The PRIVATE_CUSTOM_TOOL line uses = to evaluate the output path late.
......
......@@ -38,7 +38,8 @@ ff_list = []
r = re.compile(r'#define\s+(\S+)\s+((?:0x)?\d+)')
with open(sys.argv[1], 'r') as f:
for arg in sys.argv[1:]:
with open(arg, 'r') as f:
for line in f:
m = r.match(line)
if m:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment