mirror of
https://github.com/yuezk/GlobalProtect-openconnect.git
synced 2025-04-02 18:31:50 -04:00
add rpm packaging (#83)
This commit is contained in:
parent
fa8b5c1528
commit
3175855122
5
.gitignore
vendored
5
.gitignore
vendored
@ -2,6 +2,11 @@
|
|||||||
gpclient
|
gpclient
|
||||||
gpservice
|
gpservice
|
||||||
|
|
||||||
|
*.rpm
|
||||||
|
*.gz
|
||||||
|
.DS_Store
|
||||||
|
build-debian
|
||||||
|
|
||||||
# Auto generated DBus files
|
# Auto generated DBus files
|
||||||
*_adaptor.cpp
|
*_adaptor.cpp
|
||||||
*_adaptor.h
|
*_adaptor.h
|
||||||
|
5
packaging/rpm/README.md
Normal file
5
packaging/rpm/README.md
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
## Command
|
||||||
|
|
||||||
|
```sh
|
||||||
|
docker run --rm -it -v ${PWD}:/rpm --workdir=/rpm --entrypoint ./entrypoint.sh centos:8
|
||||||
|
```
|
21
packaging/rpm/entrypoint.sh
Executable file
21
packaging/rpm/entrypoint.sh
Executable file
@ -0,0 +1,21 @@
|
|||||||
|
#!/bin/bash -e
|
||||||
|
|
||||||
|
# Install the build tools
|
||||||
|
dnf install -y epel-release
|
||||||
|
rpm --import http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-8
|
||||||
|
dnf install -y make rpm-build rpm-devel rpmlint rpmdevtools
|
||||||
|
|
||||||
|
# Install the build dependencies
|
||||||
|
dnf install -y qt5-qtbase-devel qt5-qtwebengine-devel qt5-qtwebsockets-devel
|
||||||
|
|
||||||
|
# Prepare the RPM build environment
|
||||||
|
rpmdev-setuptree
|
||||||
|
cp *.spec $HOME/rpmbuild/SPECS/
|
||||||
|
cp *.tar.gz $HOME/rpmbuild/SOURCES/
|
||||||
|
|
||||||
|
# Build
|
||||||
|
rpmbuild -ba $HOME/rpmbuild/SPECS/globalprotect-openconnect.spec
|
||||||
|
|
||||||
|
# Copy the package to the current directory
|
||||||
|
cp $HOME/rpmbuild/RPMS/x86_64/globalprotect-openconnect-*.rpm .
|
||||||
|
cp $HOME/rpmbuild/SRPMS/globalprotect-openconnect-*.src.rpm .
|
39
packaging/rpm/globalprotect-openconnect.spec
Normal file
39
packaging/rpm/globalprotect-openconnect.spec
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
Name: globalprotect-openconnect
|
||||||
|
Version: 1.3.0+SNAPSHOT20210829120923
|
||||||
|
Release: 1
|
||||||
|
Summary: A GlobalProtect VPN client
|
||||||
|
|
||||||
|
License: GPLv3
|
||||||
|
URL: https://github.com/yuezk/GlobalProtect-openconnect
|
||||||
|
Source0: %{url}/releases/download/latest/globalprotect-openconnect_%{version}.full.tar.gz
|
||||||
|
|
||||||
|
BuildRequires: qt5-qtbase-devel qt5-qtwebengine-devel qt5-qtwebsockets-devel
|
||||||
|
Requires: qt5-qtbase >= 5.12 qt5-qtwebengine >= 5.12 qt5-qtwebsockets >= 5.12 openconnect >= 8.0
|
||||||
|
|
||||||
|
%global debug_package %{nil}
|
||||||
|
|
||||||
|
%description
|
||||||
|
A GlobalProtect VPN client (GUI) for Linux based on OpenConnect and built with Qt5, supports SAML auth mode.
|
||||||
|
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup
|
||||||
|
|
||||||
|
|
||||||
|
%build
|
||||||
|
qmake-qt5 CONFIG+=release
|
||||||
|
%make_build
|
||||||
|
|
||||||
|
|
||||||
|
%install
|
||||||
|
INSTALL_ROOT=${RPM_BUILD_ROOT} %make_install
|
||||||
|
|
||||||
|
|
||||||
|
%files
|
||||||
|
/etc/systemd/system/gpservice.service
|
||||||
|
/usr/bin/gpclient
|
||||||
|
/usr/bin/gpservice
|
||||||
|
/usr/share/applications/com.yuezk.qt.gpclient.desktop
|
||||||
|
/usr/share/dbus-1/system-services/com.yuezk.qt.GPService.service
|
||||||
|
/usr/share/dbus-1/system.d/com.yuezk.qt.GPService.conf
|
||||||
|
/usr/share/pixmaps/com.yuezk.qt.GPClient.svg
|
Loading…
Reference in New Issue
Block a user