aboutsummaryrefslogtreecommitdiffhomepage
path: root/distrib/configure.distrib
blob: bc7ff74e926ad272b4e3695a067be16eb80291ac (plain)
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
#!/bin/sh

####################################
#
#  Configuration script for releases
# 
####################################
#
#  Default values comes from ../configure which is probably consistent
#  with the archive
#

VERSION=`sed -n -e 's/^VERSION=\(.*\)/\1/p' ../configure`
DATE=`sed -n -e 's/^DATE=\(.*\)/\1/p' ../configure`
RELEASENUM=1
DISTRIBDIR=`pwd`

# i.86 standardized to i386
# MacOS X returns "Power Macintosh" - changed to "MacOS-X"
ARCH=`uname -m | sed -e 's/i.86/i386/' -e 's/Power Macintosh/MacOS-X/'`

echo Default values are taken from ../configure
echo ------------------------------------------

# Determine the release number
echo -n "Version number of the current release [$VERSION]? "
read ANSWER
case $ANSWER in
 "") true;;
 *) VERSION=$ANSWER;
esac

# The main number of the release
MAINNUMBER=`echo $VERSION | sed -e 's/^\([0-9]\+*\)\.[0-9]\+.*$/\1/'`
# The minor number
LASTNUMBER=`echo $VERSION | sed -e 's/^[0-9]\+\.\([0-9]\+\).*$/\1/'`
# The release level: alpha, beta, etc.
LEVEL=`echo $VERSION | sed -e 's/^[0-9]\+\.[0-9]\+\(.*\)$/\1/'`

MAJORVERSION=V$MAINNUMBER
CVSMODULE=V7
CVSTAG=V`echo $VERSION | sed -e 's/\./-/g'`
if [ "$LASTNUMBER" = "0" ]; then
    PREVIOUSMAINNUMBER=`expr $MAINNUMBER - 1`
    PREVIOUSVERSION=$PREVIOUSMAINNUMBER.99
else
    PREVIOUSLASTNUMBER=`expr $LASTNUMBER - 1`
    PREVIOUSVERSION=$MAINNUMBER.$PREVIOUSLASTNUMBER
fi

# Determine the previous release number
echo -n "Version number of the previous release (for the patch file) [$PREVIOUSVERSION]? "
read ANSWER
case $ANSWER in
 "") true;;
 *) PREVIOUSVERSION=$ANSWER;;
esac


# Determine the searchisos version number
#echo -n "What is the version number of the current SearchIsos release [$VERSIONSI]? "
#read ANSWER
#case $ANSWER in
# "") true;;
# *) VERSIONSI=$ANSWER;;
#esac

# Determine the date of the release
echo -n "Date of the current release [$DATE]? "
read ANSWER
case $ANSWER in
 "") true;;
 *) DATE=$ANSWER;;
esac

# Determine the rpm release number
echo -n "Release number for the RPM packages [$RELEASENUM]? "
read ANSWER
case $ANSWER in
 "") true;;
 *) RELEASENUM=$ANSWER;;
esac

echo CVSMODULE=$CVSMODULE > config.distrib
echo CVSTAG=$CVSTAG >> config.distrib
echo DISTRIBDIR=$DISTRIBDIR >> config.distrib
echo VERSION=$VERSION >> config.distrib
echo RELEASENUM=$RELEASENUM >> config.distrib
echo ARCH=$ARCH >> config.distrib
echo PREVIOUSVERSION=$PREVIOUSVERSION >> config.distrib
#echo VERSIONSI=$VERSIONSI >> config.distrib
chmod +x config.distrib

# $Id$