1 | dnl Process this file with autoconf to produce a configure script. |
---|
2 | dnl |
---|
3 | dnl $Id$ |
---|
4 | |
---|
5 | AC_PREREQ(2.13) |
---|
6 | AC_INIT(libbsp) |
---|
7 | RTEMS_TOP(../../..) |
---|
8 | AC_CONFIG_AUX_DIR(../../..) |
---|
9 | |
---|
10 | AC_PROG_MAKE_SET |
---|
11 | RTEMS_CANONICAL_TARGET_CPU |
---|
12 | |
---|
13 | AM_MAINTAINER_MODE |
---|
14 | |
---|
15 | RTEMS_ENABLE_MULTIPROCESSING |
---|
16 | RTEMS_ENABLE_NETWORKING |
---|
17 | RTEMS_ENABLE_RDBG |
---|
18 | RTEMS_ENABLE_CXX |
---|
19 | RTEMS_ENABLE_GCC28 |
---|
20 | RTEMS_ENABLE_LIBCDIR |
---|
21 | RTEMS_ENABLE_BARE |
---|
22 | RTEMS_ENABLE_HWAPI |
---|
23 | |
---|
24 | RTEMS_ENV_RTEMSBSP |
---|
25 | |
---|
26 | AC_PROG_INSTALL |
---|
27 | |
---|
28 | RTEMS_CHECK_CPU |
---|
29 | RTEMS_CANONICAL_HOST |
---|
30 | |
---|
31 | RTEMS_PROJECT_ROOT |
---|
32 | |
---|
33 | dnl check target cc |
---|
34 | RTEMS_PROG_CC_FOR_TARGET |
---|
35 | RTEMS_CANONICALIZE_TOOLS |
---|
36 | |
---|
37 | dnl if this is an i386, does gas have good code16 support? |
---|
38 | RTEMS_I386_GAS_CODE16 |
---|
39 | AM_CONDITIONAL(RTEMS_GAS_CODE16,test "$RTEMS_GAS_CODE16" = "yes"); |
---|
40 | |
---|
41 | RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP) |
---|
42 | RTEMS_CHECK_MULTIPROCESSING(RTEMS_BSP) |
---|
43 | RTEMS_CHECK_NETWORKING(RTEMS_BSP) |
---|
44 | |
---|
45 | RTEMS_BSP_ALIAS(${RTEMS_BSP},bspdir) |
---|
46 | |
---|
47 | AM_CONDITIONAL(UNIX,test "$RTEMS_CPU" = "unix") |
---|
48 | |
---|
49 | # find all the CPU dependent library Makefiles |
---|
50 | AC_CONFIG_SUBDIRS(libcpu) |
---|
51 | AC_CONFIG_SUBDIRS(libbsp) |
---|
52 | |
---|
53 | # If the TCP/IP stack is enabled, then find all TCP/IP Makefiles |
---|
54 | if test "$HAS_NETWORKING" = "yes"; then |
---|
55 | cfg_subdirs="$cfg_subdirs libnetworking" |
---|
56 | cfg_subdirs="$cfg_subdirs librpc" |
---|
57 | |
---|
58 | if test "$RTEMS_HAS_RDBG" = "yes"; then |
---|
59 | RTEMS_CHECK_RDBG(RTEMS_BSP) |
---|
60 | fi |
---|
61 | fi |
---|
62 | |
---|
63 | |
---|
64 | if test "$HAS_RDBG" = "yes"; then |
---|
65 | cfg_subdirs="$cfg_subdirs librdbg" |
---|
66 | fi |
---|
67 | |
---|
68 | # If the HWAPI is enabled, the find the HWAPI Makefiles |
---|
69 | RTEMS_ENABLE_HWAPI |
---|
70 | if test "$RTEMS_HAS_HWAPI" = "yes"; then |
---|
71 | if test -d "${srcdir}/libhwapi"; then |
---|
72 | cfg_subdirs="$cfg_subdirs libhwapi" |
---|
73 | fi |
---|
74 | LIBHWAPI="libhwapi" |
---|
75 | fi |
---|
76 | AC_SUBST(LIBHWAPI) |
---|
77 | |
---|
78 | if test -d "${srcdir}/start/$RTEMS_CPU"; then |
---|
79 | cfg_subdirs="$cfg_subdirs start/$RTEMS_CPU" |
---|
80 | RTEMS_CPU_STARTdir="$RTEMS_CPU" |
---|
81 | fi |
---|
82 | AC_SUBST(RTEMS_CPU_STARTdir) |
---|
83 | |
---|
84 | if test "$RTEMS_CPU" != "unix"; then |
---|
85 | ## HACK: Suppress libchip for unix |
---|
86 | cfg_subdirs="$cfg_subdirs libchip" |
---|
87 | fi |
---|
88 | |
---|
89 | AM_CONDITIONAL(HAS_NETWORKING,test "$HAS_NETWORKING" = "yes") |
---|
90 | AM_CONDITIONAL(HAS_LIBCHIP,test "$RTEMS_CPU" != "unix") |
---|
91 | AM_CONDITIONAL(HAS_RDBG,test "$HAS_RDBG" = "yes") |
---|
92 | |
---|
93 | AC_CONFIG_SUBDIRS(libmisc) |
---|
94 | |
---|
95 | AC_CONFIG_SUBDIRS($cfg_subdirs) |
---|
96 | |
---|
97 | PROJECT_INCLUDE="\$(PROJECT_ROOT)/$RTEMS_BSP/lib/include" |
---|
98 | AC_SUBST(PROJECT_INCLUDE) |
---|
99 | |
---|
100 | # try to explicitly list a Makefile here |
---|
101 | AC_OUTPUT( |
---|
102 | Makefile |
---|
103 | include/Makefile |
---|
104 | include/sys/Makefile |
---|
105 | include/motorola/Makefile |
---|
106 | include/zilog/Makefile |
---|
107 | include/rpc/Makefile |
---|
108 | include/rdbg/Makefile |
---|
109 | include/rdbg/i386/Makefile |
---|
110 | include/rdbg/powerpc/Makefile |
---|
111 | libc/Makefile |
---|
112 | start/Makefile |
---|
113 | wrapup/Makefile) |
---|