https://bugzilla.redhat.com/show_bug.cgi?id=2567282

Nikita Sizikov <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]



--- Comment #1 from Nikita Sizikov <[email protected]> ---
Unofficial review: I'm not a packager yet (sponsorship request:
https://forge.fedoraproject.org/packaging/sponsors/issues/805), so this
can't count as the formal review. I hope the notes are useful anyway.

I ran fedora-review 0.12.0 in mock (fedora-rawhide-x86_64), then went
through the spec, the patches and the 0.7.5 sources by hand. The package
builds, installs and works. Findings below, most important first.

Issues
======

1. License tag: the LGPL part looks inaccurate.
   The spec says "icons/* are under LGPLv2.1+", but README.icons says the
   KDE Crystal (LGPL) icons were all the GUI icons *except*
   start/stop/chapter/bookmark, and those four are exactly the ones in
   icons/ (play, stop, chapter, bookmark).
   The 0.7.5 tarball contains no Crystal icons any more: the only images
   are dvbcut.svg/.ico and icons/{bookmark,chapter,play,stop}.{png,svgz}.
   src/dvbcutbase.ui still names image0..image13, but there is no
   <images> section behind them, and src/dvbcut.cpp:370ff sets those
   action icons at runtime with QIcon::fromTheme() and QStyle fallbacks.
   debian/copyright covers "Files: *" as GPL-2+. So I think
   License: GPL-2.0-or-later alone is correct. Could you double-check?
   (Side note: the Crystal notice says "version 2.1 of the License" with
   no "or later", so it would have been LGPL-2.1-only anyway.)

2. Missing BuildRequires: make.
   %make_build and %make_install need make. In my build it only came in
   through other packages' dependencies. Per the Build-Time Dependencies
   section, you SHOULD NOT assume other packages are present, because
   "anything brought into the buildroot by the build system can change
   over time".

3. Patches: upstream status, and a bug in dvbcut-use_pkgconfig.patch.
   All three patches are marked PATCH-FIX-OPENSUSE, and none of them is
   in upstream master yet: configure.ac still uses AC_CHECK_LIB, and
   dvbcut.desktop.in still has the absolute Icon= path. Per
   PatchUpstreamStatus, each patch SHOULD carry an upstream-status
   comment. Maybe submit them to github.com/bernhardu/dvbcut-deb?
   Before doing that, note that the pkgconfig patch checks the wrong
   module:
       PKG_CHECK_MODULES(swscale, libavutil, ...
   That should be libswscale. As it is, the swscale check passes whenever
   libavutil exists. The build is fine only because libswscale is
   BuildRequired.

4. Stale comment (spec line 10): "use sh dvbcut-snapshot.sh to create
   the archive". Source0 is now the GitHub tag archive, so the comment
   can go.

5. %description still says "For MPEG video playback dvbcut can use
   Mplayer if available", but MPlayer isn't in Fedora (your changelog
   drops the weak dependency for that reason). Consider rewording or
   dropping that sentence.

Suggestions (non-blocking)
==========================

- The Qt translations (/usr/share/dvbcut/dvbcut_{cs,de}.qm) are not
  %lang-tagged. "%find_lang %{name} --with-qt" would handle them.
  %{_datadir}/%{name}/ is currently listed as a whole, so %files would
  need adjusting to avoid listing those .qm files twice.
- The AppData guidelines say a GUI app SHOULD install a .metainfo.xml.
  Upstream doesn't ship one.
- Nits: "BuildRequires: pkgconfig" is redundant next to the pkgconfig()
  BRs. "BuildRequires: hicolor-icon-theme" doesn't seem to be needed at
  build time. The Requires: is right.

Upstream bug spotted (not a packaging blocker)
==============================================

The only compiler warning in the build is
    mpgfile.cpp:864:9: warning: 'free' called on unallocated object
    'buffer' [-Wfree-nonheap-object]
It's genuine. In mpgfile::readfile(std::string, uint8_t **buffer):
    854:  *buffer = (uint8_t*) malloc(sizeof(uint8_t)*lSize);
    855:  if (buffer == NULL) {          // should be *buffer
    ...
    864:    free(buffer);                // should be free(*buffer)
On a short read, the function frees the address of the caller's pointer
variable instead of the malloc'd block. That is undefined behaviour,
typically an abort with "free(): invalid pointer". The malloc failure
check at 855 is also a no-op. The function is called from
tsfile.cpp:385 (bookmark import), and upstream master still has the
same code. It might be worth reporting upstream, or carrying a
two-line patch.

Verified / OK
=============

- Functional test: I made a 12 s MPEG-TS (MPEG-2 720x576 + AC-3) with
  ffmpeg, then ran the installed package in the mock root:
      QT_QPA_PLATFORM=offscreen dvbcut -batch -cut 50,200 \
          -exp /tmp/out.mpg /tmp/test.ts
  It exited 0. ffprobe shows out.mpg as an MPEG-PS with mpeg2video
  720x576, ac3 and DVD nav packets, 5.92 s long (frames 50-200 at
  25 fps). So export works with Fedora's ffmpeg-free; the mpeg2video
  encoder and decoder are enabled there.
- Source0 matches upstream (SHA256 76c34564...fa8b85). 0.7.5 is the
  latest tag.
- Fedora compiler/linker flags are applied (-O2 -flto=auto ...
  -D_FORTIFY_SOURCE=3, -z relro -z now). There is a single compiler
  warning, and it's a real upstream bug (see below).
- import/ (portability shims: Cygwin's sys/mman.h, plus realpath/
  asprintf replacements) is not compiled; build.log shows no
  references to it.
- desktop-file-install is used. Requires: hicolor-icon-theme is
  correct.
- /usr/share/mime/packages is owned by shared-mime-info, which is what
  makes the MIME XML useful in the first place, so I'd count it as part
  of the natural dependency chain. The fedora-review note is fine to
  ignore.
- Upgrade path from RPM Fusion: 0.7.4-12 < 0.7.5-1, and the name is the
  same, so no Obsoletes are needed.
- %make_install already passes INSTALL='install -p', so timestamps are
  preserved.
- rpmlint: incorrect-fsf-address in COPYING and README.icons is an
  upstream issue. no-%check-section is expected, since there is no test
  suite upstream.

Rpmlint
-------
dvbcut.spec: W: no-%check-section
dvbcut.x86_64: E: incorrect-fsf-address /usr/share/doc/dvbcut/README.icons
dvbcut.x86_64: E: incorrect-fsf-address /usr/share/licenses/dvbcut/COPYING
 2 packages and 0 specfiles checked; 2 errors, 1 warnings, 7 filtered, 2
badness
debuginfo: 0 errors, 0 warnings

I used fedora-review and an AI assistant to go through the checklist, and
I verified every point above myself.


-- 
You are receiving this mail because:
You are always notified about changes to this product and component
You are on the CC list for the bug.
https://bugzilla.redhat.com/show_bug.cgi?id=2567282

Report this comment as SPAM: 
https://bugzilla.redhat.com/enter_bug.cgi?product=Bugzilla&format=report-spam&short_desc=Report%20of%20Bug%202567282%23c1

-- 
_______________________________________________
package-review mailing list -- [email protected]
To unsubscribe send an email to [email protected]
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/[email protected]
Do not reply to spam, report it: 
https://forge.fedoraproject.org/infra/tickets/issues/new

Reply via email to