File slock.spec of Package slock

#
# spec file for package slock
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           slock
Version:        1.4
Release:        0
Summary:        Simple X lock
License:        MIT
Group:          System/X11/Utilities
Url:            http://tools.suckless.org/slock
Source:         %{name}-%{version}.tar.gz
Patch0:         config.mk.patch
# Gentoo patch
Patch1:         slock-1.4-dontdieonme.patch
BuildRequires:  pkgconfig
BuildRequires:  pkgconfig(x11)
BuildRequires:  pkgconfig(xext)
BuildRequires:  pkgconfig(xrandr)
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
Simple lock for X.

%prep
%setup -q
%patch0 -p1
%patch1 -p1

%build
%{suckless_config}
sed -i '/^CFLAGS = /s@$@ -fPIE ${CPPFLAGS}@' config.mk
make %{?_smp_mflags}

%install
%make_install

%files
%defattr(-,root,root)
%doc README LICENSE
%{_bindir}/*
%{_mandir}/man1/slock.1%{ext_man}

%changelog
openSUSE Build Service is sponsored by