diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ce325bc..f55824e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,14 +16,31 @@ # This specific template is located at: # https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Getting-Started.gitlab-ci.yml +variables: + GIT_SUBMODULE_STRATEGY: recursive + stages: # List of stages for jobs, and their order of execution - build -build-job: # This job runs in the build stage, which runs first. +build-fpga: # This job runs in the build stage, which runs first. tags: - efinity + - linux stage: build script: - source init_env.sh - cd hw/efinix_fpga - make + +build-sim: + tags: + - iverilog + - linux + stage: build + script: + - source init_env.sh + - cd sw/cc65 + - make -j + - cd ../.. + - cd hw/efinix_fpga/simulation + - make diff --git a/hw/efinix_fpga/simulation/Makefile b/hw/efinix_fpga/simulation/Makefile index 773850c..ee67cae 100644 --- a/hw/efinix_fpga/simulation/Makefile +++ b/hw/efinix_fpga/simulation/Makefile @@ -5,9 +5,10 @@ SRCS+=$(shell find ../src/ -type f -name "*.*v") INC=$(shell find include/ -type f) TEST_PROGRAM_NAME?=loop_test - +TEST_FOLDER?=$(REPO_TOP)/sw/test_code/$(TEST_PROGRAM_NAME) TEST_PROGRAM?=$(REPO_TOP)/sw/test_code/$(TEST_PROGRAM_NAME)/$(TEST_PROGRAM_NAME).hex + #TODO implement something like sources.list TOP_MODULE=sim_top @@ -19,9 +20,10 @@ all: $(INIT_MEM) iverilog -g2005-sv $(FLAGS) -s $(TOP_MODULE) -o $(TARGET) $(INC) $(SRCS) $(INIT_MEM): + $(MAKE) -C $(TEST_FOLDER) cp $(TEST_PROGRAM) ./init_hex.mem .PHONY: clean clean: rm -rf $(TARGET) - rm -rf $(INIT_MEM) \ No newline at end of file + rm -rf $(INIT_MEM) diff --git a/hw/efinix_fpga/super6502.xml b/hw/efinix_fpga/super6502.xml index ee79774..1431efd 100644 --- a/hw/efinix_fpga/super6502.xml +++ b/hw/efinix_fpga/super6502.xml @@ -1,4 +1,4 @@ - +