diff --git a/ghc/includes/SMClosures.lh b/ghc/includes/SMClosures.lh index 58e190749b0bce176e6a1992161de96b88fe6d10..3d57a018e4a6edde1b812aefe4dce51d848f6011 100644 --- a/ghc/includes/SMClosures.lh +++ b/ghc/includes/SMClosures.lh @@ -1067,7 +1067,11 @@ closures indexed by literal characters. As with @CONST@ closures, #define CHARLIKE_CLOSURE_NoNONPTRS(closure) (1L) /* Array of static charlike closures */ +#ifndef aix_TARGET_OS /* AIX gives link errors with consts in this file (RO assembler section) */ extern const W_ CHARLIKE_closures[]; +#else +extern W_ CHARLIKE_closures[]; +#endif /* Macro to retrieve static charlike closure */ #define CHARLIKE_CLOSURE(the_char) \ diff --git a/ghc/includes/SMInfoTables.lh b/ghc/includes/SMInfoTables.lh index 674444da878b2e3748ce2c63d604968cb9750ead..bcc65eb0bc55468fcf745c7b8018b45c664aa7b6 100644 --- a/ghc/includes/SMInfoTables.lh +++ b/ghc/includes/SMInfoTables.lh @@ -1746,7 +1746,11 @@ during a return. /* Declare the phantom info table vectors (just Bool at the moment) */ #ifndef COMPILING_GHC +#ifndef aix_TARGET_OS /* AIX gives link errors with this as a const (RO assembler section) */ EXTDATA_RO(PrelBase_Bool_itblvtbl); +#else +extern W_ PrelBase_Bool_itblvtbl[]; +#endif #endif \end{code}