Line 79... |
Line 79... |
|
|
case "$host_os" in
|
case "$host_os" in
|
solaris*) LIBS="-lsocket -lnsl" ;;
|
solaris*) LIBS="-lsocket -lnsl" ;;
|
esac
|
esac
|
|
|
|
dnl define options
|
|
|
AC_MSG_CHECKING(whether to enable profiling)
|
AC_MSG_CHECKING(whether to enable profiling)
|
AC_ARG_ENABLE(profiling,
|
AC_ARG_ENABLE(profiling,
|
[ --enable-profiling generate profiling code], [
|
[ --enable-profiling generate profiling code], [
|
case "$enableval" in
|
case "$enableval" in
|
yes) profile="-pg" ;;
|
yes) profile="-pg" ;;
|
Line 97... |
Line 99... |
no) debugmod="-DDEBUGMOD_OFF" ;;
|
no) debugmod="-DDEBUGMOD_OFF" ;;
|
esac
|
esac
|
])
|
])
|
AC_MSG_RESULT(${disable_debugmod-no})
|
AC_MSG_RESULT(${disable_debugmod-no})
|
|
|
|
AC_SUBST(FPM)
|
|
AC_MSG_CHECKING(for implementation-specific data)
|
|
AC_ARG_ENABLE(impl,
|
|
[ --enable-impl= use -specific environment
|
|
(one of: bender, mp3, default)], [
|
|
case "$enableval" in
|
|
no|default) IMPL="DEFAULT" ;;
|
|
mp3) IMPL="MP3" ;;
|
|
bender) IMPL="BENDER" ;;
|
|
*)
|
|
AC_MSG_RESULT(failed)
|
|
AC_MSG_ERROR([bad --enable-impl option])
|
|
;;
|
|
esac
|
|
])
|
|
AC_MSG_RESULT(${IMPL=DEFAULT})
|
|
if test "$IMPL" = "DEFAULT"
|
|
then
|
|
AC_MSG_WARN([using default environment])
|
|
fi
|
|
IMPL="-DIMPL_$IMPL"
|
|
|
BUILD_DIR=`pwd`
|
BUILD_DIR=`pwd`
|
AC_SUBST(BUILD_DIR)
|
AC_SUBST(BUILD_DIR)
|
|
|
AC_SUBST(CFLAGS)
|
AC_SUBST(CFLAGS)
|
AC_SUBST(LOCAL_CFLAGS)
|
AC_SUBST(LOCAL_CFLAGS)
|
Line 124... |
Line 148... |
-I\${top_srcdir}/cpu/$CPU_ARCH -I\${top_srcdir}/cache -I\${top_srcdir}/mmu \
|
-I\${top_srcdir}/cpu/$CPU_ARCH -I\${top_srcdir}/cache -I\${top_srcdir}/mmu \
|
-I\${top_srcdir}/bpb -I\${top_srcdir}/peripheral -I\${top_srcdir}/tick \
|
-I\${top_srcdir}/bpb -I\${top_srcdir}/peripheral -I\${top_srcdir}/tick \
|
-I\${top_srcdir}/pm -I\${top_srcdir}/pic"
|
-I\${top_srcdir}/pm -I\${top_srcdir}/pic"
|
AC_SUBST(INCLUDES)
|
AC_SUBST(INCLUDES)
|
|
|
echo $(debugmod)
|
|
test -n "$profile" && CFLAGS="$CFLAGS $profile" LDFLAGS="$LDFLAGS $profile"
|
test -n "$profile" && CFLAGS="$CFLAGS $profile" LDFLAGS="$LDFLAGS $profile"
|
test -n "$debugmod" && CFLAGS="$CFLAGS $debugmod"
|
test -n "$debugmod" && CFLAGS="$CFLAGS $debugmod"
|
echo $CFLAGS
|
CFLAGS="$CFLAGS $IMPL"
|
|
|
AC_OUTPUT([Makefile bpb/Makefile cache/Makefile cpu/Makefile
|
AC_OUTPUT([Makefile bpb/Makefile cache/Makefile cpu/Makefile
|
cpu/common/Makefile cpu/or32/Makefile cpu/or16/Makefile
|
cpu/common/Makefile cpu/or32/Makefile cpu/or16/Makefile
|
cpu/or1k/Makefile cpu/dlx/Makefile
|
cpu/or1k/Makefile cpu/dlx/Makefile
|
support/Makefile mmu/Makefile peripheral/Makefile tick/Makefile
|
support/Makefile mmu/Makefile peripheral/Makefile tick/Makefile
|