Skip to content

Commit

Permalink
toolchain/ghs: Fix green hills toolchain build Vela "no storage class…
Browse files Browse the repository at this point in the history
… or type specifier" error

"libcxxmini/libxx_cxa_guard.cxx", line 47: error apache#77-D: this declaration has
          no storage class or type specifier
  __extension__ typedef int __guard __attribute__((mode(__DI__)));
  ^

"libcxxmini/libxx_cxa_guard.cxx", line 47: error apache#65: expected a ";"
  __extension__ typedef int __guard __attribute__((mode(__DI__)));
                ^

"libcxxmini/libxx_cxa_guard.cxx", line 64: error apache#20: identifier "__guard" is
          undefined
    int __cxa_guard_acquire(FAR __guard *g)
                                ^

"libcxxmini/libxx_cxa_guard.cxx", line 64: error apache#20: identifier "g" is
          undefined
    int __cxa_guard_acquire(FAR __guard *g)
                                         ^

"libcxxmini/libxx_cxa_guard.cxx", line 65: error apache#65: expected a ";"
    {
    ^

"libcxxmini/libxx_cxa_guard.cxx", line 93: warning apache#12-D: parsing restarts
          here after previous syntax error
  }

Signed-off-by: yanghuatao <[email protected]>
  • Loading branch information
yanghuatao authored and extinguish committed Aug 6, 2024
1 parent 439b9e9 commit c0a3599
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions include/nuttx/compiler.h
Original file line number Diff line number Diff line change
Expand Up @@ -1110,6 +1110,14 @@

#endif

/* Green Hills Software definitions *****************************************/

#if defined(__ghs__)

# define __extension__

#endif

#ifndef CONFIG_HAVE_LONG_LONG
# undef CONFIG_FS_LARGEFILE
#endif
Expand Down

0 comments on commit c0a3599

Please sign in to comment.