aboutsummaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
diff options
context:
space:
mode:
authorClément Zrounba <6691770+clement-z@users.noreply.github.com>2023-09-30 23:06:01 +0200
committerClément Zrounba <6691770+clement-z@users.noreply.github.com>2023-09-30 23:26:46 +0200
commitff9b8bb838ecdfbfc1dc81038fcf3b2a87636982 (patch)
tree21f27be782ce11c6d00b96ce100a2bff88141b2e /.gitlab-ci.yml
downloadspecs-ff9b8bb838ecdfbfc1dc81038fcf3b2a87636982.tar.gz
specs-ff9b8bb838ecdfbfc1dc81038fcf3b2a87636982.zip
Initial release
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml79
1 files changed, 79 insertions, 0 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 0000000..f41da7d
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,79 @@
+# Currently using alpine as base
+#image: alpine:latest
+image: alpine:latest
+# TODO: Migrate to another base including all the dependencies
+# in order to avoid fetching and installing everything each time
+
+stages:
+ - build
+ - test
+ - deploy
+
+variables:
+ # Recursive submodule update
+ GIT_SUBMODULE_STRATEGY: recursive
+
+before_script:
+ # Add the testing repo for SystemC
+ - echo http://dl-cdn.alpinelinux.org/alpine/edge/testing >> /etc/apk/repositories
+ # Install all dependencies
+ - apk update
+ - apk add --no-cache
+ bash findutils
+ build-base bison flex
+ doxygen graphviz
+ systemc-dev
+ - cp .config.gitlab-ci.mk config.local.mk
+
+build:
+ stage: build
+ script:
+ - make -j$(nproc) bin V=1
+ - make -j$(nproc) lib V=1
+ artifacts:
+ paths:
+ - "./specs"
+ - "./libspecs.so"
+
+test:
+ stage: test
+ script:
+ # Only running a few tests manually for now
+ - ./specs -t wg
+ #- ./specs -t dc
+ #- ./specs -t splitter
+ #- ./specs -t merger
+ #- ./specs -t detector
+ #- ./specs -t phaseshifter
+ # TODO: add other tests (both from -t and the circuit test files)
+ dependencies:
+ - build
+ artifacts:
+ paths:
+ - "traces/*.vcd"
+
+doc:
+ stage: build
+ script:
+ - make doc
+ artifacts:
+ paths:
+ - doc/pcm-doc.tar.xz
+ - doc/html/
+ only:
+ - master
+
+
+pages:
+ stage: deploy
+ script:
+ - mkdir public
+ - cp -R doc/html/* public
+ dependencies:
+ - doc
+ artifacts:
+ paths:
+ - public
+ only:
+ - master
+