diff --git a/.gitignore b/.gitignore index 833ec3e..9abb530 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ qjournalctl.pro.user build/* src/version.h qrc_icon.cpp +*.deb diff --git a/packaging/deb/Dockerfile b/packaging/deb/Dockerfile new file mode 100644 index 0000000..a159343 --- /dev/null +++ b/packaging/deb/Dockerfile @@ -0,0 +1,15 @@ +FROM ubuntu + +ARG LIBSSHVERS=0.9 +ARG LIBSSHVERSION=0.9.0 + +WORKDIR /build + +# Get dependencies +RUN apt-get update -y +RUN apt-get install -y build-essential pkg-config qtbase5-dev cmake g++ libssl-dev xz-utils libzip-dev wget + +# Manually build libssh +RUN wget https://www.libssh.org/files/$LIBSSHVERS/libssh-$LIBSSHVERSION.tar.xz && tar xf libssh-$LIBSSHVERSION.tar.xz && cd libssh-$LIBSSHVERSION && mkdir build && cd build && cmake .. && make -j$(nproc) && make install && cd ../.. && rm -rf /build/* + +# Ready to build qjournalctl now :) diff --git a/packaging/deb/build_deb.sh b/packaging/deb/build_deb.sh new file mode 100755 index 0000000..6adb6d0 --- /dev/null +++ b/packaging/deb/build_deb.sh @@ -0,0 +1,23 @@ +#/bin/bash + +NAME=qjournalctl +VERSION=0.6 +PKGREV=1 +OUT="$NAME""_$VERSION-$PKGREV" + +# Build +QT_SELECT=qt5 qmake /source/qjournalctl.pro -r -spec linux-g++ CONFIG+=release +make -j$(nproc) + +# Move required files +cp -r /source/packaging/files $OUT/ +mkdir -p $OUT/usr/bin +mv qjournalctl $OUT/usr/bin + +# debian pkg files +mkdir -p $OUT/DEBIAN/ +cp /source/packaging/deb/control $OUT/DEBIAN/ +dpkg-deb --build $OUT + +# Keep ownership +cat $OUT.deb > /out/$OUT.deb diff --git a/packaging/deb/control b/packaging/deb/control new file mode 100644 index 0000000..5d65f7f --- /dev/null +++ b/packaging/deb/control @@ -0,0 +1,8 @@ +Package: qjournalctl +Version: 0.6-1 +Section: admin +Priority: optional +Architecture: amd64 +Depends: libssh (>= 0.8.7), qtbase5-dev (>= 1.2.6) +Maintainer: Patrick Eigensatz +Description: A Qt-based Graphical User Interface for systemd's journalctl command diff --git a/packaging/files/usr/share/applications/qjournalctl.desktop b/packaging/files/usr/share/applications/qjournalctl.desktop new file mode 100644 index 0000000..100b199 --- /dev/null +++ b/packaging/files/usr/share/applications/qjournalctl.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Encoding=UTF-8 +Type=Application +Name=QJournalctl +Comment=Graphical User Interface for systemd's journalctl +Exec=qjournalctl +Icon=qjournalctl +Terminal=false +StartupNotify=false +Categories=System; diff --git a/packaging/files/usr/share/pixmaps/qjournalctl.png b/packaging/files/usr/share/pixmaps/qjournalctl.png new file mode 100644 index 0000000..42c3888 Binary files /dev/null and b/packaging/files/usr/share/pixmaps/qjournalctl.png differ