Mercurial > hg > octave-nkf > gnulib-hg
changeset 17763:c6e0ae5c3fec
dirname: support compilation with C++
* lib/dirname.h: Add necessary C linkage declarations.
author | Werner LEMBERG <wl@gnu.org> |
---|---|
date | Sun, 21 Sep 2014 17:10:15 +0200 |
parents | 8728cf80b7d8 |
children | 2e1bf0ada123 |
files | ChangeLog lib/dirname.h |
diffstat | 2 files changed, 13 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2014-09-21 Werner Lemberg <wl@gnu.org> + + dirname: support compilation with C++ + * lib/dirname.h: Add necessary C linkage declarations. + 2014-09-16 Paul Eggert <eggert@cs.ucla.edu> qsort_r: include <config.h>
--- a/lib/dirname.h +++ b/lib/dirname.h @@ -31,6 +31,10 @@ # define DOUBLE_SLASH_IS_DISTINCT_ROOT 0 # endif +#ifdef __cplusplus +extern "C" { +#endif + # if GNULIB_DIRNAME char *base_name (char const *file); char *dir_name (char const *file); @@ -43,4 +47,8 @@ bool strip_trailing_slashes (char *file); +#ifdef __cplusplus +} /* extern "C" */ +#endif + #endif /* not DIRNAME_H_ */