-
Notifications
You must be signed in to change notification settings - Fork 3
/
Makefile
41 lines (30 loc) · 1.25 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# $Id$
#######################################################################################
## Project : hdl-secded-producer
## Designer : Dmitry Murzinov ([email protected])
## Link : https://github.com/iDoka/hdl-secded-producer
## Module : Makefile
## Description: MATLAB/Octave generator of Hamming ECC coding. Output format is Verilog HDL.
## Revision : $Rev
## Version : $GlobalRev$
## Date : $LastChangedDate$
## License : MIT
#######################################################################################
SCRIPT=hamming_producer.m
MATLAB_SCRIPT=$(shell basename -s.m $(SCRIPT))
OUTFILE=HammingCode.v
# If you have the student version of MATLAB (or simply the 32 bit version) on a 64 bit system,
# you will need to uncomment following string:
#STUDENT_OPT=-glnx86
#all: octave
all: matlab
@echo "Generate done!"
matlab:
@echo "MATLAB: Generating Hamming ECC coder/decoder verilog code: $(OUTFILE)"
@matlab -nosplash -nodesktop -nodisplay -nojvm $(STUDENT_OPT) -r $(MATLAB_SCRIPT)
octave:
@echo "GNU Octave: Generating Hamming ECC coder/decoder verilog code: $(OUTFILE)"
@octave --silent --no-gui --no-window-system --traditional $(SCRIPT)
clean:
@rm -rf $(OUTFILE)
.PHONY: octave matlab all clean