Linux compatibility
This commit is contained in:
38
configure.ac
38
configure.ac
@@ -1,14 +1,42 @@
|
|||||||
|
# -*- Autoconf -*-
|
||||||
|
# Process this file with autoconf to produce a configure script.
|
||||||
|
|
||||||
|
AC_PREREQ([2.69])
|
||||||
AC_INIT([sermon], [0.9], [david.a.baer@gmail.com])
|
AC_INIT([sermon], [0.9], [david.a.baer@gmail.com])
|
||||||
AM_INIT_AUTOMAKE([-Wall -Werror foreign])
|
AM_INIT_AUTOMAKE([-Wall -Werror foreign])
|
||||||
|
AC_CONFIG_SRCDIR([config.h.in])
|
||||||
|
AC_CONFIG_HEADERS([config.h])
|
||||||
|
|
||||||
|
# Checks for programs.
|
||||||
AC_PROG_CC
|
AC_PROG_CC
|
||||||
AC_PROG_LEX
|
AC_PROG_LEX
|
||||||
AC_PROG_YACC
|
AC_PROG_YACC
|
||||||
|
|
||||||
|
# Checks for libraries.
|
||||||
PKG_CHECK_MODULES([libxml2], [libxml-2.0])
|
PKG_CHECK_MODULES([libxml2], [libxml-2.0])
|
||||||
PKG_CHECK_MODULES([libxslt], [libxslt])
|
PKG_CHECK_MODULES([libxslt], [libxslt])
|
||||||
AC_CONFIG_HEADERS([config.h])
|
AC_CHECK_LIB([bsd], [strlcpy], [ PKG_CHECK_MODULES([libbsd], [libbsd]) ])
|
||||||
AC_CONFIG_FILES([
|
|
||||||
Makefile
|
# Checks for header files.
|
||||||
src/Makefile
|
AC_FUNC_ALLOCA
|
||||||
|
AC_CHECK_HEADERS([inttypes.h libintl.h limits.h malloc.h stddef.h stdint.h stdlib.h string.h unistd.h])
|
||||||
|
|
||||||
|
# Checks for typedefs, structures, and compiler characteristics.
|
||||||
|
AC_C_INLINE
|
||||||
|
AC_TYPE_INT16_T
|
||||||
|
AC_TYPE_INT32_T
|
||||||
|
AC_TYPE_INT8_T
|
||||||
|
AC_TYPE_SIZE_T
|
||||||
|
AC_TYPE_UINT16_T
|
||||||
|
AC_TYPE_UINT32_T
|
||||||
|
AC_TYPE_UINT8_T
|
||||||
|
|
||||||
|
# Checks for library functions.
|
||||||
|
AC_FUNC_MALLOC
|
||||||
|
AC_FUNC_REALLOC
|
||||||
|
AC_CHECK_FUNCS([memset realpath strdup strndup])
|
||||||
|
|
||||||
|
AC_CONFIG_FILES([Makefile
|
||||||
data/Makefile
|
data/Makefile
|
||||||
])
|
src/Makefile])
|
||||||
AC_OUTPUT
|
AC_OUTPUT
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ sermon_SOURCES = citations.c \
|
|||||||
utf8.c \
|
utf8.c \
|
||||||
xml.c \
|
xml.c \
|
||||||
xslt.c
|
xslt.c
|
||||||
sermon_LDADD = ${libxml2_LIBS} ${libxslt_LIBS}
|
sermon_LDADD = ${libxml2_LIBS} ${libxslt_LIBS} ${libbsd_LIBS}
|
||||||
CLEANFILES = sermon_lexer.c \
|
CLEANFILES = sermon_lexer.c \
|
||||||
sermon_parser.c \
|
sermon_parser.c \
|
||||||
sermon_parser.h
|
sermon_parser.h
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
%{
|
%{
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
#include "sermon.h"
|
||||||
#include "sermon_parser.h"
|
#include "sermon_parser.h"
|
||||||
|
|
||||||
#ifdef LEXDEBUG
|
#ifdef LEXDEBUG
|
||||||
|
|||||||
Reference in New Issue
Block a user