source: rtems/scripts/mkbspspec.in @ 0f242f5f

4.104.114.84.95
Last change on this file since 0f242f5f was 0f242f5f, checked in by Joel Sherrill <joel.sherrill@…>, on 10/20/99 at 19:54:36

Moving things to an rtems subdirectory like the other tools.

  • Property mode set to 100644
File size: 696 bytes
Line 
1#!/bin/sh
2#
3
4RTEMS_DIR=`dirname $0`
5RTEMS_VERSION=`grep Version ${RTEMS_DIR}/../VERSION | \
6sed -e 's%RTEMS[        ]*Version[      ]*\(.*\)[       ]*%\1%g'`
7
8bsp=$1
9target_alias=$2
10release=0
11
12# Some linux distributions use /usr/src/packages
13# redhat uses /usr/src/redhat
14# others might use /usr/src
15if test -d /usr/src/packages/SPECS;
16then
17dst=/usr/src/packages/SPECS;
18elif test -d /usr/src/redhat/SPECS;
19 then
20dst=/usr/src/redhat/SPECS;
21elif test -d /usr/src/SPECS/;
22then
23dst=/usr/src/SPECS;
24fi
25
26sed -e "s%@Version@%${RTEMS_VERSION}%g" \
27-e "s%@bsp@%${bsp}%g" \
28-e "s%@Release@%${release}%g" \
29-e "s%@target_alias@%${target_alias}%g" \
30< ${RTEMS_DIR}/rtems.spec.in \
31> ${dst}/rtems-$target_alias-$bsp.spec
Note: See TracBrowser for help on using the repository browser.