[OE-core] [PATCH 3/3] tclibc-musl: Add -D__USE_TIME_BITS64 to c/c++ flags

André Draszik git at andred.net
Mon Jan 6 17:08:09 UTC 2020


On Thu, 2020-01-02 at 23:21 -0800, Khem Raj wrote:
> This is needed for 64bit time_t support on 32bit architectures
> see [1]
> 
> [1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit?id=152194fe9c3f

As per the above, __USE_TIME_BITS64 is a glibc-internal macro, to be defined (by glibc),
when the application requestion 64 bit time_t via #define _TIME_BITS 64

Is the behaviour different on musl? Should this patch instead set _TIME_BITS?

Cheers,
Andre'


> 
> Signed-off-by: Khem Raj <raj.khem at gmail.com>
> ---
>  meta/conf/distro/include/tclibc-musl.inc | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/meta/conf/distro/include/tclibc-musl.inc b/meta/conf/distro/include/tclibc-musl.inc
> index 8badbbb40a..22f8214ba3 100644
> --- a/meta/conf/distro/include/tclibc-musl.inc
> +++ b/meta/conf/distro/include/tclibc-musl.inc
> @@ -18,6 +18,7 @@ DISTRO_FEATURES_BACKFILL_CONSIDERED += "ldconfig"
>  #USE_NLS ?= "no"
>  
>  CXXFLAGS += "-fvisibility-inlines-hidden"
> +TARGET_CC_ARCH += "-D__USE_TIME_BITS64"
>  
>  IMAGE_LINGUAS = ""
>  
> -- 
> 2.24.1
> 



More information about the Openembedded-core mailing list