Commit 34e5a4b6 authored by Swann Perarnau's avatar Swann Perarnau

[feature] add autotools

Standard autoconf/automake/libtool boilerplate.
parent 43d42731
ACLOCAL_AMFLAGS = -I m4
SUBDIRS = src tests
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libexcit.pc
EXTRA_DIST = autogen.sh libexcit.pc README.md
#!/bin/sh
set -x
autoreconf -vif -I m4
# see semver.org for version info
AC_INIT([excit],[0.0.1],[brice.videau@imag.fr])
# are we in the right source dir ?
AC_CONFIG_SRCDIR([src/citerators.h])
# build artefacts in separate dir
AC_CONFIG_AUX_DIR([m4])
AC_CONFIG_MACRO_DIR([m4])
# automake should fail on any error
AM_INIT_AUTOMAKE([-Wall -Werror foreign 1.12])
AM_PROG_AR
# check for libtool
LT_INIT
# check for programs
AC_LANG([C])
AC_PROG_CC
AC_PROG_CC_STDC
AC_TYPE_SIZE_T
AC_HEADER_ASSERT
AC_CONFIG_HEADERS([src/config.h])
AC_CONFIG_FILES([Makefile
src/Makefile
tests/Makefile
libexcit.pc])
AC_OUTPUT
prefix=@prefix@
exec_prefix=@prefix@
libdir=@libdir@
includedir=@includedir@
Name: libexcit
Description: Extensive C Iterators
Version: 0.0.1
Libs: -L${libdir} -lexcit
Cflags: -I${includedir}
lib_LTLIBRARIES = libexcit.la
libexcit_la_SOURCES = citerators.c citerators.h
include_HEADERS = citerators.h
AM_COLOR_TESTS = yes
AM_CFLAGS = -I$(top_srcdir)/src
AM_LDFLAGS = ../src/libexcit.la
UNIT_TESTS = citerators
# all tests
check_PROGRAMS = $(UNIT_TESTS)
TESTS = $(UNIT_TESTS)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment