build-sys: use more generic regular expression to generate syscall-list.txt correctly
Currently MIPS and ARM define syscall numbers for multiple ABI in one <asm/unistd.h>. The #define statments for each syscall are formated as: #define __NR_scname (BASE_OFFSET + sc_number) Thus we need a more generic regular expression to match these in awk.
This commit is contained in:
parent
df1c8f6ac8
commit
af18d7ca4b
|
@ -1030,7 +1030,7 @@ BUILT_SOURCES += \
|
|||
|
||||
src/core/syscall-list.txt: Makefile
|
||||
$(AM_V_at)$(MKDIR_P) $(dir $@)
|
||||
$(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include sys/syscall.h - < /dev/null | $(AWK) '/^#define[ \t]+__NR_[^ ]+[ \t]+[0-9]/ { sub(/__NR_/, "", $$2); print $$2; }' > $@
|
||||
$(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include sys/syscall.h - < /dev/null | $(AWK) '/^#define[ \t]+__NR_[^ ]+[ \t]+\(?.*[0-9]+.*\)?/ { sub(/__NR_/, "", $$2); print $$2; }' > $@
|
||||
|
||||
src/core/syscall-from-name.gperf: src/core/syscall-list.txt Makefile
|
||||
$(AM_V_at)$(MKDIR_P) $(dir $@)
|
||||
|
|
Loading…
Reference in New Issue