Bug 8571 - strace for ARC compile error
Summary: strace for ARC compile error
Status: RESOLVED FIXED
Alias: None
Product: buildroot
Classification: Unclassified
Component: Other (show other bugs)
Version: unspecified
Hardware: PC Linux
: P5 normal
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-12-23 20:15 UTC by mail
Modified: 2015-12-25 21:29 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mail 2015-12-23 20:15:31 UTC
Latest strace 4.11 for ARC does not compile:

/home/wbx/buildroot/output/host/usr/bin/arc-buildroot-linux-uclibc-gcc -DHAVE_CONFIG_H   -I./linux/arc -I./linux/arc -I./linux -I./linux -I. -I.  -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -Wall -Wwrite-strings -Wsign-compare -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -matomic -Os  -c -o strace-term.o `test -f 'term.c' || echo './'`term.c
In file included from syscall.c:34:0:
syscall.c:85:63: error: ‘sys_ARCH_mmap’ undeclared here (not in a function)
 #define SEN(syscall_name) SEN_ ## syscall_name, SYS_FUNC_NAME(sys_ ## syscall_name)
                                                               ^
defs.h:799:51: note: in definition of macro ‘MPERS_FUNC_NAME__’
 #define MPERS_FUNC_NAME__(prefix, name) prefix ## name
                                                   ^
defs.h:801:31: note: in expansion of macro ‘MPERS_FUNC_NAME_’
 #define MPERS_FUNC_NAME(name) MPERS_FUNC_NAME_(MPERS_PREFIX, name)
                               ^
defs.h:803:37: note: in expansion of macro ‘MPERS_FUNC_NAME’
 #define SYS_FUNC_NAME(syscall_name) MPERS_FUNC_NAME(syscall_name)
                                     ^
syscall.c:85:49: note: in expansion of macro ‘SYS_FUNC_NAME’
 #define SEN(syscall_name) SEN_ ## syscall_name, SYS_FUNC_NAME(sys_ ## syscall_name)
                                                 ^
./linux/32/syscallent.h:230:24: note: in expansion of macro ‘SEN’
 [222] = { 6, TD|TM|SI, SEN(ARCH_mmap),   "mmap2"   },
                        ^
/home/wbx/buildroot/output/host/usr/bin/arc-buildroot-linux-uclibc-gcc -DHAVE_CONFIG_H   -I./linux/arc -I./linux/arc -I./linux -I./linux -I. -I.  -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -Wall -Wwrite-strings -Wsign-compare -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -matomic -Os  -c -o strace-time.o `test -f 'time.c' || echo './'`time.c
In file included from syscall.c:1351:0:
./linux/arc/get_syscall_args.c: In function ‘get_syscall_args’:
./linux/arc/get_syscall_args.c:5:19: warning: pointer targets in initialization differ in signedness [-Wpointer-sign]
  long *arc_args = &arc_regs.scratch.r0;
                   ^
make[3]: *** [strace-syscall.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory `/home/wbx/buildroot/output/build/strace-4.11'
Comment 1 Thomas Petazzoni 2015-12-23 21:58:29 UTC
Thanks for the report. This has also been found by our autobuilders: http://autobuild.buildroot.org/?reason=strace-4.11. I just mailed Alexey Brodkin, who maintains the ARC support in Buildroot, to point him to this bug.
Comment 2 Alexey Brodkin 2015-12-25 21:27:45 UTC
Fixed by http://patchwork.ozlabs.org/patch/561060/