diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2021-01-22 11:45:38 -0800 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2021-01-22 12:02:55 -0800 |
commit | a900e641fa1fd765799f12a7f699f768ebfccfe8 (patch) | |
tree | a874eba952d3e51190a2bfe26cfe6c1635e9fda1 /lib/string.in.h | |
parent | 9143eba0c6861f467c18bc52d66e6f5c573be56b (diff) | |
download | emacs-a900e641fa1fd765799f12a7f699f768ebfccfe8.tar.gz |
Update from Gnulib by running admin/merge-gnulib
Diffstat (limited to 'lib/string.in.h')
-rw-r--r-- | lib/string.in.h | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/lib/string.in.h b/lib/string.in.h index 9f68e77c767..c76c1820b36 100644 --- a/lib/string.in.h +++ b/lib/string.in.h @@ -69,6 +69,14 @@ # include <unistd.h> #endif +/* AIX 7.2 declares ffsl and ffsll in <strings.h>, not in <string.h>. */ +/* But in any case avoid namespace pollution on glibc systems. */ +#if ((@GNULIB_FFSL@ || @GNULIB_FFSLL@ || defined GNULIB_POSIXCHECK) \ + && defined _AIX) \ + && ! defined __GLIBC__ +# include <strings.h> +#endif + /* The definitions of _GL_FUNCDECL_RPL etc. are copied here. */ /* The definition of _GL_ARG_NONNULL is copied here. */ @@ -110,10 +118,18 @@ _GL_WARN_ON_USE (ffsl, "ffsl is not portable - use the ffsl module"); /* Find the index of the least-significant set bit. */ #if @GNULIB_FFSLL@ -# if !@HAVE_FFSLL@ +# if @REPLACE_FFSLL@ +# if !(defined __cplusplus && defined GNULIB_NAMESPACE) +# define ffsll rpl_ffsll +# endif +_GL_FUNCDECL_RPL (ffsll, int, (long long int i)); +_GL_CXXALIAS_RPL (ffsll, int, (long long int i)); +# else +# if !@HAVE_FFSLL@ _GL_FUNCDECL_SYS (ffsll, int, (long long int i)); -# endif +# endif _GL_CXXALIAS_SYS (ffsll, int, (long long int i)); +# endif _GL_CXXALIASWARN (ffsll); #elif defined GNULIB_POSIXCHECK # undef ffsll |