pkg_create_dbgsym doesn't cope with multi-line Depends, Suggests, etc.
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
pkg-create-dbgsym (Ubuntu) |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Binary package hint: pkg-create-dbgsym
The mplayer build fails during the creation of the -dbgsym packages with the following error:
pkg-gencontrol: warning: unknown substitution variable ${shlibs:Depends}
dpkg-gencontrol: warning: unknown substitution variable ${misc:Depends}
dpkg-gencontrol: warning: unknown substitution variable ${shlibs:Depends}
dpkg-gencontrol: warning: unknown substitution variable ${misc:Depends}
dpkg-gencontrol: internal error: field Section has blank lines >video
ttf-freefont,
netselect | fping,
bzip2,
fontconfig
,
mplayer-doc (<< 1.0~rc3+
Error: parsed ddeb section or priority is empty
After a look at the pkg_create_dbgsym code this happens because it doesn't filter out multi-line Depends, Suggests, etc. properly.
An example from mplayer's debian/control:
Package: mplayer-nogui
Architecture: any
Section: video
Suggests: mplayer-doc,
netselect | fping,
bzip2,
Depends: debconf | debconf-2.0,
Replaces: mplayer (<< 1.0~rc3+
Description: movie player for Unix-like systems
MPlayer plays most MPEG, VOB, AVI, Ogg/OGM, VIVO,
[...]
Calling "perl -p000 -e 's/^(?:
Package: mplayer-nogui
Architecture: any
Section: video
ttf-freefont,
netselect | fping,
bzip2,
fontconfig
${shlibs:
${misc:Depends}
mplayer-doc (<< 1.0~rc3+
Description: movie player for Unix-like systems
MPlayer plays most MPEG, VOB, AVI, Ogg/OGM, VIVO,
[...]
Looking at the regex the negative look-ahead assertation "(?! )" should probably look for all white-space and not only " ".
Using "perl -p000 -e 's/^(?: Pre-Depends| Depends| Recommends| Suggests| Conflicts| Provides| Replaces| Breaks| Essential) :.*?\n( ?!\s)// msg' debian/control" will result in
Package: mplayer-nogui
Architecture: any
Section: video
Description: movie player for Unix-like systems
MPlayer plays most MPEG, VOB, AVI, Ogg/OGM, VIVO,
[...]
which is probably the expected behaviour.