Changeset 320 in MondoRescue for trunk/tools/mksvnversion


Ignore:
Timestamp:
Jan 15, 2006, 12:29:12 AM (18 years ago)
Author:
bcornec
Message:

merge -r316:319 $SVN_M/branches/2.06

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/mksvnversion

    r238 r320  
    11#!/bin/bash
    2 ########################################################
    3 # $Id$
    4 ########################################################
    52#
    63# on every build, record the working copy revision string
    74#
    8 dname=`dirname $0`
    9 prem=`echo $dname |cut -c1`
    10 if [ ${prem} == "/" ]; then
    11     export TOOLHOME=$dname
    12 else
    13     export TOOLHOME=${PWD}/$dname
     5# $Id$
     6#
     7
     8# TOOLHOME should be provided by callers
     9if [ _"$TOOLHOME" = _"" ]; then
     10    # It's not the case so compute it
     11    dname=`dirname $0`
     12    prem=`echo $dname |cut -c1`
     13    if [ ${prem} == "/" ]; then
     14        export TOOLHOME=$dname
     15    else
     16        export TOOLHOME=${PWD}/$dname
     17    fi
    1418fi
    15 . $TOOLHOME/rpm-env
    1619
    17 #
    18 # Create a .c file for mondo to link with and get
    19 # the right build version from SVN
    20 #
    2120rel=`svnversion $TOOLHOME/..`
    22 cat > $TOOLHOME/../mondo/revision.h << EOF
    23 #define REVISION "${rel}"
    24 EOF
     21
    2522cat > $TOOLHOME/../mondo/REVISION << EOF
    2623${rel}
Note: See TracChangeset for help on using the changeset viewer.