Sophie

Sophie

distrib > Mageia > 9 > armv7hl > media > core-release-src > by-pkgid > e5c44ec5eb12970716baa5862a0462e5 > files > 4

barrier-2.4.0-1.mga9.src.rpm

%define gulrak_version	1.5.14

Name:		barrier
Version:	2.4.0
Release:	%mkrel 1
Summary:	Mouse, keyboard and clipboard sharing utility
License:	GPLv2
Group:		Networking/Remote access
URL:		https://github.com/debauchee/barrier
Source0:	%{url}/archive/v%{version}/%{name}-%{version}.tar.gz
# Gulrak filesystem https://github.com/gulrak/filesystem
Source1:	https://github.com/gulrak/filesystem/archive/v%{gulrak_version}/filesystem-%{gulrak_version}.tar.gz
# https://github.com/debauchee/barrier/issues/1366
Patch1:		0001-fix-includes.patch
Patch2:		0001-Add-missing-include-directives-needed-for-GCC-13.patch

BuildRequires:	cmake
BuildRequires:	imagemagick
BuildRequires:	librsvg
#BuildRequires:	gulrak-filesystem-devel
BuildRequires:	pkgconfig(avahi-compat-libdns_sd)
BuildRequires:	pkgconfig(gmock)
BuildRequires:	pkgconfig(gtest)
BuildRequires:	pkgconfig(libcurl)
BuildRequires:	pkgconfig(openssl)
BuildRequires:	pkgconfig(x11)
BuildRequires:	pkgconfig(xtst)
BuildRequires:	pkgconfig(Qt5Core)
BuildRequires:	pkgconfig(Qt5Gui)
BuildRequires:	pkgconfig(Qt5Network)
BuildRequires:	pkgconfig(Qt5Widgets)

%description
Barrier is software that mimics the functionality of a KVM switch, which
historically would allow you to use a single keyboard and mouse to control
multiple computers by physically turning a dial on the box to switch the
machine you're controlling at any given moment. Barrier does this in
software, allowing you to tell it which machine to control by moving your
mouse to the edge of the screen, or by using a keypress to switch focus to
a different system.

Barrier was forked from Symless's Synergy 1.9 codebase. Synergy was a
commercialized reimplementation of the original CosmoSynergy written by
Chris Schoeneman.

%files
%license LICENSE
%doc ChangeLog res/Readme.txt doc/barrier.conf.example*
%{_bindir}/%{name}*
%{_iconsdir}/hicolor/scalable/apps/%{name}.svg
%{_datadir}/applications/%{name}.desktop
%{_metainfodir}/%{name}.appdata.xml
%{_mandir}/man1/%{name}*.1*

#----------------------------------------------------------------------------

%prep
%autosetup -p1

# prepare gulrak-filesystem
tar -xf %{S:1}
cp -r filesystem-%{gulrak_version}/include/ ext/gulrak-filesystem/

%build
%cmake \
	-DBARRIER_BUILD_GUI:BOOL=ON \
	-DBARRIER_BUILD_INSTALLER:BOOL=OFF \
	-DBARRIER_BUILD_TESTS:BOOL=OFF \
	-DBARRIER_USE_EXTERNAL_GTEST:BOOL=ON \
	-DBARRIER_VERSION_STAGE:STRING=%{_vendor}
%cmake_build

%install
%cmake_install

# man
install -D -p -m 0644 doc/barrierc.1 %{buildroot}%{_mandir}/man1/barrierc.1
install -D -p -m 0644 doc/barriers.1 %{buildroot}%{_mandir}/man1/barriers.1

# icons
install -D -p -m 0644 res/%{name}.svg %{buildroot}%{_iconsdir}/hicolor/scalable/apps/%{name}.svg

# .desktop
install -D -p -m 0644 res/barrier.desktop %{buildroot}%{_datadir}/applications/barrier.desktop

# .appstream
install -dm 0755 %{buildroot}%{_metainfodir}
cat <<END> %{buildroot}%{_metainfodir}/%{name}.appdata.xml
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2020 Ding-Yi Chen <dchen@redhat.com> -->
<component type="desktop-application">
  <id>%{name}</id>
  <metadata_license>FSFAP</metadata_license>
  <project_license>GPLv2</project_license>
  <name>%{name}</name>
  <summary>%{summary}</summary>

  <description>
    <p>%{description}</p>
  </description>

  <launchable type="desktop-id">%{name}.desktop</launchable>

  <url type="homepage">%{url}</url>

  <provides>
    <binary>barrier</binary>
    <binary>barrierc</binary>
    <binary>barriers</binary>
  </provides>

  <releases>
    <release version="%{version}" date="2021-11-02" />
  </releases>
</component>
END



%changelog
* Fri May 26 2023 daviddavid <daviddavid> 2.4.0-1.mga9
+ Revision: 1958011
- initial package barrier (mga#30255)