aboutsummaryrefslogtreecommitdiff
path: root/util/mkup
blob: ed4499f5fb6d2122ef21e5aa0a73a12f1359776c (plain) (blame)
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
#!/bin/bash
#

# Initialize the $iraf and environment.
if [ -z "$iraf" ]; then
  if [ -e "$HOME/.iraf/setup.sh" ]; then
    source $HOME/.iraf/setup.sh
  else
    source unix/hlib/setup.sh
  fi
else
    source $iraf/unix/hlib/setup.sh
fi

source $iraf/unix/hlib/irafuser.sh

# Reconfigure the system for the proper architecture if needed.
if [ -n "$IRAFARCH" ]; then		# use environment value
    make $IRAFARCH
else					# use actual value
    arch=`$iraf/unix/hlib/irafarch.sh -actual`
    cfgarch=`mkpkg arch | sed -e "s/system is configured for //g"`
    if [ $cfgarch != $arch ]; then
	#make $arch
	/bin/echo "Warning: current arch="$cfgarch" but system arch="$arch
	export IRAFARCH=$arch
    fi
fi

cd $iraf/				# build core system
mkpkg
mkpkg update

cd $iraf/noao				# build NOAO package
export noao=`pwd`/
mkpkg -p noao

cd $iraf/vo				# build VO package
export vo=`pwd`/
cd votools				# build VOTOOLS package
mkpkg -p vo update