(root)/
strace-6.5/
src/
xlat/
access_modes.h
       1  /* Generated by ./src/xlat/gen.sh from ./src/xlat/access_modes.in; do not edit. */
       2  
       3  #include "gcc_compat.h"
       4  #include "static_assert.h"
       5  
       6  #if defined(F_OK) || (defined(HAVE_DECL_F_OK) && HAVE_DECL_F_OK)
       7  DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
       8  static_assert((F_OK) == (0), "F_OK != 0");
       9  DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
      10  #else
      11  # define F_OK 0
      12  #endif
      13  #if defined(R_OK) || (defined(HAVE_DECL_R_OK) && HAVE_DECL_R_OK)
      14  DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
      15  static_assert((R_OK) == (4), "R_OK != 4");
      16  DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
      17  #else
      18  # define R_OK 4
      19  #endif
      20  #if defined(W_OK) || (defined(HAVE_DECL_W_OK) && HAVE_DECL_W_OK)
      21  DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
      22  static_assert((W_OK) == (2), "W_OK != 2");
      23  DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
      24  #else
      25  # define W_OK 2
      26  #endif
      27  #if defined(X_OK) || (defined(HAVE_DECL_X_OK) && HAVE_DECL_X_OK)
      28  DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
      29  static_assert((X_OK) == (1), "X_OK != 1");
      30  DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
      31  #else
      32  # define X_OK 1
      33  #endif
      34  #undef XLAT_PREV_VAL
      35  
      36  #ifndef XLAT_MACROS_ONLY
      37  
      38  # ifdef IN_MPERS
      39  
      40  #  error static const struct xlat access_modes in mpers mode
      41  
      42  # else
      43  
      44  DIAG_PUSH_IGNORE_TAUTOLOGICAL_CONSTANT_COMPARE
      45  static const struct xlat_data access_modes_xdata[] = {
      46   XLAT(F_OK),
      47   #define XLAT_VAL_0 ((unsigned) (F_OK))
      48   #define XLAT_STR_0 STRINGIFY(F_OK)
      49   XLAT(R_OK),
      50   #define XLAT_VAL_1 ((unsigned) (R_OK))
      51   #define XLAT_STR_1 STRINGIFY(R_OK)
      52   XLAT(W_OK),
      53   #define XLAT_VAL_2 ((unsigned) (W_OK))
      54   #define XLAT_STR_2 STRINGIFY(W_OK)
      55   XLAT(X_OK),
      56   #define XLAT_VAL_3 ((unsigned) (X_OK))
      57   #define XLAT_STR_3 STRINGIFY(X_OK)
      58  };
      59  static
      60  const struct xlat access_modes[1] = { {
      61   .data = access_modes_xdata,
      62   .size = ARRAY_SIZE(access_modes_xdata),
      63   .type = XT_NORMAL,
      64   .flags_mask = 0
      65  #  ifdef XLAT_VAL_0
      66    | XLAT_VAL_0
      67  #  endif
      68  #  ifdef XLAT_VAL_1
      69    | XLAT_VAL_1
      70  #  endif
      71  #  ifdef XLAT_VAL_2
      72    | XLAT_VAL_2
      73  #  endif
      74  #  ifdef XLAT_VAL_3
      75    | XLAT_VAL_3
      76  #  endif
      77    ,
      78   .flags_strsz = 0
      79  #  ifdef XLAT_STR_0
      80    + sizeof(XLAT_STR_0)
      81  #  endif
      82  #  ifdef XLAT_STR_1
      83    + sizeof(XLAT_STR_1)
      84  #  endif
      85  #  ifdef XLAT_STR_2
      86    + sizeof(XLAT_STR_2)
      87  #  endif
      88  #  ifdef XLAT_STR_3
      89    + sizeof(XLAT_STR_3)
      90  #  endif
      91    ,
      92  } };
      93  DIAG_POP_IGNORE_TAUTOLOGICAL_CONSTANT_COMPARE
      94  
      95  #  undef XLAT_STR_0
      96  #  undef XLAT_VAL_0
      97  #  undef XLAT_STR_1
      98  #  undef XLAT_VAL_1
      99  #  undef XLAT_STR_2
     100  #  undef XLAT_VAL_2
     101  #  undef XLAT_STR_3
     102  #  undef XLAT_VAL_3
     103  # endif /* !IN_MPERS */
     104  
     105  #endif /* !XLAT_MACROS_ONLY */