diff --git a/.github/workflows/driver-cross-build.yml b/.github/workflows/driver-cross-build.yml new file mode 100644 index 0000000..438325a --- /dev/null +++ b/.github/workflows/driver-cross-build.yml @@ -0,0 +1,60 @@ +name: CI + +on: + push: + branches: + - master + paths: + - 'src/drivers/**' + - '.github/workflows/**' + pull_request: + types: [opened, synchronize] + paths: + - 'src/drivers/**' + - '.github/workflows/**' + +jobs: + build: + strategy: + matrix: + env: + - { RPI_LINUX_VER: rpi-4.1.y, CONFIG_FILE: config-4.1.21-v7+, RPI_LINUX_COMMIT_HASH: ff45bc0 } + - { RPI_LINUX_VER: rpi-4.4.y, CONFIG_FILE: config-4.4.38-v7+, RPI_LINUX_COMMIT_HASH: c95b7f1 } + - { RPI_LINUX_VER: rpi-4.14.y, CONFIG_FILE: config-4.14.34-v7+, RPI_LINUX_COMMIT_HASH: f70eae4 } + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - name: Install cross-build settings + run: | + mkdir -p ${HOME}/repo/raspberrypi + if [ -e ${HOME}/repo/raspberrypi/tools ]; then (cd ${HOME}/repo/raspberrypi/tools && git pull); else (cd ${HOME}/repo/raspberrypi && git clone --depth 1 https://github.com/raspberrypi/tools.git); fi + + - name: Install kernel headers + env: + RPI_LINUX_VER: ${{ matrix.env.RPI_LINUX_VER }} + CONFIG_FILE: ${{ matrix.env.CONFIG_FILE }} + RPI_LINUX_COMMIT_HASH: ${{ matrix.env.RPI_LINUX_COMMIT_HASH }} + run: | + if [ -e ${HOME}/repo/raspberrypi/linux ]; then (cd ${HOME}/repo/raspberrypi/linux && git fetch origin && git checkout ${RPI_LINUX_VER} && git pull); else (cd ${HOME}/repo/raspberrypi && git clone -b ${RPI_LINUX_VER} https://github.com/raspberrypi/linux.git); fi + cd ${HOME}/repo/raspberrypi/linux && make clean && git reset --hard HEAD && git checkout ${RPI_LINUX_COMMIT_HASH} + cp "${GITHUB_WORKSPACE}/.test/${CONFIG_FILE}" ${HOME}/repo/raspberrypi/linux/.config + make CROSS_COMPILE=${HOME}/repo/raspberrypi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- ARCH=arm oldconfig + make CROSS_COMPILE=${HOME}/repo/raspberrypi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- ARCH=arm -j 8 + + - name: Build kernel module + run: | + cd ${GITHUB_WORKSPACE}/src/drivers + make -f ${GITHUB_WORKSPACE}/.test/Makefile.crosscompile + + - name: Output kernel module info + run: | + uname -a + echo ${{ matrix.env.RPI_LINUX_VER }} ${{ matrix.env.CONFIG_FILE }} ${{ matrix.env.RPI_LINUX_COMMIT_HASH }} + cd ${GITHUB_WORKSPACE}/src/drivers + modinfo rtmouse.ko + + - name: Clean up kernel module + run: | + cd ${GITHUB_WORKSPACE}/src/drivers + make -f ${GITHUB_WORKSPACE}/.test/Makefile.crosscompile clean diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 31e7fd4..0000000 --- a/.travis.yml +++ /dev/null @@ -1,43 +0,0 @@ -os: linux -group: stable -sudo: false -dist: xenial -language: generic - -addons: - apt: - packages: - - build-essential - - bc - -env: - global: - - HOME=/home/travis - matrix: - - RPI_LINUX_VER=rpi-4.1.y CONFIG_FILE=config-4.1.21-v7+ RPI_LINUX_COMMIT_HASH=ff45bc0 - - RPI_LINUX_VER=rpi-4.4.y CONFIG_FILE=config-4.4.38-v7+ RPI_LINUX_COMMIT_HASH=c95b7f1 - - RPI_LINUX_VER=rpi-4.14.y CONFIG_FILE=config-4.14.34-v7+ RPI_LINUX_COMMIT_HASH=f70eae4 - -cache: - apt: true - directories: - - $HOME/repo/raspberrypi - -install: - - export DRIVER_SRC_DIR=$(pwd)/src/drivers && echo $DRIVER_SRC_DIR - - export REPOSITORY_DIR=$(pwd) && echo $REPOSITORY_DIR - - mkdir -p $HOME/repo/raspberrypi - - if [ -e $HOME/repo/raspberrypi/tools ]; then (cd $HOME/repo/raspberrypi/tools && git pull); else (cd $HOME/repo/raspberrypi && git clone --depth 1 https://github.com/raspberrypi/tools.git); fi - -before_script: - - if [ -e $HOME/repo/raspberrypi/linux ]; then (cd $HOME/repo/raspberrypi/linux && git fetch origin && git checkout $RPI_LINUX_VER && git pull); else (cd $HOME/repo/raspberrypi && git clone -b $RPI_LINUX_VER https://github.com/raspberrypi/linux.git); fi - - cd $HOME/repo/raspberrypi/linux && make clean && git reset --hard HEAD && git checkout $RPI_LINUX_COMMIT_HASH - - cp "$REPOSITORY_DIR/.test/$CONFIG_FILE" $HOME/repo/raspberrypi/linux/.config - - make CROSS_COMPILE=$HOME/repo/raspberrypi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- ARCH=arm oldconfig - - make CROSS_COMPILE=$HOME/repo/raspberrypi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- ARCH=arm -j 8 - -script: - - cd $DRIVER_SRC_DIR - - make -f $REPOSITORY_DIR/.test/Makefile.crosscompile - - make -f $REPOSITORY_DIR/.test/Makefile.crosscompile clean - diff --git a/README.md b/README.md index 25b8fba..d954f55 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # RaspberryPiMouse -[![Build Status](https://travis-ci.org/rt-net/RaspberryPiMouse.svg?branch=master)](https://travis-ci.org/rt-net/RaspberryPiMouse) +![CI](https://github.com/rt-net/RaspberryPiMouse/workflows/CI/badge.svg?branch=master) This repository has the source code and kernel objects for the Raspberry Pi Mouse. @@ -84,4 +84,4 @@ This repository contains the code of the repository shown below. * [mcp3204.c in Raspberry Piで学ぶARMデバイスドライバープログラミング](http://www.socym.co.jp/support/s-940#ttlDownload) * GPL v2 License * [RPi-Distro/raspi-gpio](https://github.com/RPi-Distro/raspi-gpio) - * The 3-Clause BSD License \ No newline at end of file + * The 3-Clause BSD License pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy