arpa_inet: Use the common idioms with C++ support.
[pspp] / modules / arpa_inet
index cec5d6c854a6eb42cc8c942f7beb1ccb0a40368b..34b988161cad97b948697e7f2edb73d3562e2f90 100644 (file)
@@ -7,6 +7,7 @@ m4/arpa_inet_h.m4
 
 Depends-on:
 arg-nonnull
+c++defs
 include_next
 sys_socket
 warn-on-use
@@ -20,7 +21,7 @@ BUILT_SOURCES += arpa/inet.h
 
 # We need the following in order to create <arpa/inet.h> when the system
 # doesn't have one.
-arpa/inet.h: arpa_inet.in.h $(WARN_ON_USE_H) $(ARG_NONNULL_H)
+arpa/inet.h: arpa_inet.in.h $(CXXDEFS_H) $(WARN_ON_USE_H) $(ARG_NONNULL_H)
        $(AM_V_at)$(MKDIR_P) arpa
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
@@ -34,6 +35,7 @@ arpa/inet.h: arpa_inet.in.h $(WARN_ON_USE_H) $(ARG_NONNULL_H)
              -e 's|@''GNULIB_INET_PTON''@|$(GNULIB_INET_PTON)|g' \
              -e 's|@''HAVE_DECL_INET_NTOP''@|$(HAVE_DECL_INET_NTOP)|g' \
              -e 's|@''HAVE_DECL_INET_PTON''@|$(HAVE_DECL_INET_PTON)|g' \
+             -e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \
              -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \
              -e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \
              < $(srcdir)/arpa_inet.in.h; \