run 616 Bytes
Newer Older
Sven Robertz's avatar
Sven Robertz committed
1
2
3
#!/bin/sh

# Auto generate code from .lc file
4
java -jar ../../compiler/labComm.jar \
Sven Robertz's avatar
Sven Robertz committed
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
  --c=example.c --h=example.h \
  --java=. \
  --cs=example.cs \
  --python=example.py \
  example.lc

# Compile executables
gcc -o example_encoder -I ../../lib/c/ \
	example_encoder.c \
 	example.c \
	../../lib/c/labcomm.c \
	../../lib/c//labcomm_fd_reader_writer.c
javac -cp ../../lib/java:. *.java

# Run through all executables (c->java->Python)
./example_encoder one two
java -cp ../../lib/java:. example_decoder_encoder example.encoded example.javaencoded
PYTHONPATH=../../lib/python ./example_decoder.py example.javaencoded