From b830445f6f1115ed0a04139d9216e54bfe3da1c0 Mon Sep 17 00:00:00 2001 From: Chris Johns Date: Wed, 14 Aug 2013 14:04:53 +1000 Subject: [PATCH] config: Support --without-rtems to not build RTEMS. The default is to build RTEMS. This change lets a user stop this by using '--without-rtems' on the command line. --- rtems/config/tools/rtems-kernel-4.11.cfg | 75 ++++++++++++++---------- 1 file changed, 43 insertions(+), 32 deletions(-) diff --git a/rtems/config/tools/rtems-kernel-4.11.cfg b/rtems/config/tools/rtems-kernel-4.11.cfg index 99ab111..f97035a 100644 --- a/rtems/config/tools/rtems-kernel-4.11.cfg +++ b/rtems/config/tools/rtems-kernel-4.11.cfg @@ -2,41 +2,52 @@ # RTEMS 4.11 # -%include %{_configdir}/checks.cfg -%include %{_configdir}/base.cfg -%include %{_configdir}/versions.cfg - -%define rtems_kernel_version 4.11 - # -# Check the version of autoconf. Check autoreconf as it is used. +# Optionally disable building the RTEMS kernel via the command line. # -%if %{__autoreconf_ver} <= 2.68 - %if %{__autoreconf_bindir_ver} <= 2.68 - %if %{__autoreconf_path_ver} <= 2.68 - %error Autoconf (autoreconf) version 2.69 or higher is needed. - %endif - %endif +%if %{without_rtems} + %define rtems_kernel_build 0 +%else + %define rtems_kernel_build 1 %endif -# -# A magic internal path that would break if changes in the defaults.mc -# macro file are made. -# -%define _internal_autotools_path %{_tmppath}/sb-%{_uid}/${SB_PREFIX_CLEAN} -# -# Pull the latest changes from git each build. Override if this is not what you -# want. -# -Source0: git://git.rtems.org/rtems.git?reset=hard?pull +%if %{rtems_kernel_build} + %include %{_configdir}/checks.cfg + %include %{_configdir}/base.cfg + %include %{_configdir}/versions.cfg -# -# The code in git needs to be bootstrapped. Do each build because we have -# no way to change what changes may have happened in the code. -# -%define rtems_bootstrap + %define rtems_kernel_version 4.11 -# -# The RTEMS build instructions. We use 4.xx Release 1. -# -%include tools/rtems-kernel-4-1.cfg + # + # Check the version of autoconf. Check autoreconf as it is used. + # + %if %{__autoreconf_ver} <= 2.68 + %if %{__autoreconf_bindir_ver} <= 2.68 + %if %{__autoreconf_path_ver} <= 2.68 + %error Autoconf (autoreconf) version 2.69 or higher is needed. + %endif + %endif + %endif + + # + # A magic internal path that would break if changes in the defaults.mc + # macro file are made. + # + %define _internal_autotools_path %{_tmppath}/sb-%{_uid}/${SB_PREFIX_CLEAN} + # + # Pull the latest changes from git each build. Override if this is not what you + # want. + # + Source0: git://git.rtems.org/rtems.git?reset=hard?pull + + # + # The code in git needs to be bootstrapped. Do each build because we have + # no way to change what changes may have happened in the code. + # + %define rtems_bootstrap + + # + # The RTEMS build instructions. We use 4.xx Release 1. + # + %include tools/rtems-kernel-4-1.cfg +%endif