source: scripts/locker-update @ 56e4869

debianrelease-1.10release-1.4release-1.5release-1.6release-1.7release-1.8release-1.9
Last change on this file since 56e4869 was 56e4869, checked in by Nelson Elhage <nelhage@mit.edu>, 15 years ago
Add usage and clean up the build script a lot.
  • Property mode set to 100755
File size: 838 bytes
Line 
1#!/bin/bash
2NEWVERSION="$1"
3
4# Run this as 'locker-update NEW-VERSION' to upgrade the barnowl.real
5# symlink in all arch/ directories to point to the new version.
6
7if [ -z "$NEWVERSION" ]; then
8    echo "Usage: $0 new-version" 1>&2
9    exit -1;
10fi
11
12cd /mit/barnowl/arch/
13
14for i in *; do
15    if [ -L "$i" ]; then
16        echo "Skipping $i as a symbolic link..."
17    else
18        if [ "$i" = "common" ]; then
19            echo "Skipping 'common'..."
20        else
21            if ! [ -e "$i/bin/$NEWVERSION" ]; then
22                echo "New version $NEWVERSION not built for arch $i...";
23            else
24                # Sanity -- make sure the 'barnowl' symlink is correct.
25                ln -sf "../../common/bin/barnowl" "$i/bin/barnowl"
26                ln -sf "$NEWVERSION" "$i/bin/barnowl.real"
27            fi
28        fi
29    fi
30done;
Note: See TracBrowser for help on using the repository browser.