Skip to content
This repository was archived by the owner on Mar 7, 2021. It is now read-only.

Fixed #5 -- added the most basic CI #6

Merged
merged 10 commits into from
May 18, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
sudo: required

language: rust
rust:
- nightly
cache:
- cargo: true
# TODO: dedup this with the MODULE_DIR in env
- directories:
- static-filesystem/target/
- hello-world/target/

matrix:
include:
- env: MODULE_DIR=hello-world MODULE=helloworld
# TODO: currently the kernel module fails to load
# - env: MODULE_DIR=static-filesystem MODULE=staticfilesystem

install:
- sudo apt-get install -y "linux-headers-$(uname -r)"
- type -p cargo-install-update || cargo install --force cargo-update
- |
if type -p cargo-xbuild; then
cargo install-update -i cargo-xbuild
else
cargo install --force cargo-xbuild
fi
- rustup component add rust-src

script:
- cd $MODULE_DIR
- RUST_TARGET_PATH="$(pwd)/.." cargo xbuild --target x86_64-linux-kernel-module
- make
- sudo insmod "${MODULE}.ko"
- sudo rmmod "$MODULE"