-
Notifications
You must be signed in to change notification settings - Fork 39
/
configure.ac
64 lines (53 loc) · 1.51 KB
/
configure.ac
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
AC_INIT([pdbg],[3.6])
AM_INIT_AUTOMAKE([subdir-objects])
AM_SILENT_RULES([yes])
AC_SUBST(SONAME_CURRENT, 6)
AC_SUBST(SONAME_REVISION, 0)
AC_SUBST(SONAME_AGE, 0)
AC_PROG_CC
AC_PROG_CXX
AM_PROG_AS
LT_INIT
AC_PATH_PROG([M4], [m4])
if test x"$ac_cv_path_M4" = "x" ; then
AC_MSG_ERROR([Command 'm4' not found.])
fi
AC_SUBST([M4])
AC_PATH_PROG([DTC], [dtc])
if test x"$ac_cv_path_DTC" = x ; then
AC_MSG_ERROR([Command 'dtc' not found.])
fi
AC_SUBST([DTC])
AC_PATH_PROG([RAGEL], [ragel])
AC_SUBST([RAGEL])
AM_CONDITIONAL([HAVE_RAGEL], [test x"$ac_cv_path_RAGEL" != "x"])
AC_CHECK_LIB([fdt], [fdt_check_header])
AM_CONDITIONAL([BUILD_LIBFDT], [test x"$ac_cv_lib_fdt_fdt_check_header" != "xyes"])
if test x"$ac_cv_lib_fdt_fdt_check_header" != "xyes" ; then
AC_CONFIG_SUBDIRS([libfdt])
else
AC_SUBST([LIBFDT], ["-lfdt"])
fi
AC_CHECK_HEADER([linux/fsi.h],
[AC_DEFINE([HAVE_LINUX_FSI_H], 1,
[Define to 1 if you have the <linux/fsi> header file])],
[])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_FILES([Makefile])
AC_CONFIG_FILES([libpdbg/pdbg.pc])
AC_LANG(C)
case "$host" in
arm*-*-*) ARCH="arm" ;;
powerpc*-*-*) ARCH="ppc" ;;
*) ARCH="def" ;;
esac
AC_SUBST([ARCH])
AM_CONDITIONAL([TARGET_ARM], [test x"$ARCH" = "xarm"])
AM_CONDITIONAL([TARGET_PPC], [test x"$ARCH" = "xppc"])
AC_ARG_ENABLE(gdbserver,
AS_HELP_STRING([--disable-gdbserver], [disables building the gdbserver]),
want_gdbserver=false,
want_gdbserver=true)
AM_CONDITIONAL([GDBSERVER], [test x$want_gdbserver = xtrue])
AC_OUTPUT