From c951ea013db433b711dc3fe9bd8b2c63050c79ff Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 21 Oct 2013 12:44:08 +0100 Subject: [PATCH] Autotools setup. --- .gitignore | 23 +++++++++++++++++++++++ Makefile.am | 3 +++ configure.ac | 6 ++++++ m4/.gitignore | 5 +++++ 4 files changed, 37 insertions(+) create mode 100644 m4/.gitignore diff --git a/.gitignore b/.gitignore index b25c15b..483e91c 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,24 @@ *~ +*.o + +.deps +Makefile +Makefile.in + +/aclocal.m4 +/autom4te.cache +/compile +/config.guess +/config.h +/config.h.in +/config.log +/config.status +/config.sub +/configure +/depcomp +/install-sh +/libtool +/ltmain.sh +/missing +/pxzcat +/stamp-h1 diff --git a/Makefile.am b/Makefile.am index 7f89a10..324e946 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,3 +1,6 @@ +ACLOCAL_AMFLAGS = -I m4 + bin_PROGRAMS = pxzcat pxzcat_SOURCES = pxzcat.c +pxzcat_LDADD = $(LIBLZMA_LIBS) diff --git a/configure.ac b/configure.ac index 1d0260a..7bdce4d 100644 --- a/configure.ac +++ b/configure.ac @@ -1,5 +1,9 @@ AC_INIT([pxzcat],0.0.1) +AM_INIT_AUTOMAKE(foreign) + +AC_CONFIG_MACRO_DIR([m4]) + AC_PROG_LIBTOOL dnl Check for basic C environment. @@ -12,6 +16,8 @@ test "x$U" != "x" && AC_MSG_ERROR([Compiler not ANSI compliant]) AM_PROG_CC_C_O +PKG_CHECK_MODULES([LIBLZMA], [liblzma]) + AC_CONFIG_HEADERS([config.h]) AC_CONFIG_FILES([Makefile]) AC_OUTPUT diff --git a/m4/.gitignore b/m4/.gitignore new file mode 100644 index 0000000..94e6f26 --- /dev/null +++ b/m4/.gitignore @@ -0,0 +1,5 @@ +/libtool.m4 +/ltoptions.m4 +/ltsugar.m4 +/ltversion.m4 +/lt~obsolete.m4 -- 1.8.3.1