Skip to content

Commit

Permalink
Merge
Browse files Browse the repository at this point in the history
  • Loading branch information
dallmair committed Dec 28, 2024
2 parents a37913c + 22f0fd7 commit 294adaf
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 20 deletions.
69 changes: 51 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,43 +2,76 @@ name: CI

on:
push:
branches: [ "main" ]
branches: "*"
pull_request:
branches: [ "main" ]
branches: "*"

permissions: {}

jobs:
build:
# On Ubuntu, because that is the standard OS of GitHub Actions.
build_ubuntu:

runs-on: ubuntu-latest

steps:
- name: Install build dependencies
run: sudo apt-get update && sudo apt-get install -y libusb-1.0-0-dev libsystemd-dev libev-dev libfmt-dev libinih-dev

- uses: actions/checkout@v4
with:
fetch-depth: 0 # Full history to be able to determine version number

- name: Install build dependencies
run: sudo apt-get update && sudo apt-get install -y libusb-1.0-0-dev libsystemd-dev libev-dev libfmt-dev libinih-dev

- name: Bootstrap
run: sh bootstrap.sh

- name: Configure
run: ./configure

- name: Build
run: make
run: make -j$(nproc)

- name: Install
run: sudo make -j1 install

# On Alpine, because it's a tiny distro heavily used in containers.
build_alpine:

- name: Run check
run: make check
runs-on: ubuntu-latest
container: alpine

- name: Test install
run: sudo make install
steps:
- name: Install build dependencies
run: apk update && apk add git build-base autoconf automake libtool argp-standalone linux-headers libusb-dev libev-dev fmt-dev inih-dev

debian:
- name: Configure git in container
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Full history to be able to determine version number

- name: Bootstrap
run: sh bootstrap.sh

- name: Configure
run: ./configure --disable-systemd

- name: Build
run: make -j$(nproc)

- name: Install
run: make -j1 install

# Debian packaging; May break when code changes require updates to the Debian package.
# Merges the pushed/proposed code changes to the `debian` branch and builds that then.
package_debian:

strategy:
fail-fast: false
matrix:
release: [stable, oldstable, testing]
release: [testing, stable, oldstable]
runs-on: ubuntu-latest
container: debian:${{ matrix.release }}-slim

Expand All @@ -49,16 +82,16 @@ jobs:
apt-get upgrade -y
apt-get install -y --no-install-recommends ca-certificates git sudo
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Full history to be able to determine version number

- name: Configure git
- name: Configure git in container
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git config --global user.name "Your Name"
git config --global user.email "you@example.com"
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Full history to be able to determine version number

- name: Merge into debian branch
run: git checkout debian && git merge "$GITHUB_REF"

Expand Down
1 change: 0 additions & 1 deletion src/libserver/tcptunserver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
#include "config.h"
#include "tunchannel.h"

#include <unistd.h>
#include <netinet/tcp.h>
#include <sys/un.h>
#include <arpa/inet.h>
Expand Down
2 changes: 1 addition & 1 deletion src/usb/usb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

#include <cstdlib>
#include <cerrno>
#include <sys/poll.h>
#include <poll.h>
#include "usb.h"
#include "types.h"

Expand Down

0 comments on commit 294adaf

Please sign in to comment.