Revision 1,
773 bytes
checked in by mmamonski, 14 years ago
(diff) |
Torque/PBS DRMAA initial commit
|
-
Property svn:executable set to
*
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | # ylwrap script specially crafted for Bison |
---|
3 | |
---|
4 | input="$1"; shift |
---|
5 | |
---|
6 | while true; do |
---|
7 | case "$1" in |
---|
8 | "") exit 1;; |
---|
9 | --) shift; break;; |
---|
10 | *) shift;; |
---|
11 | esac |
---|
12 | done |
---|
13 | |
---|
14 | prog="$1"; shift; args=$@ |
---|
15 | if [ ${prog} != "bison" ]; then |
---|
16 | cat >&2 <<EOF |
---|
17 | * ERROR: Bison was not found at configuration time while some sources are |
---|
18 | * build by it. Either install Bison <http://www.gnu.org/software/bison/> |
---|
19 | * or download tarball with generated sources included (than you will |
---|
20 | * not be able to modify .y files). |
---|
21 | EOF |
---|
22 | exit 1 |
---|
23 | fi |
---|
24 | |
---|
25 | real_args="" |
---|
26 | for i in $args; do |
---|
27 | case "$i" in |
---|
28 | -y) ;; |
---|
29 | --yacc) ;; |
---|
30 | *) real_args="$real_args $i" ;; |
---|
31 | esac |
---|
32 | done |
---|
33 | |
---|
34 | echo "${prog} --output=`basename ${input} .y`.c ${real_args[@]} ${input}" |
---|
35 | ${prog} --output=`basename ${input} .y`.c ${real_args[@]} ${input} |
---|
36 | |
---|
37 | |
---|
Note: See
TracBrowser
for help on using the repository browser.