From 1896a650fc382d343844b56f4b79efe31562755e Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Fri, 30 Jul 1999 17:52:50 +0000 Subject: Patch from Ralf Corsepius : The main topic is replacing the hard-coded values for HAS_MP and HAS_RDBG in custom/*.cfg with per-bsp configuration-time autoconf checks (This is the patch I had mentioned before earlier this week). CHANGES * HAS_MP removed from custom/*.cfg, replaced with configuration time autoconf check * HAS_RDBG removed from custom/*.cfg, replaced with configuration-time autoconf check * NEW: c/src/make/bsp.cfg.in, takes configuration-time checked per-bsp values (i.e. HAS_MP, HAS_RDBG), gets installed as $(prefix)//make/bsp.cfg * NEW: default.cfg includes bsp.cfg - this change is backward compatible. * IMPORT_SRC: apply VPATH instead for ts_386ex/i386ex subdirectory Makefile.ins * HACK: a bug in acpolish mis-handles addtions to makefile variables which are enclosed in gmake conditionals: c/src/lib/libbsp/m68k/ods68302/start302/Makefile.in * Apply inline_dir, HAS_MP and HAS_RDBG for avoiding configuration of unneeded subdirectories in various configure.in files. * Several minor changes in Makefile.ins and configure.ins, wrt. to the order of including *.cfg and defining Makefile variables APPLYING THE PATCH: patch -p1 < rtems-rc-19990709-4.diff ./autogen --- c/src/exec/configure | 143 +++++++++++++++++++++++++++++++-------------------- 1 file changed, 87 insertions(+), 56 deletions(-) (limited to 'c/src/exec/configure') diff --git a/c/src/exec/configure b/c/src/exec/configure index b116a5d6a1..3e230e7b00 100644 --- a/c/src/exec/configure +++ b/c/src/exec/configure @@ -2672,40 +2672,46 @@ RTEMS_USE_NEWLIB="$rtems_cv_use_newlib" -# find all the Executive Makefiles - -echo $ac_n "checking for Makefile.in in rtems""... $ac_c" 1>&6 -echo "configure:2679: checking for Makefile.in in rtems" >&5 -if test -d $srcdir/rtems; then - rtems_av_save_dir=`pwd`; - cd $srcdir; - rtems_av_tmp=`find rtems -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"` - makefiles="$makefiles $rtems_av_tmp"; - cd $rtems_av_save_dir; - echo "$ac_t""done" 1>&6 +# Check if there is custom/*.cfg for this BSP +echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6 +echo "configure:2678: checking for make/custom/$RTEMS_BSP.cfg" >&5 +if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then + echo "$ac_t""yes" 1>&6 else - echo "$ac_t""no" 1>&6 + { echo "configure: error: no" 1>&2; exit 1; } fi +echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6 +echo "configure:2687: checking whether BSP supports multiprocessing" >&5 +if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${RTEMS_BSP}/shmsupp"; then + if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then + rtems_cv_HAS_MP="yes" ; + else + rtems_cv_HAS_MP="disabled"; + fi + else + rtems_cv_HAS_MP="no"; + fi + +fi -echo $ac_n "checking for Makefile.in in sapi""... $ac_c" 1>&6 -echo "configure:2694: checking for Makefile.in in sapi" >&5 -if test -d $srcdir/sapi; then - rtems_av_save_dir=`pwd`; - cd $srcdir; - rtems_av_tmp=`find sapi -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"` - makefiles="$makefiles $rtems_av_tmp"; - cd $rtems_av_save_dir; - echo "$ac_t""done" 1>&6 +echo "$ac_t""$rtems_cv_HAS_MP" 1>&6 +if test "$rtems_cv_HAS_MP" = "yes"; then +HAS_MP="yes" else - echo "$ac_t""no" 1>&6 +HAS_MP="no" fi +# find all the Executive Makefiles + echo $ac_n "checking for Makefile.in in score/cpu/$RTEMS_CPU""... $ac_c" 1>&6 -echo "configure:2709: checking for Makefile.in in score/cpu/$RTEMS_CPU" >&5 +echo "configure:2715: checking for Makefile.in in score/cpu/$RTEMS_CPU" >&5 if test -d $srcdir/score/cpu/$RTEMS_CPU; then rtems_av_save_dir=`pwd`; cd $srcdir; @@ -2719,44 +2725,31 @@ fi -if test "$RTEMS_HAS_POSIX_API" = "yes"; then - -echo $ac_n "checking for Makefile.in in posix""... $ac_c" 1>&6 -echo "configure:2726: checking for Makefile.in in posix" >&5 -if test -d $srcdir/posix; then - rtems_av_save_dir=`pwd`; - cd $srcdir; - rtems_av_tmp=`find posix -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"` - makefiles="$makefiles $rtems_av_tmp"; - cd $rtems_av_save_dir; - echo "$ac_t""done" 1>&6 -else - echo "$ac_t""no" 1>&6 -fi - - - makefiles="$makefiles wrapup/posix/Makefile" -fi - -# Check if there is custom/*.cfg for this BSP -echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6 -echo "configure:2744: checking for make/custom/$RTEMS_BSP.cfg" >&5 -if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then - echo "$ac_t""yes" 1>&6 -else - { echo "configure: error: no" 1>&2; exit 1; } -fi - - # If RTEMS macros are enabled, then use them. Otherwise, use inlines. if test "$RTEMS_USE_MACROS" = "yes"; then - inline_dir=macros + inline_dir="macros" if test "$RTEMS_HAS_POSIX_API" = "yes"; then # The problem is that there is currently no code in posix/macros :) { echo "configure: error: Macros are not implemented for the POSIX API" 1>&2; exit 1; } fi else - inline_dir=inline + inline_dir="inline" +fi + +if test "$RTEMS_HAS_POSIX_API" = "yes"; then + makefiles="$makefiles posix/Makefile" + makefiles="$makefiles posix/src/Makefile" + makefiles="$makefiles posix/include/Makefile" + makefiles="$makefiles posix/include/sys/Makefile" + makefiles="$makefiles posix/include/rtems/Makefile" + makefiles="$makefiles posix/include/rtems/posix/Makefile" + makefiles="$makefiles posix/include/wrap/Makefile" + makefiles="$makefiles posix/optman/Makefile" + makefiles="$makefiles wrapup/posix/Makefile" + + makefiles="$makefiles posix/${inline_dir}/Makefile" + makefiles="$makefiles posix/${inline_dir}/rtems/Makefile" + makefiles="$makefiles posix/${inline_dir}/rtems/posix/Makefile" fi @@ -2885,6 +2878,25 @@ ac_given_srcdir=$srcdir ac_given_INSTALL="$INSTALL" trap 'rm -fr `echo "Makefile +rtems/Makefile +rtems/src/Makefile +rtems/include/Makefile +rtems/include/wrap/Makefile +rtems/include/rtems/Makefile +rtems/include/rtems/rtems/Makefile +rtems/optman/Makefile +rtems/${inline_dir}/Makefile +rtems/${inline_dir}/rtems/Makefile +rtems/${inline_dir}/rtems/rtems/Makefile +sapi/Makefile +sapi/src/Makefile +sapi/include/Makefile +sapi/include/wrap/Makefile +sapi/include/rtems/Makefile +sapi/include/rtems/sptables.h +sapi/${inline_dir}/Makefile +sapi/${inline_dir}/rtems/Makefile +sapi/optman/Makefile score/Makefile score/cpu/Makefile score/include/Makefile @@ -2898,7 +2910,6 @@ score/src/Makefile wrapup/Makefile wrapup/rtems/Makefile $makefiles -sapi/include/rtems/sptables.h " | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 EOF cat >> $CONFIG_STATUS <> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF @@ -3118,3 +3148,4 @@ chmod +x $CONFIG_STATUS rm -fr confdefs* $ac_clean_files test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 + -- cgit v1.2.3