1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
AC_PREREQ([2.60])
AC_INIT([hal-backend-tdm-vc4],
[0.1.0],
[https://www.tizen.org],
[hal-backend-tdm-vc4])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_SRCDIR([Makefile.am])
AM_INIT_AUTOMAKE([1.10 foreign dist-bzip2])
AM_MAINTAINER_MODE([enable])
# Check for programs
AC_PROG_CC
AC_USE_SYSTEM_EXTENSIONS
AC_SYS_LARGEFILE
AC_FUNC_ALLOCA
# Initialize libtool
LT_PREREQ([2.2])
LT_INIT([disable-static])
# Enable quiet compiles on automake 1.11.
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
PKG_CHECK_MODULES(LIBHAL_BACKEND_TDM_VC4, hal-api-common hal-api-tdm hal-api-tbm libdrm dlog pixman-1 libtbm)
PKG_CHECK_MODULES(UDEV, libudev, [udev=yes], [udev=no])
if test x"$udev" = xyes; then
AC_DEFINE(HAVE_UDEV,1,[Enable udev-based monitor hotplug detection])
LIBHAL_BACKEND_TDM_VC4_CFLAGS="$LIBHAL_BACKEND_TDM_VC4_CFLAGS $UDEV_CFLAGS"
LIBHAL_BACKEND_TDM_VC4_LIBS="$LIBHAL_BACKEND_TDM_VC4_LIBS $UDEV_LIBS"
fi
AC_SUBST(LIBHAL_BACKEND_TDM_VC4_CFLAGS)
AC_SUBST(LIBHAL_BACKEND_TDM_VC4_LIBS)
AC_DEFINE_UNQUOTED(LIBDRM_MAJOR_VERSION, [`pkg-config --modversion libdrm | cut -d '.' -f 1`], dnl
[libdrm major version])
AC_DEFINE_UNQUOTED(LIBDRM_MINOR_VERSION, [`pkg-config --modversion libdrm | cut -d '.' -f 2`], dnl
[libdrm major version])
AC_DEFINE_UNQUOTED(LIBDRM_MICRO_VERSION, [`pkg-config --modversion libdrm | cut -d '.' -f 3`], dnl
[libdrm major version])
# set the library dir for the tdm hal backend
DEFAULT_HAL_LIBDIR="/hal/lib"
AC_ARG_WITH(hal-libdir, AS_HELP_STRING([--with-hal-libdir=PATH], [hal backend library path]),
[ HAL_LIBDIR="$withval" ],
[ HAL_LIBDIR="${DEFAULT_HAL_LIBDIR}" ])
AC_DEFINE_UNQUOTED(HAL_LIBDIR, "${HAL_LIBDIR}", [Directory for hal backend library path])
AC_SUBST(HAL_LIBDIR)
# For enumerating devices in test case
AC_OUTPUT([
Makefile
src/Makefile])
echo ""
echo "$PACKAGE_STRING will be compiled with:"
echo ""
echo "LIBHAL_BACKEND_TDM_VC4_CFLAGS : $LIBHAL_BACKEND_TDM_VC4_CFLAGS"
echo "LIBHAL_BACKEND_TDM_VC4_LIBS : $LIBHAL_BACKEND_TDM_VC4_LIBS"
echo "HAL_LIBDIR : $HAL_LIBDIR"
echo ""
|