Last change
on this file since 1320 was 1217, checked in by mar637, 18 years ago |
Merge from Release2.1.0b tag
|
-
Property svn:executable
set to
*
|
File size:
1.2 KB
|
Rev | Line | |
---|
[1159] | 1 | #!/bin/sh
|
---|
| 2 |
|
---|
[1161] | 3 | ROOTDIR=`pwd`
|
---|
[1159] | 4 |
|
---|
[1161] | 5 | # insert flags to make it install with gcc-4.1
|
---|
| 6 | gv=`gcc -dumpversion | sed -e 's#\.# #g'`
|
---|
| 7 | major=`/bin/echo $gv | awk '{ print $1 }'`
|
---|
| 8 | minor=`/bin/echo $gv | awk '{ print $2 }'`
|
---|
| 9 | cppflags=''
|
---|
| 10 | if [ $major -eq 4 ] && [ $minor -ge 1 ]; then
|
---|
| 11 | cppflags='-ffriend-injection -fpermissive '
|
---|
[1208] | 12 | echo "Found gcc-4.1. Applying patches..."
|
---|
[1161] | 13 | elif [ $major -eq 2 ]; then
|
---|
| 14 | echo "gcc version < 3 not supported"
|
---|
| 15 | exit 1
|
---|
| 16 | fi
|
---|
[1159] | 17 |
|
---|
[1161] | 18 | for AIPSINIT in aipsinit.sh aipsinit.csh
|
---|
[1159] | 19 | do
|
---|
[1161] | 20 | if [ ! -f $AIPSINIT ]
|
---|
| 21 | then
|
---|
| 22 | sed -e "s#__AIPSROOT#$ROOTDIR#g" $AIPSINIT.template > $AIPSINIT
|
---|
| 23 | fi
|
---|
[1159] | 24 | done
|
---|
[1161] | 25 |
|
---|
| 26 | # detect 64bit
|
---|
| 27 | platf=`uname -m | grep '64'`
|
---|
| 28 | arch=`uname -s`
|
---|
| 29 |
|
---|
| 30 | if [ ! $platf == '' ]; then
|
---|
[1208] | 31 | echo "configuting 64bit linux..."
|
---|
[1161] | 32 | mv $ROOTDIR/linux $ROOTDIR/linux_64b
|
---|
| 33 | cd $ROOTDIR/linux_64b/UNKNOWN_SITE
|
---|
[1217] | 34 | cat makedefs.64 | sed -e "s#-Wall #-Wall $cppflags#" > makedefs
|
---|
[1161] | 35 | cd $ROOTDIR
|
---|
| 36 | elif [ $arch == 'Darwin' ]; then
|
---|
[1208] | 37 | echo "configuring darwin..."
|
---|
[1161] | 38 | mv $ROOTDIR/linux $ROOTDIR/darwin
|
---|
| 39 | cd $ROOTDIR/darwin/UNKNOWN_SITE
|
---|
| 40 | cat makedefs.darwin > makedefs
|
---|
| 41 | cd $ROOTDIR
|
---|
| 42 | else
|
---|
[1208] | 43 | echo "configuring linux..."
|
---|
[1161] | 44 | cd $ROOTDIR/linux/UNKNOWN_SITE
|
---|
[1217] | 45 | cat makedefs.32 | sed -e "s#-Wall #-Wall $cppflags#" > makedefs
|
---|
[1161] | 46 | cd $ROOTDIR
|
---|
| 47 | fi
|
---|
Note:
See
TracBrowser
for help on using the repository browser.