linux-user: fix strace build w/out munlockall
PATCH 1/1 linux-user: fix strace build w/out munlockall
Signed-off-by Mike Frysinger <[email protected]>
--- linux-user/strace.c | 2 ++ 1 file changed, 2 insertions(+)
linux-user/strace.c +2 -0
@@ -1380,6 +1380,7 @@ UNUSED static struct flags termios_lflags[] = { FLAG_END, }; +#ifdef TARGET_NR_mlockall UNUSED static struct flags mlockall_flags[] = {FLAG_TARGET (MCL_CURRENT ), FLAG_TARGET(MCL_FUTURE),
@@ -1388,6 +1389,7 @@ UNUSED static struct flags mlockall_flags[] = {#endif FLAG_END, }; +#endif /* IDs of the various system clocks */ #define TARGET_CLOCK_REALTIME 0
Signature · 1 line
2.39.0
Quoted 10 lines · Mike Frysinger
Signed-off-by Mike Frysinger <[email protected]>--- linux-user/strace.c | 2 ++ 1 file changed, 2 insertions(+)linux-user/strace.c +0
-0
linux-user/strace.c UNUSED static struct flags termios_lflags[] = { · line 1384
Quoted 5 lines
linux-user/strace.c +1
-0@@ -1380,6 +1380,7 @@ UNUSED static struct flags termios_lflags[] = { FLAG_END, }; +#ifdef TARGET_NR_mlockall UNUSED static struct flags mlockall_flags[] = {
Removing the 'UNUSED' qualifier:
Reviewed-by Philippe Mathieu-Daudé <[email protected]>
Quoted 10 lines
linux-user/strace.c +1
-0FLAG_TARGET (MCL_CURRENT ), FLAG_TARGET(MCL_FUTURE),@@ -1388,6 +1389,7 @@ UNUSED static struct flags mlockall_flags[] = {#endif FLAG_END, }; +#endif /* IDs of the various system clocks */ #define TARGET_CLOCK_REALTIME 0
PATCH v2 1/1 linux-user: fix strace build w/out munlockall
In reply to Mike FrysingerSigned-off-by Mike Frysinger <[email protected]>
Reviewed-by Philippe Mathieu-Daudé <[email protected]>
--- linux-user/strace.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
linux-user/strace.c +3 -1
@@ -1380,7 +1380,8 @@ UNUSED static struct flags termios_lflags[] = { FLAG_END, }; -UNUSED static struct flags mlockall_flags[] = { +#ifdef TARGET_NR_mlockall +static struct flags mlockall_flags[] = {FLAG_TARGET (MCL_CURRENT ),FLAG_TARGET (MCL_FUTURE ), #ifdef MCL_ONFAULT
@@ -1388,6 +1389,7 @@ UNUSED static struct flags mlockall_flags[] = {#endif FLAG_END, }; +#endif /* IDs of the various system clocks */ #define TARGET_CLOCK_REALTIME 0
Signature · 1 line
2.39.0
Laurent Vivier
AppliedLe 18/01/2023 à 10:01, Mike Frysinger a écrit :
Quoted 21 lines
Signed-off-by Mike Frysinger <[email protected]>Reviewed-by Philippe Mathieu-Daudé <[email protected]>--- linux-user/strace.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)linux-user/strace.c +2
-1@@ -1380,7 +1380,8 @@ UNUSED static struct flags termios_lflags[] = { FLAG_END, }; -UNUSED static struct flags mlockall_flags[] = { +#ifdef TARGET_NR_mlockall +static struct flags mlockall_flags[] = {FLAG_TARGET (MCL_CURRENT ),FLAG_TARGET (MCL_FUTURE ), #ifdef MCL_ONFAULT
linux-user/strace.c UNUSED static struct flags mlockall_flags[] = { · line 1395
Quoted 7 lines
linux-user/strace.c +1
-0@@ -1388,6 +1389,7 @@ UNUSED static struct flags mlockall_flags[] = {#endif FLAG_END, }; +#endif /* IDs of the various system clocks */ #define TARGET_CLOCK_REALTIME 0
Applied to my linux-user-for-8.0 branch.
Thanks,
Laurent