]> git.ipfire.org Git - thirdparty/ldns.git/commitdiff
Suppress warnings from automatically generated code by SWIG.
authorWillem Toorop <willem@NLnetLabs.nl>
Mon, 19 Sep 2011 21:28:39 +0000 (21:28 +0000)
committerWillem Toorop <willem@NLnetLabs.nl>
Mon, 19 Sep 2011 21:28:39 +0000 (21:28 +0000)
Reformat some of the comments to prevent "warning: marco .... not defined" messages
Adapted configure.ac to nu use PYTHON_VERSION directly (as advised in the ax_python_devel package).

configure.ac
ldns/buffer.h
ldns/dnssec_verify.h

index e259e069c9bc94454a87e5ed97e1f417db80f125..0d0b3a251233a7ab7d63bf484a156989b9fa52c3 100644 (file)
@@ -93,15 +93,8 @@ if test x_$withval != x_no; then
    sinclude(ax_python_devel.m4)
    ac_save_LIBS="$LIBS" dnl otherwise AC_PYTHON_DEVEL thrashes $LIBS
 
-   AX_PYTHON_DEVEL
-   if test ! -z "$PYTHON_VERSION"; then
-        if test `$PYTHON -c "import sys; \
-            ver = sys.version.split()[[0]]; \
-            print(ver >= '2.4.0')"` = "False"; then
-                AC_MSG_ERROR([Python version >= 2.4.0 is required])
-        fi
-       # Have Python
-       AC_DEFINE(HAVE_PYTHON,1,[Define if you have Python libraries and header files.])
+   AX_PYTHON_DEVEL([>= '2.4.0'])
+   if test ! -z "$ac_python_version"; then
        ldns_have_python=yes
    fi
 
@@ -139,6 +132,9 @@ if test x_$withval != x_no; then
    # xtra cflags for pyldns
    if test x_$ldns_have_python != x_no; then
        ACX_CHECK_COMPILER_FLAG(fno-strict-aliasing, [PYTHON_X_CFLAGS="-fno-strict-aliasing"])
+       ACX_CHECK_COMPILER_FLAG(Wno-missing-field-initializers, [PYTHON_X_CFLAGS="-Wno-missing-field-initializers $PYTHON_X_CFLAGS"])
+       ACX_CHECK_COMPILER_FLAG(Wno-unused-parameter, [PYTHON_X_CFLAGS="-Wno-unused-parameter $PYTHON_X_CFLAGS"])
+       ACX_CHECK_COMPILER_FLAG(Wno-unused-variable, [PYTHON_X_CFLAGS="-Wno-unused-variable $PYTHON_X_CFLAGS"])
    fi
 fi
 AC_SUBST(PYTHON_X_CFLAGS)
index 65b8bdc4ad67c8f06200a4bcc62a33de88396b80..03df14c99158bee12b47c5c05ceeb6a78c977804 100644 (file)
@@ -607,8 +607,8 @@ ldns_buffer_status_ok(ldns_buffer *buffer)
 
 /**
  * prints to the buffer, increasing the capacity if required using
- * buffer_reserve(). The buffer's position is set to the terminating
- * '\\0'. Returns the number of characters written (not including the
+ * buffer_reserve(). The buffer's position is set to the terminating '\\0'
+ * Returns the number of characters written (not including the
  * terminating '\\0') or -1 on failure.
  */
 int ldns_buffer_printf(ldns_buffer *buffer, const char *format, ...);
index cfed9e602beef8379a4474b24272a04b484c4bcd..13b3fa32570f99e9fa45462a289350e26fdb1d1a 100644 (file)
@@ -224,8 +224,7 @@ ldns_dnssec_trust_tree *ldns_dnssec_derive_trust_tree(
                                           ldns_rr *rr);
 
 /**
- * Sub function for derive_trust_tree that is used for a
- * 'normal' rrset
+ * Sub function for derive_trust_tree that is used for a 'normal' rrset
  *
  * \param[in] new_tree The trust tree that we are building
  * \param[in] data_chain The data chain containing the data for the trust tree