From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 128885 invoked by alias); 13 Aug 2019 18:30:05 -0000 Mailing-List: contact newlib-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: newlib-owner@sourceware.org Received: (qmail 128867 invoked by uid 89); 13 Aug 2019 18:30:04 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-34.6 required=5.0 tests=AWL,BAYES_00,ENV_AND_HDR_SPF_MATCH,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,HTML_MESSAGE,KAM_NUMSUBJECT,RCVD_IN_DNSWL_NONE,SPF_PASS,USER_IN_DEF_SPF_WL autolearn=ham version=3.3.1 spammy=PhD, phd, H*c:alternative X-HELO: mail-oi1-f195.google.com Received: from mail-oi1-f195.google.com (HELO mail-oi1-f195.google.com) (209.85.167.195) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 13 Aug 2019 18:30:02 +0000 Received: by mail-oi1-f195.google.com with SMTP id h21so16110oie.7 for ; Tue, 13 Aug 2019 11:30:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=yvAWXdsvSUp+PaQEmrfdpsxzZqCc2w2nxTE+S9Eh7ow=; b=Rco+KDGtO0GRY53k+xLs84xI/j7F5WpVU66IDWzEtUbhVOz4iZTckVIVYlDFCrhcs6 IGB71KhANReKtR7lQjnHNogo1GnArNuGJXV93zz52cboYFBXeJjpfN97Ix8BPXNF7z/H CJPpj93Yq6XYOZKyCsSqFOtNcatoHZIs2iMI5rLisQM7OdI1ij/aTBPKSyNojayG2Kul SwXsJzgG+vUbhPdRg/Wk8xckx474Gug21s/VwISSxtFrRkyjWp8mPAVWXlxDXG63fE7t g86XuZoSvmeLxM6f/T4WW9C0bgOBuXfjLsjZ9RFoQlawItNyzQ8cj9pLtLXjhnkU6GAl pmzQ== MIME-Version: 1.0 From: "Dionna Amalie Glaze via newlib" Reply-To: Dionna Amalie Glaze Date: Tue, 13 Aug 2019 18:30:00 -0000 Message-ID: Subject: [PATCH] Make st_*tim visible in stat for POSIX.1-2008 To: newlib@sourceware.org Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2019/txt/msg00479.txt.bz2 The st_{a,c,m}tim fields are needed for POSIX.1-2008, not just RTEMS. Signed-off-by: Dionna Glaze --- newlib/libc/include/sys/stat.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/newlib/libc/include/sys/stat.h b/newlib/libc/include/sys/stat.h index eee98db64..052ef5a66 100644 --- a/newlib/libc/include/sys/stat.h +++ b/newlib/libc/include/sys/stat.h @@ -34,10 +34,12 @@ struct stat gid_t st_gid; dev_t st_rdev; off_t st_size; -#if defined(__rtems__) +#if defined(__USE_MISC) || __POSIX_VISIBLE >= 200809 struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; +#endif +#if defined(__rtems__) blksize_t st_blksize; blkcnt_t st_blocks; #else @@ -60,7 +62,7 @@ struct stat #endif }; -#if defined(__rtems__) +#if __POSIX_VISIBLE >= 200809 #define st_atime st_atim.tv_sec #define st_ctime st_ctim.tv_sec #define st_mtime st_mtim.tv_sec -- -Dionna Glaze, PhD (she/her)