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