Changeset 21d9736 in rtems


Ignore:
Timestamp:
May 29, 2010, 2:31:09 AM (9 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.10, 4.11, master
Children:
ce3386cd
Parents:
8f4ceeb
Message:

2010-05-29 Ralf Corsépius <ralf.corsepius@…>

  • libfs/src/nfsclient/src/dirutils.c: Add PRIomode_t, PRIdoff_t.
  • configure.ac: Add AC_CHECK_SIZEOF(mode_t), AC_CHECK_SIZEOF(off_t).
Location:
cpukit
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • cpukit/ChangeLog

    r8f4ceeb r21d9736  
     12010-05-29      Ralf Corsépius <ralf.corsepius@rtems.org>
     2
     3        * libfs/src/nfsclient/src/dirutils.c: Add PRIomode_t, PRIdoff_t.
     4        * configure.ac: Add AC_CHECK_SIZEOF(mode_t), AC_CHECK_SIZEOF(off_t).
     5
    162010-05-28      Ralf Corsépius <ralf.corsepius@rtems.org>
    27
  • cpukit/configure.ac

    r8f4ceeb r21d9736  
    249249AC_CHECK_DECLS([_POSIX_LOGIN_NAME_MAX],,,[#include <limits.h>])
    250250AC_CHECK_DECLS([CHAR_BIT],,,[#include <limits.h>])
     251
     252# FIXME: We should get rid of this.
     253# So far, only used in libfs/src/nfsclient/src/dirutils.c
     254AC_CHECK_SIZEOF([mode_t])
     255AC_CHECK_SIZEOF([off_t])
     256
    251257# FIXME: Mandatory in SUSv4, optional in SUSv3.
    252258#   Not implemented in GCC/newlib, so far.
  • cpukit/libfs/src/nfsclient/src/dirutils.c

    r8f4ceeb r21d9736  
    6767#include <limits.h> /* PATH_MAX */
    6868
     69#include <inttypes.h> /* PRI* */
     70
     71#if SIZEOF_MODE_T == 8
     72#define PRIomode_t PRIo64
     73#elif SIZEOF_MODE_T == 4
     74#define PRIomode_t PRIo32
     75#else
     76#error "unsupport size of mode_t"
     77#endif
     78
     79#if SIZEOF_OFF_T == 8
     80#define PRIdoff_t PRIo64
     81#elif SIZEOF_OFF_T == 4
     82#define PRIdoff_t PRIo32
     83#else
     84#error "unsupported size of off_t"
     85#endif
     86
    6987#ifdef HAVE_CEXP
    7088#include <cexpHelp.h>
     
    110128        }
    111129
    112         printf("%10li, %10lib, %5i.%-5i 0%04o %s%s\n",
     130        printf("%10li, %10" PRIdoff_t "b, %5i.%-5i 0%04" PRIomode_t " %s%s\n",
    113131                                buf->st_ino,
    114132                                buf->st_size,
Note: See TracChangeset for help on using the changeset viewer.