"Fossies" - the Fresh Open Source Software Archive

Member "recode-3.7.12/configure.ac" (17 Feb 2022, 3794 Bytes) of package /linux/misc/recode-3.7.12.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the latest Fossies "Diffs" side-by-side code changes report for "configure.ac": 3.7.11_vs_3.7.12.

    1 # Configure template for Recode.
    2 # Copyright (C) 1994-2022 Free Software Foundation, Inc.
    3 # Process this file with autoconf to produce a configure script.
    4 
    5 AC_PREREQ(2.69)
    6 AC_INIT(recode, 3.7.12, [rrt@sc3d.org])
    7 AC_CONFIG_SRCDIR(src/recode.c)
    8 AC_CONFIG_AUX_DIR([build-aux])
    9 AM_INIT_AUTOMAKE
   10 AC_CONFIG_MACRO_DIR(m4)
   11 AC_CANONICAL_HOST
   12 
   13 dnl Release number rules:
   14 dnl This is derived from "Versioning" chapter of info libtool documentation.
   15 dnl Format is MAJOR:MINOR:MICRO
   16 dnl     4a) Increment major when removing or changing interfaces.
   17 dnl     4a) 5) Increment minor when adding interfaces.
   18 dnl     6) Set minor to zero when removing or changing interfaces.
   19 dnl     3) Increment micro when interfaces not changed at all,
   20 dnl               only bug fixes or internal changes made.
   21 dnl     4b) Set micro to zero when adding, removing or changing interfaces.
   22 
   23 dnl First extract pieces from the version number string
   24 RECODE_MAJOR_VERSION=`echo $VERSION | awk -F. '{print $1}'`
   25 RECODE_MINOR_VERSION=`echo $VERSION | awk -F. '{print $2}'`
   26 RECODE_MICRO_VERSION=`echo $VERSION | awk -F. '{print $3}'`
   27 
   28 dnl Version info for libraries = CURRENT:REVISION:AGE
   29 RECODE_SONUM=$RECODE_MAJOR_VERSION
   30 AGE=$RECODE_MINOR_VERSION
   31 REVISION=$RECODE_MICRO_VERSION
   32 CURRENT=`expr $RECODE_SONUM + $AGE`
   33 VERSION_INFO=$CURRENT:$REVISION:$AGE
   34 AC_SUBST(VERSION_INFO)
   35 
   36 AC_PROG_CC_C99
   37 gl_EARLY
   38 LT_INIT
   39 AC_PROG_LEX
   40 AM_PATH_PYTHON([3.5])
   41 gl_INIT
   42 
   43 dnl help2man
   44 dnl Set a value even if not found, so that an invocation via build-aux/missing works
   45 AC_PATH_PROG([HELP2MAN], [help2man], [help2man])
   46 
   47 dnl Cython
   48 AC_CHECK_PROGS([CYTHON], [cython3 cython])
   49 AM_CONDITIONAL([HAVE_CYTHON], test -n "$ac_cv_prog_CYTHON")
   50 
   51 AC_SUBST([objdir])
   52 LT_SYS_MODULE_EXT
   53 case $host_os in
   54   *mingw* )  pyextext=.pyd;;
   55   *cygwin*)  pyextext=.dll;;
   56   * )        pyextext=.so;;
   57 esac
   58 AC_SUBST([pyextext], [$pyextext])
   59 
   60 dnl Extra warnings with GCC and compatible compilers
   61 AC_ARG_ENABLE([gcc-warnings],
   62   [AS_HELP_STRING([--disable-gcc-warnings],
   63                   [turn off lots of GCC warnings])],
   64   [case $enableval in
   65      yes|no) ;;
   66      *)      AC_MSG_ERROR([bad value $enableval for gcc-warnings option]) ;;
   67    esac
   68    gl_gcc_warnings=$enableval],
   69   [gl_gcc_warnings=yes]
   70 )
   71 if test "$gl_gcc_warnings" = yes; then
   72   dnl Set up the list of undesired warnings.
   73   nw=
   74   nw="$nw -Wsystem-headers"   # Don’t let system headers trigger warnings
   75   nw="$nw -Wundef"            # All compiler preprocessors support #if UNDEF
   76   nw="$nw -Wtraditional"      # All compilers nowadays support ANSI C
   77   nw="$nw -Wdeclaration-after-statement" # We require C99.
   78   nw="$nw -Wstrict-overflow"  # Use a lower level (see below).
   79   nw="$nw -Wconversion"       # These warnings usually don’t point to mistakes.
   80   nw="$nw -Wsign-conversion"  # Likewise.
   81 
   82   gl_MANYWARN_ALL_GCC([warnings])
   83 
   84   dnl Enable all GCC warnings not in this list.
   85   gl_MANYWARN_COMPLEMENT([warnings], [$warnings], [$nw])
   86   for w in $warnings; do
   87     gl_WARN_ADD([$w])
   88   done
   89 
   90   dnl Add an extra warning
   91   gl_WARN_ADD([-Wstrict-overflow=1])
   92   dnl Remove a warning being promoted to error: we trigger this and can't turn it off with pragmas.
   93   gl_WARN_ADD([-Wno-error=format-security])
   94 
   95   # When compiling with GCC, prefer -isystem to -I when including system
   96   # include files, to avoid generating useless diagnostics for the files.
   97   ISYSTEM='-isystem '
   98 else
   99   ISYSTEM='-I'
  100 fi
  101 AC_SUBST([ISYSTEM])
  102 
  103 # Extra settings for running tests, e.g. LD_PRELOAD for ASAN
  104 AC_SUBST([TESTS_ENVIRONMENT_EXTRA])
  105 
  106 AC_CONFIG_HEADERS([config.h])
  107 AC_HEADER_STDC
  108 AM_ICONV
  109 LIBS="$LIBICONV $LIBS"
  110 
  111 AM_GNU_GETTEXT_VERSION(0.19)
  112 AM_GNU_GETTEXT(external)
  113 AM_XGETTEXT_OPTION([--from-code=UTF-8])
  114 
  115 AC_OUTPUT(Makefile contrib/Makefile doc/Makefile lib/Makefile
  116           po/Makefile.in src/Makefile tests/Makefile tests/setup.py)