[4de3dc] | 1 | #!/usr/bin/env bash |
---|
| 2 | # Hannes helper to build tar files for the ftp server |
---|
[063360] | 3 | # for the patch-versions (version between official releases x.x.x) |
---|
| 4 | # for official versions: use "make dist"/"make distcheck" |
---|
[4de3dc] | 5 | |
---|
| 6 | set -e |
---|
[2570f08] | 7 | |
---|
[0f1f79] | 8 | TARVERSION=4.2.1p1 |
---|
| 9 | VERSION=4.2.1 |
---|
[0874066] | 10 | BUILD_DIR=/tmp/tst2 |
---|
[8f5493] | 11 | export VERSION TARVERSION BUILD_DIR |
---|
[724581c] | 12 | |
---|
[063360] | 13 | # sanity check |
---|
| 14 | if test -e $BUILD_DIR/singularconfig.h |
---|
| 15 | then |
---|
| 16 | |
---|
[0874066] | 17 | rm -rf singular-$VERSION |
---|
[724581c] | 18 | git archive --prefix=singular-$VERSION/ HEAD |tar xf - |
---|
| 19 | mkdir singular-$VERSION/doc |
---|
[0874066] | 20 | cp doc/*.* singular-$VERSION/doc/. |
---|
| 21 | mkdir singular-$VERSION/doc/images |
---|
| 22 | cp doc/images/* singular-$VERSION/doc/images/. |
---|
[fe8ff2] | 23 | |
---|
[6b08c9e] | 24 | command rm singular-$VERSION/.gdbinit singular-$VERSION/*/.gdbinit singular-$VERSION/*/*/.gdbinit singular-$VERSION/*/*/*/.gdbinit |
---|
[1a1f34b] | 25 | command rm singular-$VERSION/IntegerProgramming/README |
---|
[6b08c9e] | 26 | cd singular-$VERSION |
---|
| 27 | ./autogen.sh |
---|
| 28 | cd .. |
---|
[1a1f34b] | 29 | command rm -rf singular-$VERSION/autom4te.cache |
---|
| 30 | command rm -rf singular-$VERSION/*/autom4te.cache |
---|
| 31 | command rm -rf singular-$VERSION/*/*/autom4te.cache |
---|
| 32 | command rm -rf singular-$VERSION/omalloc/Misc |
---|
| 33 | command rm -rf singular-$VERSION/Singular/LIB/surfex |
---|
| 34 | command rm -rf singular-$VERSION/Singular/cnf2ideal.py |
---|
| 35 | command rm -rf singular-$VERSION/kernel/old singular-$VERSION/kernel/sample |
---|
| 36 | command rm -rf singular-$VERSION/dox/Doxyfile.html.all singular-$VERSION/dox/Doxyfile.in1 singular-$VERSION/dox/Doxyfile.latex.short singular-$VERSION/dox/readme |
---|
| 37 | command rm singular-$VERSION/factory/ConwayList.txt |
---|
| 38 | command rm -rf singular-$VERSION/logo singular-$VERSION/standalone.test singular-$VERSION/templates singular-$VERSION/tests |
---|
[2570f08] | 39 | cp $BUILD_DIR/redhat/singular.spec singular-$VERSION/redhat/singular.spec |
---|
[8f5493] | 40 | cp $BUILD_DIR/Singular/all.lib singular-$VERSION/Singular/LIB/. |
---|
[5afddc] | 41 | tar cf singular-$TARVERSION.tar singular-$VERSION |
---|
| 42 | gzip -9 -f singular-$TARVERSION.tar |
---|
[724581c] | 43 | command rm -rf singular-$VERSION |
---|
[063360] | 44 | |
---|
| 45 | else |
---|
| 46 | echo BUILD_DIR is not set correctly, use |
---|
| 47 | echo make dist |
---|
| 48 | echo in a configured directory |
---|
| 49 | exit 1 |
---|
| 50 | fi |
---|