[PATCH] strace: solve ilp32 strace build error

Dmitry V. Levin ldv at strace.io
Sat Mar 25 21:42:17 UTC 2023


On Fri, Mar 24, 2023 at 01:43:49AM +0000, chenzanyu wrote:
> When constructing, HAVE_ARCH_OLD_TIME64_SYSCALLS SIZEOF_LONG == 8,
> resulting in failure to build ilp32, need to add SIZEOF_LONG == 4 to fit ilp32
> 
> The build error log is as follows:
> ERROR: ilp32-strace-5.14 do_compile: oe_runmake failed
> ERROR: ilp32-strace-5.14 do_compile: ExecutionError('/home/ck/strace/czy/tmp-glibc/work/aarch64_ilp32-eulermlilp32-linux-gnu_ilp32/ilp32-strace/5.14/temp/run.do_compile.19077', 1, None, None)
> ERROR: Logfile of failure stored in: /home/ck/strace/czy/tmp-glibc/work/aarch64_ilp32-eulermlilp32-linux-gnu_ilp32/ilp32-strace/5.14/temp/log.do_compile.19077
> NOTE: recipe ilp32-strace-5.14: task do_compile: Failed
> 
> Signed-off-by: chenzanyu <chenzanyu at huawei.com>
> ---
>  src/arch_defs.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/arch_defs.h b/src/arch_defs.h
> index bb35252..500212f 100644
> --- a/src/arch_defs.h
> +++ b/src/arch_defs.h
> @@ -66,7 +66,7 @@
>  # endif
>  
>  # ifndef HAVE_ARCH_OLD_TIME64_SYSCALLS
> -#  define HAVE_ARCH_OLD_TIME64_SYSCALLS (SIZEOF_LONG == 8)
> +#  define HAVE_ARCH_OLD_TIME64_SYSCALLS ((SIZEOF_LONG == 4) || (SIZEOF_LONG == 8))
>  # endif
>  
>  # ifndef MIN_KLONGSIZE

The patch to change the default for 32-bit architectures is definitely
incorrect because none of them used to provide old style time64 syscalls.

What is the ilp32 architecture you're trying to build,
and why does it provide old style time64 syscalls?


-- 
ldv


More information about the Strace-devel mailing list