Skip to content
This repository was archived by the owner on Jul 9, 2024. It is now read-only.
Open
Show file tree
Hide file tree
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
16 changes: 16 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
ODIR = ./output
BRANCH = master
JOBS = -
TESTS = 1
FILTER =

.PHONY: clean purge test-all

clean:
rm -rf $(ODIR)

rmi:
docker images | grep symless/synergy-core | tr -s ' ' | cut -d ' ' -f 2 | xargs -I {} docker rmi symless/synergy-core:{}

test-all:
./test-core-all $(FILTER) -j $(JOBS) -b $(BRANCH) -J $(TESTS)
8 changes: 4 additions & 4 deletions build-core.sh → build-container
Original file line number Diff line number Diff line change
Expand Up @@ -26,20 +26,20 @@ while getopts "h" flag; do
esac
done

OS="${@:$OPTIND:1}"
VERSION=${@:$OPTIND+1:1}
OS="${*:$OPTIND:1}"
VERSION=${*:$OPTIND+1:1}

echo -e "
ARGUMENTS:
OS: $OS
VERSION: $VERSION
"
if [ -z $OS ]; then
if [ -z "$OS" ]; then
echo "The OS parameter is required!"
usage
fi

if [ -z $VERSION ]; then
if [ -z "$VERSION" ]; then
echo "The VERSION parameter is required!"
usage
fi
Expand Down
8 changes: 4 additions & 4 deletions make-core.sh → make-core
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ while getopts "hj:b:" flag; do
esac
done

OS="${@:$OPTIND:1}"
VERSION=${@:$OPTIND+1:1}
OS="${*:$OPTIND:1}"
VERSION=${*:$OPTIND+1:1}

echo -e "
ARGUMENTS:
Expand All @@ -54,12 +54,12 @@ OPTIONS:
JOBS: $JOBS
BRANCH: $BRANCH
"
if [ -z $OS ]; then
if [ -z "$OS" ]; then
echo "The OS parameter is required!"
usage
fi

if [ -z $VERSION ]; then
if [ -z "$VERSION" ]; then
echo "The VERSION parameter is required!"
usage
fi
Expand Down
28 changes: 28 additions & 0 deletions synergy-core/debian/12/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM debian:12

# Update base packages
RUN export DEBIAN_FRONTEND=noninteractive \
&& apt-get update \
&& apt-get upgrade -y \
# Install Synergy core build dependencies
&& apt-get install -y \
build-essential \
cmake \
debhelper \
devscripts \
git \
libavahi-compat-libdnssd-dev \
libgdk-pixbuf2.0-dev \
libgl1-mesa-dev \
libglib2.0-dev \
libnotify-dev \
libssl-dev \
libx11-dev \
libxkbfile-dev \
libxtst-dev \
qtbase5-dev \
qttools5-dev \
qttools5-dev-tools \
zip \
&& rm -rf /var/lib/apt/lists \
&& git config --system --add safe.directory '*'
27 changes: 27 additions & 0 deletions synergy-core/fedora/39/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
FROM fedora:39

# Update base packages
RUN dnf -y update \
# Install Synergy core build dependencies
&& dnf -y install \
avahi-compat-libdns_sd \
avahi-compat-libdns_sd-devel \
cmake3 \
desktop-file-utils \
gdk-pixbuf2-devel \
git \
glib2-devel \
gpg \
libcurl-devel \
libnotify-devel \
libxkbfile-devel \
libXtst-devel \
make \
openssl-devel \
qt5-qtbase-devel \
qt5-qtdeclarative-devel \
qt5-qttools-devel \
rpm-build \
rpmlint \
&& rm -rf /var/cache/yum \
&& git config --system --add safe.directory '*'
27 changes: 27 additions & 0 deletions synergy-core/fedora/rawhide/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
FROM fedora:rawhide

# Update base packages
RUN dnf -y update \
# Install Synergy core build dependencies
&& dnf -y install \
avahi-compat-libdns_sd \
avahi-compat-libdns_sd-devel \
cmake3 \
desktop-file-utils \
gdk-pixbuf2-devel \
git \
glib2-devel \
gpg \
libcurl-devel \
libnotify-devel \
libxkbfile-devel \
libXtst-devel \
make \
openssl-devel \
qt5-qtbase-devel \
qt5-qtdeclarative-devel \
qt5-qttools-devel \
rpm-build \
rpmlint \
&& rm -rf /var/cache/yum \
&& git config --system --add safe.directory '*'
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:22.10
FROM ubuntu:rolling

# Update base packages
RUN export DEBIAN_FRONTEND=noninteractive \
Expand Down
12 changes: 6 additions & 6 deletions test-core.sh → test-core
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ while getopts "hj:b:" flag; do
esac
done

OS="${@:$OPTIND:1}"
VERSION=${@:$OPTIND+1:1}
OS="${*:$OPTIND:1}"
VERSION=${*:$OPTIND+1:1}

echo -e "
ARGUMENTS:
Expand All @@ -46,12 +46,12 @@ OPTIONS:
JOBS: $JOBS
BRANCH: $BRANCH
"
if [ -z $OS ]; then
if [ -z "$OS" ]; then
echo "The OS parameter is required!"
usage
fi

if [ -z $VERSION ]; then
if [ -z "$VERSION" ]; then
echo "The VERSION parameter is required!"
usage
fi
Expand All @@ -64,5 +64,5 @@ trap 'echo "\"${BASH_COMMAND}\" command filed with exit code $?."' DEBUG

mkdir -p output

./build-core.sh "$OS" "$VERSION" |& tee "./output/synergy-core-$OS$VERSION.txt"
./make-core.sh -j "$JOBS" -b "$BRANCH" "$OS" "$VERSION" |& tee -a "./output/synergy-core-$OS$VERSION.txt"
./build-container "$OS" "$VERSION" |& tee "./output/synergy-core-$OS-$VERSION.txt"
./make-core -j "$JOBS" -b "$BRANCH" "$OS" "$VERSION" |& tee -a "./output/synergy-core-$OS-$VERSION.txt"
16 changes: 8 additions & 8 deletions test-core-all.sh → test-core-all
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#! /usr/bin/env bash

JOBS="1"
TESTS="1"
BRANCH="master"
FILTER=""

Expand All @@ -27,18 +28,21 @@ OPTIONS:
exit 1
}

while getopts "hj:b:" flag; do
while getopts "hj:b:J:" flag; do
case "$flag" in
j) JOBS=$OPTARG;;
J) TESTS=$OPTARG;;
b) BRANCH=$OPTARG;;
*) usage;;
esac
done

FILTER=${@:$OPTIND}
FILTER=${*:$OPTIND}

echo -e "
ARGUMENTS:
TESTS: $TESTS
JOBS: $JOBS
FILTER: $FILTER

OPTIONS:
Expand All @@ -50,13 +54,9 @@ docker container prune -f
function args_pairs() {
for os in "$1"/*; do
for version in "$os"/*; do
if [ "ubuntu 16.04" = "$(basename "$os") $(basename "$version")" ]; then
echo "-j 1 $(basename "$os") $(basename "$version")"
else
echo "-j $JOBS $(basename "$os") $(basename "$version")"
fi
echo "-j $JOBS $(basename "$os") $(basename "$version")"
done
done
}

args_pairs "./synergy-core" | grep "$FILTER" | xargs -L1 ./test-core.sh -b "$BRANCH"
args_pairs "./synergy-core" | grep "$FILTER" | xargs -L1 -P "$TESTS" ./test-core -b "$BRANCH"