#49 spectool fails to parse complex source declarations
Closed by decathorpe. Opened by nim.

The following spec files build perfectly in koji (meaning that rpmbuild -bs parses them fine in F31, F32 and F33) but fail parsing in spectool.

Something is wrong in the spectool parsing code but I’ve no idea where;

  1. simple case that parses fine:
    https://koji.fedoraproject.org/koji/buildinfo?buildID=1469199

  2. More complex cases (using the same macros!) that fail in spectool:
    https://koji.fedoraproject.org/koji/buildinfo?buildID=1470153
    https://koji.fedoraproject.org/koji/buildinfo?buildID=1475692

It seems there is a broken assumption in the spectool parser, that triggers on some specs (but not others), and is not present in the parsing code used by rpmbuild

Sometimes it is possible to workaround spectool limitations by running rpmspec -P on the original specfile and feeding the result to spectool, but that’s quite inconvenient
https://koji.fedoraproject.org/koji/buildinfo?buildID=1470196

@pnemade I think you may be hitting some form of the above


The spectool implementation has been completely replaced. Please try the new implementation and see if it solves your problems!

May be related to https://pagure.io/rpmdevtools/issue/67

The spectool implementation has been completely replaced with version 9 / for fedora 33. It's now using rpm itself to parse .spec files, so if spectool has issues parsing a .spec file, rpm itself will choke on it too.

Closing this ticket due to inactivity and because the problem is most likely solved.

Metadata Update from @decathorpe:
- Issue status updated to: Closed (was: Open)

Metadata