main: compile-fix for linux 4.18+
[libdreamdvd.git] / configure.ac
1 #                                               -*- Autoconf -*-
2 # Process this file with autoconf to produce a configure script.
3
4 AC_INIT([libdreamdvd],[0.0.1],[enigma2-devel@lists.elitedvb.net])
5 AM_INIT_AUTOMAKE([dist-bzip2 foreign])
6 AC_CONFIG_SRCDIR([main.c])
7 AC_CONFIG_HEADERS([libdreamdvd_config.h])
8
9 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
10
11 AC_USE_SYSTEM_EXTENSIONS
12 AC_SYS_LARGEFILE
13
14 # Checks for programs.
15 AC_PROG_CC
16 m4_ifdef([LT_INIT], [LT_INIT], [AC_PROG_LIBTOOL])
17
18 # Checks for libraries.
19 PKG_CHECK_MODULES(DVDNAV, dvdnav)
20 AC_CHECK_LIB([dl], [dlopen], [LIBDL_LIBS="-ldl"], [AC_MSG_ERROR([Could not find libdl])])
21 AC_SUBST(LIBDL_LIBS)
22 AC_CHECK_LIB([m], [pow], [LIBM_LIBS="-lm"], [AC_MSG_ERROR([Could not find libm])])
23 AC_SUBST(LIBM_LIBS)
24
25 # Checks for header files.
26 AC_CHECK_HEADERS([byteswap.h ost/dmx.h linux/dvb/version.h])
27
28 AC_CONFIG_FILES([
29 Makefile
30 libdreamdvd.pc
31 ])
32 AC_OUTPUT