From 4509790f1015ac00f274e9e76410ee28adb0b6cd Mon Sep 17 00:00:00 2001 From: Romain B Date: Thu, 18 May 2017 23:00:37 +0200 Subject: [PATCH] Fix some autotools warnings - Create m4 directory in autogen and declare it - Fix AC_COMPILE_IFELSE and datarootdir warnings since autoconf 2.68 --- Makefile.am | 1 + autogen.sh | 2 ++ configure.ac.in | 5 +++-- libxfce4panel/libxfce4panel-1.0.pc.in | 1 + libxfce4panel/libxfce4panel-2.0.pc.in | 1 + 5 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Makefile.am b/Makefile.am index 0ad07802..e4e67957 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,3 +1,4 @@ +ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS} SUBDIRS = \ libxfce4panel \ diff --git a/autogen.sh b/autogen.sh index 6eae7154..d8e44a7d 100755 --- a/autogen.sh +++ b/autogen.sh @@ -29,5 +29,7 @@ EOF exit 1 } +test -d m4 || mkdir m4 + XDT_AUTOGEN_REQUIRED_VERSION="4.7.3" \ exec xdt-autogen $@ diff --git a/configure.ac.in b/configure.ac.in index 83df6e1a..18c0df79 100644 --- a/configure.ac.in +++ b/configure.ac.in @@ -42,6 +42,7 @@ dnl *************************** AC_CONFIG_HEADERS([config.h]) AM_INIT_AUTOMAKE([1.8 no-dist-gzip dist-bzip2 tar-ustar]) AM_MAINTAINER_MODE() +AC_CONFIG_MACRO_DIR([m4]) m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) dnl ****************************** @@ -180,7 +181,7 @@ if test x"$enable_visibility" != x"no"; then save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -Wall -Werror" AC_MSG_CHECKING([whether $CC supports the GNUC visibility attribute]) - AC_COMPILE_IFELSE(AC_LANG_SOURCE( + AC_COMPILE_IFELSE([AC_LANG_SOURCE( [ void test_default (void); void test_hidden (void); @@ -189,7 +190,7 @@ if test x"$enable_visibility" != x"no"; then void __attribute__ ((visibility("hidden"))) test_hidden (void) {} int main (int argc, char **argv) { test_default (); test_hidden (); return 0; } - ]), + ])], [ have_gnuc_visibility=yes AC_MSG_RESULT([yes]) diff --git a/libxfce4panel/libxfce4panel-1.0.pc.in b/libxfce4panel/libxfce4panel-1.0.pc.in index 90423b65..c0cdc884 100644 --- a/libxfce4panel/libxfce4panel-1.0.pc.in +++ b/libxfce4panel/libxfce4panel-1.0.pc.in @@ -3,6 +3,7 @@ exec_prefix=@exec_prefix@ libdir=@libdir@ includedir=@includedir@ localedir=@localedir@ +datarootdir=@datarootdir@ api=1.0 Name: libxfce4panel diff --git a/libxfce4panel/libxfce4panel-2.0.pc.in b/libxfce4panel/libxfce4panel-2.0.pc.in index 4f18f0f4..6644f7b8 100644 --- a/libxfce4panel/libxfce4panel-2.0.pc.in +++ b/libxfce4panel/libxfce4panel-2.0.pc.in @@ -3,6 +3,7 @@ exec_prefix=@exec_prefix@ libdir=@libdir@ includedir=@includedir@ localedir=@localedir@ +datarootdir=@datarootdir@ api=@LIBXFCE4PANEL_VERSION_API@ Name: libxfce4panel -- 2.13.0