Ticket #3603: mc-3603-0001-configure.ac-proper-AC_INIT-and-AM_INIT_AUTOMAKE-usage.patch

File mc-3603-0001-configure.ac-proper-AC_INIT-and-AM_INIT_AUTOMAKE-usage.patch, 2.0 KB (added by and, 9 years ago)
  • configure.ac

    From 9113503862aabc2ff3fbb55eab070570f1283c19 Mon Sep 17 00:00:00 2001
    From: Andreas Mohr <and@gmx.li>
    Date: Sat, 2 Apr 2016 10:42:35 +0000
    Subject: [PATCH] configure.ac: proper AC_INIT and AM_INIT_AUTOMAKE usage
    
    fix AM_INIT_AUTOMAKE deprecate warning
    define AC_INIT version string (version.h > git version > unknown)
    define AC_INIT tarname and url (since autoconf 2.64)
    
    configure.ac:13: warning: AM_INIT_AUTOMAKE: two- and three-arguments forms are deprecated.  For more info, see:
    configure.ac:13: http://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_005fINIT_005fAUTOMAKE-invocation
    
    example before:
    #define PACKAGE "mc"
    #define PACKAGE_BUGREPORT ""
    #define PACKAGE_NAME ""
    #define PACKAGE_STRING ""
    #define PACKAGE_TARNAME ""
    #define PACKAGE_URL ""
    #define PACKAGE_VERSION ""
    example after:
    #define PACKAGE "mc"
    #define PACKAGE_BUGREPORT "mc-devel@gnome.org"
    #define PACKAGE_NAME "GNU Midnight Commander"
    #define PACKAGE_STRING "GNU Midnight Commander 4.8.16-15-g50cca69"
    #define PACKAGE_TARNAME "mc"
    #define PACKAGE_URL "https://www.midnight-commander.org/"
    #define PACKAGE_VERSION "4.8.16-15-g50cca69"
    
    Signed-off-by: Andreas Mohr <and@gmx.li>
    ---
    diff --git a/configure.ac b/configure.ac
    index d0d8358..09ea0be 100644
    a b dnl 
    22dnl Configure.in file for the Midnight Commander 
    33dnl 
    44 
    5 AC_PREREQ(2.60) 
    6 AC_INIT([GNU Midnight Commander], [], [mc-devel@gnome.org]) 
     5AC_PREREQ(2.64) 
     6AC_INIT([GNU Midnight Commander], m4_esyscmd_s([sed -n 's/^#define MC_CURRENT_VERSION.*"\(.*\)"$/\1/p' version.h 2>/dev/null || git describe 2>/dev/null || echo unknown]), [mc-devel@gnome.org], [mc], [https://www.midnight-commander.org/]) 
    77m4_pattern_forbid(MC_) 
    88AC_CONFIG_MACRO_DIR([m4]) 
    99AC_CONFIG_AUX_DIR(config) 
    1010AC_CONFIG_SRCDIR(src/main.c) 
    1111AC_CONFIG_HEADERS(config.h) 
    1212mc_VERSION 
    13 AM_INIT_AUTOMAKE(mc, ${VERSION} ) 
     13AM_INIT_AUTOMAKE 
    1414dnl Enable silent rules by default (if yes) 
    1515m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) 
    1616