OpenCores
URL https://opencores.org/ocsvn/zipcpu/zipcpu/trunk

Subversion Repositories zipcpu

[/] [zipcpu/] [trunk/] [bench/] [cpp/] [Makefile] - Blame information for rev 36

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 dgisselq
################################################################################
2
#
3
# Filename:     Makefile
4
#
5
# Project:      Zip CPU -- a small, lightweight, RISC CPU soft core
6
#
7
# Purpose:      This makefile builds the final verilator simulation of the
8
#               zipsystem.  Specifically, it builds the final C++ portion
9
#               of the simulator, and thus the final simulator executable.
10
#
11
#               This simulator depends upon the ncurses library.
12
#
13
#
14
# Creator:      Dan Gisselquist, Ph.D.
15
#               Gisselquist Tecnology, LLC
16
#
17
################################################################################
18
#
19
# Copyright (C) 2015, Gisselquist Technology, LLC
20
#
21
# This program is free software (firmware): you can redistribute it and/or
22
# modify it under the terms of  the GNU General Public License as published
23
# by the Free Software Foundation, either version 3 of the License, or (at
24
# your option) any later version.
25
#
26
# This program is distributed in the hope that it will be useful, but WITHOUT
27
# ANY WARRANTY; without even the implied warranty of MERCHANTIBILITY or
28
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
29
# for more details.
30
#
31
# License:      GPL, v3, as defined and found on www.gnu.org,
32
#               http://www.gnu.org/licenses/gpl.html
33
#
34
#
35
################################################################################
36
#
37
all: zippy_tb
38
 
39
CXX     := g++
40
FLAGS   := -Wall -Og -g
41
ZASM    := ../../sw/zasm
42
INCS    := -I../../rtl/obj_dir/ -I/usr/share/verilator/include -I../../sw/zasm
43
SOURCES := zippy_tb.cpp memsim.cpp twoc.cpp $(ZASM)/zopcodes.cpp $(ZASM)/zparser.cpp
44
RAWLIB  := /usr/share/verilator/include/verilated.cpp ../../rtl/obj_dir/Vzipsystem__ALL.a
45
LIBS    := $(RAWLIB) -lncurses
46 27 dgisselq
TESTF   := ../../sw/zasm/z.out
47 2 dgisselq
 
48 36 dgisselq
zippy_tb: $(SOURCES) $(RAWLIB) $(ZASM)/zopcodes.h $(ZASM)/zparser.h testb.h
49 2 dgisselq
        $(CXX) $(FLAGS) $(INCS) $(SOURCES) $(LIBS) -o $@
50
 
51 36 dgisselq
.PHONY: stest
52
stest: zippy_tb
53
        ./zippy_tb -s $(TESTF)
54
 
55
.PHONY: itest
56 27 dgisselq
itest: zippy_tb
57
        ./zippy_tb $(TESTF)
58
 
59 36 dgisselq
.PHONY: test
60
test: zippy_tb stest
61 27 dgisselq
        ./zippy_tb -a $(TESTF)
62 36 dgisselq
 
63
.PHONY: clean
64
clean:
65
        rm ./zippy_tb

powered by: WebSVN 2.1.0

© copyright 1999-2022 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.