From: Daniel Elstner Date: Sat, 5 Sep 2015 22:04:27 +0000 (+0200) Subject: Build: Modernize Autotools configuration X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=0e885faee37cd4ec880ab9572f0ed72d085d33db;p=sigrok-firmware.git Build: Modernize Autotools configuration --- diff --git a/Makefile.am b/Makefile.am index 2823628..0d89444 100644 --- a/Makefile.am +++ b/Makefile.am @@ -19,7 +19,7 @@ ## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA ## -ACLOCAL_AMFLAGS = -I autostuff +GNUMAKEFLAGS = --no-print-directory SUBDIRS = asix-sigma sysclk-lwla diff --git a/autogen.sh b/autogen.sh index 70d4c18..a9b5843 100755 --- a/autogen.sh +++ b/autogen.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh -e ## ## This file is part of the sigrok-firmware project. ## @@ -20,28 +20,7 @@ ## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA ## -OS=`uname` - -if [ "x$OS" = "xDarwin" ]; then - if [ -d /sw/share/aclocal ]; then - # fink installs aclocal macros here - ACLOCAL_DIR="-I /sw/share/aclocal" - elif [ -d /opt/local/share/aclocal ]; then - # Macports installs aclocal macros here - ACLOCAL_DIR="-I /opt/local/share/aclocal" - elif [ -d /usr/local/share/aclocal ]; then - # Homebrew installs aclocal macros here - ACLOCAL_DIR="-I /usr/local/share/aclocal" - elif [ -d /usr/share/aclocal ]; then - # Xcode installs aclocal macros here - ACLOCAL_DIR="-I /usr/share/aclocal" - fi -fi - -echo "Generating build system..." -mkdir -p autostuff -aclocal ${ACLOCAL_DIR} || exit 1 -autoheader || exit 1 -automake --add-missing --copy || exit 1 -autoconf || exit 1 +test -n "$srcdir" || srcdir=`dirname "$0"` +test -n "$srcdir" || srcdir=. +autoreconf --force --install --verbose "$srcdir" diff --git a/configure.ac b/configure.ac index ca963ef..9ba54a9 100644 --- a/configure.ac +++ b/configure.ac @@ -23,24 +23,16 @@ AC_PREREQ([2.63]) AC_INIT([sigrok-firmware], [0.1.0], [sigrok-devel@lists.sourceforge.net], [sigrok-firmware], [http://www.sigrok.org]) -AC_CONFIG_HEADER([config.h]) -AC_CONFIG_MACRO_DIR([autostuff]) AC_CONFIG_AUX_DIR([autostuff]) # We require at least automake 1.11 (needed for 'silent rules'). -AM_INIT_AUTOMAKE([1.11 -Wall -Werror check-news]) -m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) +AM_INIT_AUTOMAKE([1.11 -Wall -Werror no-define nostdinc check-news]) +AM_SILENT_RULES([yes]) AC_PROG_INSTALL -AC_PROG_LN_S - -AC_SUBST(FIRMWARE_DIR, "$datadir/sigrok-firmware") -AC_SUBST(MAKEFLAGS, '--no-print-directory') AC_CONFIG_FILES([Makefile asix-sigma/Makefile sysclk-lwla/Makefile ]) - AC_OUTPUT -