Mercurial > repos > rhope
annotate ctobin @ 126:85f8012b6938
Simplify and speed up List by removing support for sparse Lists
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Thu, 28 Oct 2010 21:39:17 -0400 |
parents | e556416e9c91 |
children | a68e6828d896 |
rev | line source |
---|---|
75
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
1 #!/bin/sh |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
2 |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
3 if test ! -f "$1.c"; then |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
4 echo "C file missing! Maybe you need to do a full compile?" |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
5 exit 1 |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
6 fi |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
7 |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
8 cp runtime/* build/ |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
9 cp "$1.c" build/ |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
10 cd build |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
11 bin=`echo $1 | sed s/\.rhope//` |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
12 |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
13 if test -f "$bin"; then |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
14 rm "$bin" |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
15 fi |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
16 |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
17 if test -z $CC; then |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
18 CC="gcc" |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
19 fi |
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
20 |
125
e556416e9c91
Update compilation scripts
Mike Pavone <pavone@retrodev.com>
parents:
105
diff
changeset
|
21 file=$1 |
e556416e9c91
Update compilation scripts
Mike Pavone <pavone@retrodev.com>
parents:
105
diff
changeset
|
22 shift |
e556416e9c91
Update compilation scripts
Mike Pavone <pavone@retrodev.com>
parents:
105
diff
changeset
|
23 echo "$CC -o $bin $@ $file.c blueprint.c context.c fixed_alloc.c object.c" |
e556416e9c91
Update compilation scripts
Mike Pavone <pavone@retrodev.com>
parents:
105
diff
changeset
|
24 $CC -o $bin $@ "$file.c" blueprint.c context.c fixed_alloc.c object.c |
75
0083b2f7b3c7
Partially working implementation of List. Modified build scripts to allow use of other compilers. Fixed some bugs involving method implementations on different types returning different numbers of outputs. Added Fold to the 'builtins' in the comipler.
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
25 |
81
dbe95bfec970
Very basic file access is now working; however, there's a bug involving assigning a literal to a named pipe inside a conditional block that needs fixing
Mike Pavone <pavone@retrodev.com>
parents:
75
diff
changeset
|
26 cd .. |
dbe95bfec970
Very basic file access is now working; however, there's a bug involving assigning a literal to a named pipe inside a conditional block that needs fixing
Mike Pavone <pavone@retrodev.com>
parents:
75
diff
changeset
|
27 |