[1937] | 1 | #!/bin/bash |
---|
| 2 | |
---|
| 3 | # THE FIRST PARAMETER IS THE VERSION STRING |
---|
| 4 | |
---|
| 5 | set -e |
---|
| 6 | |
---|
| 7 | function make-dir () { |
---|
| 8 | if [ ! -d $1 ]; then |
---|
| 9 | mkdir $1 |
---|
| 10 | fi |
---|
| 11 | } |
---|
| 12 | |
---|
| 13 | VERSION=$1 |
---|
[1954] | 14 | PKGNAME='lemon' |
---|
| 15 | VERSION_STRING='svn-head' |
---|
[1937] | 16 | |
---|
| 17 | make-dir release-dir |
---|
| 18 | cd release-dir |
---|
| 19 | |
---|
| 20 | echo |
---|
| 21 | echo '**********************************************************************' |
---|
| 22 | echo ' CHECK OUT' |
---|
| 23 | echo '**********************************************************************' |
---|
| 24 | echo |
---|
| 25 | |
---|
| 26 | rm -rf trunk |
---|
| 27 | svn co https://hugo.cs.elte.hu/svn/hugo/trunk |
---|
[1958] | 28 | # svn lock https://hugo.cs.elte.hu/svn/hugo/trunk |
---|
[1937] | 29 | |
---|
| 30 | cd trunk |
---|
| 31 | |
---|
| 32 | echo |
---|
| 33 | echo '**********************************************************************' |
---|
| 34 | echo " CHANGE THE VERSION TO ${VERSION}" |
---|
| 35 | echo '**********************************************************************' |
---|
| 36 | echo |
---|
| 37 | |
---|
[2124] | 38 | sed "s/${VERSION_STRING}/${VERSION}/" <configure.ac >configure.ac.tmp |
---|
| 39 | mv configure.ac.tmp configure.ac |
---|
[1937] | 40 | |
---|
| 41 | echo |
---|
| 42 | echo '**********************************************************************' |
---|
| 43 | echo ' CREATE TARBALL' |
---|
| 44 | echo '**********************************************************************' |
---|
| 45 | echo |
---|
| 46 | |
---|
[1958] | 47 | ./bootstrap --amver=1.7 |
---|
[1955] | 48 | ./configure CXXFLAGS='-g -O2 -W -Wall -Werror' --enable-gui --enable-demo --enable-benchmark |
---|
[1937] | 49 | make doc |
---|
| 50 | make distcheck |
---|
| 51 | |
---|
| 52 | cd .. |
---|
| 53 | |
---|
| 54 | echo |
---|
| 55 | echo '**********************************************************************' |
---|
| 56 | echo ' CREATE THE OTHER TAR FILES' |
---|
| 57 | echo '**********************************************************************' |
---|
| 58 | echo |
---|
| 59 | |
---|
| 60 | mv trunk/${PKGNAME}-${VERSION}.tar.gz . |
---|
| 61 | tar xzf ${PKGNAME}-${VERSION}.tar.gz |
---|
| 62 | mv ${PKGNAME}-${VERSION}/doc/html ./${PKGNAME}-doc-${VERSION} |
---|
| 63 | tar czf ${PKGNAME}-doc-${VERSION}.tar.gz ${PKGNAME}-doc-${VERSION} |
---|
| 64 | tar czf ${PKGNAME}-${VERSION}-nodoc.tar.gz ${PKGNAME}-${VERSION} |
---|
| 65 | rm -rf ${PKGNAME}-${VERSION} ${PKGNAME}-doc-${VERSION} |
---|
| 66 | |
---|
| 67 | echo |
---|
| 68 | echo '**********************************************************************' |
---|
| 69 | echo ' CREATE SVN TAG' |
---|
| 70 | echo '**********************************************************************' |
---|
| 71 | echo |
---|
| 72 | |
---|
| 73 | svn cp trunk https://hugo.cs.elte.hu/svn/hugo/tags/${PKGNAME}-${VERSION} -m "Version ${VERSION} released." |
---|
[1958] | 74 | # svn unlock https://hugo.cs.elte.hu/svn/hugo/trunk |
---|