summaryrefslogtreecommitdiffabout
authorSergey Poznyakoff <gray@gnu.org>2019-11-10 11:27:02 (GMT)
committer Sergey Poznyakoff <gray@gnu.org>2019-11-10 11:27:02 (GMT)
commitb8cdb89ea0af82b27137ee60ad1ffebd9f66a849 (patch) (side-by-side diff)
tree4ce228cb64e994bea7cd1640aacbb13bf4db9ae0
parent367aa99dd28cc74febe4e8c5f81df9812a41e05a (diff)
downloadmailutils-b8cdb89ea0af82b27137ee60ad1ffebd9f66a849.tar.gz
mailutils-b8cdb89ea0af82b27137ee60ad1ffebd9f66a849.tar.bz2
Create types.h when configuring.
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--configure.ac5
-rw-r--r--include/mailutils/Makefile.am6
-rw-r--r--include/mailutils/types.hin6
3 files changed, 7 insertions, 10 deletions
diff --git a/configure.ac b/configure.ac
index f74b10e..1a2f459 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1362,7 +1362,10 @@ AC_ARG_WITH([mh-bindir],
test -z "$server_list" && server_list=" [NONE]"
test -z "$client_list" && client_list=" [NONE]"
-
+
+# Create the installable types.h
+AC_CONFIG_FILES([include/mailutils/types.h:include/mailutils/types.hin])
+
# Initialize the (autotest) test suite.
AC_CONFIG_TESTDIR(testsuite)
diff --git a/include/mailutils/Makefile.am b/include/mailutils/Makefile.am
index a4a94ba..0179513 100644
--- a/include/mailutils/Makefile.am
+++ b/include/mailutils/Makefile.am
@@ -19,12 +19,6 @@ EXTRA_DIST=errno.hin types.hin
errno.h: $(top_srcdir)/libmailutils/diag/errors errno.hin
$(AM_V_GEN)$(AWK) -f $(mu_aux_dir)/generr.awk $(top_srcdir)/libmailutils/diag/errors errno.hin > errno.h
-types.h: $(top_srcdir)/include/mailutils/types.hin Makefile
- $(AM_V_GEN)sed -e 's/_MU_OFF_TYPE_/$(MU_OFF_TYPE)/' \
- -e 's/_MU_DEFAULT_RECORD_/$(MU_DEFAULT_RECORD)/' \
- -e 's/_MU_PRI_OFF_T_/$(MU_PRI_OFF_T)/' \
- $(top_srcdir)/include/mailutils/types.hin > types.h
-
gitinfo.h: $(top_srcdir)/ChangeLog
$(AM_V_GEN)if test "$(builddir)" = "$(srcdir)"; then \
test -d $(top_srcdir)/.git && $(GITINFO) -Hc -ogitinfo.h; \
diff --git a/include/mailutils/types.hin b/include/mailutils/types.hin
index fe02297..fcc6b4b 100644
--- a/include/mailutils/types.hin
+++ b/include/mailutils/types.hin
@@ -81,8 +81,8 @@ struct _mu_msgset;
struct mu_sockaddr; /* defined in mailutils/sockaddr.h */
struct mu_cidr; /* defined in mailutils/cidr.h */
-typedef _MU_OFF_TYPE_ mu_off_t;
-#define MU_PRI_OFF_T "_MU_PRI_OFF_T_"
+typedef @MU_OFF_TYPE@ mu_off_t;
+#define MU_PRI_OFF_T "@MU_PRI_OFF_T@"
typedef struct mu_address *mu_address_t;
typedef struct _mu_attribute *mu_attribute_t;
@@ -152,7 +152,7 @@ mu_prstr (char const *s)
return s ? s : "";
}
-#define MU_DEFAULT_RECORD _MU_DEFAULT_RECORD_
+#define MU_DEFAULT_RECORD @MU_DEFAULT_RECORD@
#ifdef __cplusplus
}

Return to:

Send suggestions and report system problems to the System administrator.