Imported Upstream version 4.9
[platform/upstream/libtasn1.git] / configure.ac
index 76a4298..7a14e04 100644 (file)
@@ -1,5 +1,5 @@
 dnl Process this file with autoconf to produce a configure script.
-# Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation
+# Copyright (C) 2002-2014 Free Software Foundation, Inc.
 #
 # This file is part of LIBTASN1.
 #
@@ -16,58 +16,57 @@ dnl Process this file with autoconf to produce a configure script.
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-AC_PREREQ(2.61)
-AC_INIT([GNU Libtasn1], [2.4], [bug-gnutls@gnu.org])
+AC_PREREQ([2.61])
+AC_INIT([GNU Libtasn1],[4.9],[help-libtasn1@gnu.org])
 AC_CONFIG_AUX_DIR([build-aux])
 AC_CONFIG_MACRO_DIR([m4])
 AC_CONFIG_HEADERS(config.h)
-AM_INIT_AUTOMAKE([1.10 -Wall -Werror -Wno-override])
+AM_INIT_AUTOMAKE([1.10 -Wall -Wno-override])
+AM_SILENT_RULES([yes])
 
 # Library code modified:                              REVISION++
 # Interfaces changed/added/removed:   CURRENT++       REVISION=0
 # Interfaces added:                             AGE++
 # Interfaces removed:                           AGE=0
-AC_SUBST(LT_CURRENT, 4)
-AC_SUBST(LT_REVISION, 7)
-AC_SUBST(LT_AGE, 1)
+AC_SUBST(LT_CURRENT, 11)
+AC_SUBST(LT_REVISION, 2)
+AC_SUBST(LT_AGE, 5)
 
 AC_PROG_CC
 gl_EARLY
 lgl_EARLY
 AC_PROG_YACC
-AC_PROG_LN_S
+
+AC_ARG_ENABLE(doc,
+  AS_HELP_STRING([--disable-doc], [don't generate any documentation]),
+    enable_doc=$enableval, enable_doc=yes)
+AM_CONDITIONAL(ENABLE_DOC, test "$enable_doc" != "no")
 
 dnl Checks for programs.
-AC_PROG_INSTALL
-AM_MISSING_PROG(PERL, perl, $missing_dir)
 AM_MISSING_PROG(HELP2MAN, help2man, $missing_dir)
-
 AC_LIBTOOL_WIN32_DLL
+AM_PROG_AR
 AM_PROG_LIBTOOL
+GTK_DOC_CHECK(1.2)
 
 AC_CHECK_SIZEOF(unsigned long int, 4)
 AC_CHECK_SIZEOF(unsigned int, 4)
 
-sj_VALGRIND
 sj_UPDATE_HEADER_VERSION([$srcdir/lib/libtasn1.h])
 
-# Check for gtk-doc.
-GTK_DOC_CHECK(1.2)
-
 # For gnulib compatibility modules.
 gl_INIT
 lgl_INIT
 
-
 AC_ARG_ENABLE([gcc-warnings],
-  [AS_HELP_STRING([--enable-gcc-warnings],
-                 [turn on lots of GCC warnings (for developers)])],
+  [AS_HELP_STRING([--disable-gcc-warnings],
+                 [disable GCC warnings (for developers)])],
   [case $enableval in
      yes|no) ;;
      *)      AC_MSG_ERROR([bad value $enableval for gcc-warnings option]) ;;
    esac
    gl_gcc_warnings=$enableval],
-  [gl_gcc_warnings=no]
+  [gl_gcc_warnings=yes]
 )
 
 if test "$gl_gcc_warnings" = yes; then
@@ -79,13 +78,15 @@ if test "$gl_gcc_warnings" = yes; then
   nw="$nw -Wtraditional-conversion" # Too many warnings for now
   nw="$nw -Wconversion"             # Too many warnings for now
   nw="$nw -Wsign-conversion"        # Too many warnings for now
-  nw="$nw -Wold-style-definition"   # 
+  nw="$nw -Wold-style-definition"   #
   nw="$nw -Wpadded"                 # Our structs are not padded
-  nw="$nw -Wundef"                  # 
+  nw="$nw -Wundef"                  #
   nw="$nw -Wunreachable-code"       # Too many false positives
   nw="$nw -Wunused-macros"          # Breaks on bison generated ASN1.c
+  nw="$nw -Wswitch-default"         # Breaks on bison generated ASN1.c
   nw="$nw -Wunsafe-loop-optimizations"
   nw="$nw -Wstrict-overflow"
+  nw="$nw -Wsuggest-attribute=pure" # Is it worth using pure attributes?
 
   gl_MANYWARN_ALL_GCC([ws])
   gl_MANYWARN_COMPLEMENT(ws, [$ws], [$nw])
@@ -93,9 +94,8 @@ if test "$gl_gcc_warnings" = yes; then
     gl_WARN_ADD([$w])
   done
 
+  gl_WARN_ADD([-Wno-type-limits])
   gl_WARN_ADD([-Wno-missing-field-initializers])
-  gl_WARN_ADD([-Wno-sign-compare])
-  gl_WARN_ADD([-Wno-pointer-sign])
   gl_WARN_ADD([-Wno-unused-parameter])
   gl_WARN_ADD([-Wno-stack-protector])            # Some functions cannot be protected
   gl_WARN_ADD([-fdiagnostics-show-option])
@@ -106,6 +106,7 @@ AC_CONFIG_FILES([
   doc/Makefile
   doc/cyclo/Makefile
   doc/reference/Makefile
+  doc/reference/version.xml
   examples/Makefile
   gl/Makefile
   lib/Makefile