summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Josefsson <simon@josefsson.org>2005-04-15 00:12:32 +0000
committerSimon Josefsson <simon@josefsson.org>2005-04-15 00:12:32 +0000
commit419aebcc6891cfbfdd3bc8a998b8500933afc6d0 (patch)
treebe680759858bf4fa6569b27cfa7860066f3bcf49
parent41738c775f1ce818441f866d741eaefc125540ac (diff)
downloadgnutls-419aebcc6891cfbfdd3bc8a998b8500933afc6d0.tar.gz
Move lib/gnutls.h.in.in into includes/gnutls/gnutls.h.in.
Fix #warning about missing components, it didn't work in config.status. Simplify configure.ac wrt to gnutls.h.
-rw-r--r--configure.in40
-rw-r--r--includes/gnutls/gnutls.h.in (renamed from lib/gnutls.h.in.in)8
2 files changed, 24 insertions, 24 deletions
diff --git a/configure.in b/configure.in
index 036f5839a4..2d7a1900d3 100644
--- a/configure.in
+++ b/configure.in
@@ -492,37 +492,29 @@ AC_MSG_WARN(***
fi
fi
-AC_CONFIG_FILES(lib/gnutls.h.in)
-
-AC_CONFIG_COMMANDS([includes/gnutls/gnutls.h],[[
- test -f lib/gnutls.h.in || (echo "Could not generate includes/gnutls/gnutls.h" && exit 1)
- cat lib/gnutls.h.in > includes/gnutls/gnutls.h
- echo "" >> includes/gnutls/gnutls.h
- echo "#ifdef __cplusplus" >> includes/gnutls/gnutls.h
- echo "}" >> includes/gnutls/gnutls.h
- echo "#endif" >> includes/gnutls/gnutls.h
-
if test $ac_full -eq 0; then
- echo "#ifdef __GNUC__" >> includes/gnutls/gnutls.h
- echo "#warning This is not the official GnuTLS library. Several features were disabled at compilation." >> includes/gnutls/gnutls.h
- echo "#endif /* __GNUC__ */" >> includes/gnutls/gnutls.h
+ AC_SUBST(POSSIBLY_WARN_ABOUT_MISSING_FEATURES, [[
+#ifdef __GNUC__
+#warning This is not the official GnuTLS library. Several features were disabled at compilation.
+#endif /* __GNUC__ */]])
fi
- echo "#endif /* GNUTLS_H */" >> includes/gnutls/gnutls.h
- echo "" >> includes/gnutls/gnutls.h
+AC_CONFIG_COMMANDS([chmod-config],[[
chmod +x lib/libgnutls-config
chmod +x libextra/libgnutls-extra-config
]],[[]])
AC_CONFIG_FILES([Makefile src/Makefile libextra/Makefile lib/Makefile \
-libextra/openpgp/Makefile libextra/opencdk/Makefile doc/reference/Makefile \
-lib/libgnutls-config libextra/libgnutls-extra-config \
-doc/Makefile src/x509/Makefile src/srp/Makefile src/openpgp/Makefile \
-src/cfg/Makefile src/cfg/platon/Makefile src/cfg/platon/str/Makefile \
-doc/scripts/Makefile lib/minitasn1/Makefile lib/x509/Makefile \
-includes/Makefile includes/gnutls/Makefile doc/manpages/Makefile \
-gl/Makefile nettle/Makefile nettle/tests/Makefile \
-crypto/Makefile tests/Makefile \
-lib/gnutls.pc libextra/gnutls-extra.pc])
+ libextra/openpgp/Makefile libextra/opencdk/Makefile \
+ doc/reference/Makefile \
+ lib/libgnutls-config libextra/libgnutls-extra-config \
+ doc/Makefile src/x509/Makefile src/srp/Makefile src/openpgp/Makefile \
+ src/cfg/Makefile src/cfg/platon/Makefile src/cfg/platon/str/Makefile \
+ doc/scripts/Makefile lib/minitasn1/Makefile lib/x509/Makefile \
+ includes/Makefile includes/gnutls/Makefile doc/manpages/Makefile \
+ gl/Makefile nettle/Makefile nettle/tests/Makefile \
+ crypto/Makefile tests/Makefile \
+ lib/gnutls.pc libextra/gnutls-extra.pc \
+ includes/gnutls/gnutls.h])
AC_OUTPUT
diff --git a/lib/gnutls.h.in.in b/includes/gnutls/gnutls.h.in
index 8e5461c942..c21fc77b42 100644
--- a/lib/gnutls.h.in.in
+++ b/includes/gnutls/gnutls.h.in
@@ -42,6 +42,8 @@ extern "C" {
#define LIBGNUTLS_VERSION "@VERSION@"
+@POSSIBLY_WARN_ABOUT_MISSING_FEATURES@
+
/* Get size_t. */
#include <stddef.h>
@@ -866,3 +868,9 @@ int gnutls_srp_base64_decode_alloc( const gnutls_datum_t *b64_data,
#define GNUTLS_E_RANDOM_FAILED -206
#define GNUTLS_E_UNIMPLEMENTED_FEATURE -1250
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* GNUTLS_H */