Hi,

thanks for contributing! Overall looks good. Some comments below.

On 11.07.2023 10:29, Mateusz Kocielski wrote:
> Hi there,
> 
>  I've prepared spec file to build i3lock [1]. This is my first spec file, so
> please review it carefully. The software requires suid to be able to verify
> password provided by user.
> 
> [1] - https://i3wm.org/i3lock/
> 
>  Thanks,
>  Mateusz

> Summary:      improved screen locker

Start summary with capital letter unless it starts with a name that goes
lower case.

> Name:         i3lock
> Version:      2.14.1
> Release:      1
> License:      BSD
> Group:                Applications
> Source0:      https://i3wm.org/i3lock/%{name}-%{version}.tar.xz
> # Source0-md5:        33d4bc8256a1566fbac911e405e53fdd
> URL:          https://i3wm.org/i3lock/
> BuildRequires:        cairo-devel

cairo is required with version at least 1.14.4.

> BuildRequires:        libev-devel
> BuildRequires:        libxcb-devel
> BuildRequires:        meson >= 0.45.0
> BuildRequires:        ninja
> BuildRequires:        pam-devel
> BuildRequires:        pkgconfig
> BuildRequires:        xcb-util-devel
> BuildRequires:        xcb-util-image-devel
> BuildRequires:        xcb-util-xrm-devel
> BuildRequires:        xorg-lib-libX11-devel

Can't see direct dependency on xorg-lib-libX11-devel.

> BuildRequires:        xorg-lib-libxkbcommon-x11-devel
> BuildRequires:  rpmbuild(macros) >= 1.726

Keep it sorted and use tabs instead (run adapter script).

> Requires:     libxcb
> Requires:     pam
> Requires:     xcb-util
> Requires:     xcb-util-image
> Requires:     xcb-util-xrm
> Requires:     xorg-lib-libxkbcommon-x11

No need to give explicit Requires: for libraries linked to main binary
unless specific version is required (like in case of cair).

> BuildRoot:    %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
> 
> %description
> Minimalist screen locker based on slock.
> 
> %prep
> %setup -q
> 
> %build
> %meson build
> %ninja_build -C build

For additional BuildRequires: check:

http://cvs.pld-linux.org/cgi-bin/viewvc.cgi/cvs/PLD-doc/BuildRequires.txt
> 
> %install
> rm -rf $RPM_BUILD_ROOT
> %ninja_install -C build
> 
> %clean
> rm -rf $RPM_BUILD_ROOT
> 
> %files
> %defattr(644,root,root,755)

LICENSE states it needs to be distributed with binaries so include it in
%doc.

> %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/i3lock
> %attr(4755,root,wheel) %{_bindir}/i3lock

That's peculiar -- what screen locker needs suid bit for? Why wheel
group?

> %{_mandir}/man1/i3lock.1*

> _______________________________________________
> pld-devel-en mailing list
> pld-devel-en@lists.pld-linux.org
> http://lists.pld-linux.org/mailman/listinfo/pld-devel-en

_______________________________________________
pld-devel-en mailing list
pld-devel-en@lists.pld-linux.org
http://lists.pld-linux.org/mailman/listinfo/pld-devel-en

Reply via email to