[PLEASE WRITE IN ENGLISH ON OPENPKG MAILING LISTS]

On Mon, Dec 30, 2002, Michael van Elst wrote:

> >   Log:
> >     support new %option(s) stuff
> [...]
> Der Index ist jetzt fehlerhaft, weil du die einfache spec-Syntax geaendert
> hast, die der Index-Parser nur versteht.

I've now tried to fix "openpkg index" so it understands again the
options by parsing the "%option" lines.

> Die Syntax von %options gefaellt mir nicht sehr, denn %description ist
> freitext und sollte daher auch nur als solcher betrachtet werden. Eine
> fehlende (optionale!) Einrueckung und der Parser funktioniert nicht mehr.
>
> Die Syntax von %description in einem .spec-file unterscheidet sich jetzt
> von der die rpm ausgibt. Es ist unmoeglich die Description in einem
> specfile alleine zu parsen.

There is no need to parse "%options" in %description if you parse a
.spec file directly. If you parse directly, you can just look for
the "%option" directives outside %description". And if you parse the
%description output of RPM you again just have to look for the "%option"
directives again. That's the reason why "%options" output the options
again in the same "%option" syntax.

So, forget "%description" and "%options": In both cases you just look
for "%option"!

> Die Syntax von %option ist reiner Zucker.

It is just syntactic sugar, of course. But the syntactic sugar is
_reduced_ now. That was the goal. And with "%options" the redundancy is
gone now, too.
                                       Ralf S. Engelschall
                                       [EMAIL PROTECTED]
______________________________________________________________________
The OpenPKG Project                                    www.openpkg.org
Developer Communication List                   [EMAIL PROTECTED]

Reply via email to