summaryrefslogtreecommitdiffstats
path: root/aclocal/env-rtemscpu.m4
blob: 796f875db4e2c732dd42b9e6399ad08756179c89 (plain)
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
dnl $Id$

AC_DEFUN(RTEMS_ENV_RTEMSCPU,
[AC_REQUIRE([RTEMS_ENABLE_MULTILIB])

if test x"$multilib" = x"yes"; then
## FIXME: There is no multilib BSP
  RTEMS_BSP_SPECS=""
  AC_SUBST(RTEMS_BSP_SPECS)

  if test -n "$with_multisubdir"; then
    MULTIBUILDTOP=`echo "/$with_multisubdir" | sed 's,/[[^\\/]]*,../,g'`
  fi
  AC_SUBST(MULTIBUILDTOP)

  if test -n "$with_multisubdir"; then
    MULTISUBDIR="/$with_multisubdir"
  fi
  AC_SUBST(MULTISUBDIR)

  PROJECT_ROOT="${RTEMS_TOPdir}/\$(MULTIBUILDTOP)\$(top_builddir)"
  GCC_SPECS="-isystem \$(PROJECT_ROOT)/lib/include"
  AC_SUBST(GCC_SPECS)

  PROJECT_INCLUDE="\$(PROJECT_ROOT)/lib/include"
  AC_SUBST(PROJECT_INCLUDE)

  PROJECT_RELEASE="\$(PROJECT_ROOT)"
  AC_SUBST(PROJECT_RELEASE)

  RTEMS_ROOT=${PROJECT_ROOT}
  AC_SUBST(RTEMS_ROOT)

  includedir="\${exec_prefix}/lib/include"
  libdir="${libdir}\$(MULTISUBDIR)"
else
  RTEMS_ENV_RTEMSBSP
  RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP)
fi
])