]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
Move lib/gnutls.h.in.in into includes/gnutls/gnutls.h.in.
authorSimon Josefsson <simon@josefsson.org>
Fri, 15 Apr 2005 00:12:32 +0000 (00:12 +0000)
committerSimon Josefsson <simon@josefsson.org>
Fri, 15 Apr 2005 00:12:32 +0000 (00:12 +0000)
Fix #warning about missing components, it didn't work in config.status.
Simplify configure.ac wrt to gnutls.h.

configure.in
includes/gnutls/gnutls.h.in [moved from lib/gnutls.h.in.in with 99% similarity]

index 036f5839a4e5ff9f0bbc368d9b0ddcb8eb4cd977..2d7a1900d37e44b2bc9069fe045863178f096ea8 100644 (file)
@@ -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
similarity index 99%
rename from lib/gnutls.h.in.in
rename to includes/gnutls/gnutls.h.in
index 8e5461c942ba95fed74b2e8ad08f2b542e59bf89..c21fc77b422befb8fdb253deb0195cb1ec18049c 100644 (file)
@@ -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 */