Simplify significantly (and fix syntax error).
[oota-llvm.git] / utils / makellvm
1 #!/bin/csh -f
2
3         ## LLVMDIR is simply the directory where this script resides!
4 set THISEXEC = $0               ## cannot use :h on $0 for some reason
5 set LLVMDIR = $THISEXEC:h
6 set EXEC = opt
7
8 if ($#argv > 0) then
9     if ($argv[1] == "-h") then
10         echo 'USAGE: makellvm [toolname]   (toolname defaults to "opt").'
11         exit 0
12     endif
13     set EXEC = $argv[1]
14 endif
15
16 gnumake && (cd $LLVMDIR/tools/$EXEC && gnumake)