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 |
2 | 2 | dnl Configure.in file for the Midnight Commander |
3 | 3 | dnl |
4 | 4 | |
5 | | AC_PREREQ(2.60) |
6 | | AC_INIT([GNU Midnight Commander], [], [mc-devel@gnome.org]) |
| 5 | AC_PREREQ(2.64) |
| 6 | AC_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/]) |
7 | 7 | m4_pattern_forbid(MC_) |
8 | 8 | AC_CONFIG_MACRO_DIR([m4]) |
9 | 9 | AC_CONFIG_AUX_DIR(config) |
10 | 10 | AC_CONFIG_SRCDIR(src/main.c) |
11 | 11 | AC_CONFIG_HEADERS(config.h) |
12 | 12 | mc_VERSION |
13 | | AM_INIT_AUTOMAKE(mc, ${VERSION} ) |
| 13 | AM_INIT_AUTOMAKE |
14 | 14 | dnl Enable silent rules by default (if yes) |
15 | 15 | m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) |
16 | 16 | |