File: make_build_date.sh

package info (click to toggle)
devicexlib 0.8.6-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 10,364 kB
  • sloc: f90: 77,678; sh: 3,701; fortran: 773; makefile: 268; python: 246; ansic: 69; awk: 36
file content (32 lines) | stat: -rwxr-xr-x 649 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#! /bin/sh 
# generates the file include/build_date.h

# run from directory where this script is
cd `echo $0 | sed 's/\(.*\)\/.*/\1/'` # extract pathname
# come back to WanT HOME
cd ..  
#
TOPDIR=`pwd`
TARGETDIR=$TOPDIR/include
TARGETFILE=$TARGETDIR/build_date.h

if [ -e "$TARGETFILE" ] ; then rm $TARGETFILE ; fi
#
cat > $TARGETFILE << EOF

!
! Copyright (C) 2010 WanT Group
!
! This file is distributed under the terms of the
! GNU General Public License. See the file "License"
! in the root directory of the present distribution,
! or http://www.gnu.org/copyleft/gpl.txt .
!

#define   __CONF_BUILD_DATE           "`date '+%c'`"

EOF

exit 0