Debian...:Binary(3pm)

πŸ’– Debian...:Binary(3pm) β€” the User Contributed Perl Documentation era πŸ’–

okay bestie, sit down, hydrate, because we're talking about Debian::Control::Stanza::Binary, and it is so much less scary than it sounds. it lives in the User Contributed Perl Documentation section of the manual, and it's lowkey one of the most useful little Perl modules in the Debian toolchain. periodt.


✨ NAME ✨

Debian::Control::Stanza::Binary β€” it's the binary stanza of a Debian source package control file, babes. that's the vibe. that's the whole vibe. πŸ’…


🌸 SYNOPSIS 🌸

my $bin = Debian::Control::Stanza::Binary->new(\%data);
print $bin;                         # auto-stringification
print $bin->Depends;                # Debian::Dependencies object

look at her. three lines. she's thriving. the way that print $bin just... works, because she stringifies herself? no cap, iconic behavior. 🫢


πŸ¦‹ DESCRIPTION πŸ¦‹

so Debian::Control::Stanza::Binary is your girl for representation and manipulation of the Package: stanza of Debian source package control files, and she does it all in an object-oriented way. very main character. very demure.

and when you put her in string context? she just converts herself to a textual representation. no extra steps, no drama, no ->as_string pleading. she knows what to do. ✨


πŸŽ€ FIELDS πŸŽ€

here's the full roster of fields our queen supports for binary stanzas, bestie. and if you wanna know what each one actually means, go read the section named "Source package control files -- debian/control" in the Debian Policy Manual at https://www.debian.org/doc/debian-policy/ β€” that's the homework, i don't make the rules. πŸ“š

  • Package
  • Architecture
  • Section
  • Priority
  • Essential
  • Depends
  • Recommends
  • Suggests
  • Enhances
  • Replaces
  • Pre_Depends
  • Conflicts
  • Breaks
  • Provides
  • Built_Using
  • Multi_Arch
  • Description
  • Package_Type
  • Build_Profiles
⚠️ tiny but crucial heads up: real control fields can have dashes in their names. this module replaces those dashes with underscores. so don't come at her with Pre-Depends and expect the accessor to be named that. it's Pre_Depends. iykyk. πŸ’…

and now the glow-up section: these fields β€”

Depends, Conflicts Breaks, Recommends, Suggests, Enhances, Replaces, and Pre_Depends

β€” get converted into objects of the Debian::Dependencies class upon construction. she doesn't hand you a sad little string, she hands you a whole object. obsessed. 😭


πŸ’œ Two More Accessors, Because She's Generous πŸ’œ

there are also two extra accessor methods for easier handling of a package's short and long description. bestie behavior fr fr.

  • short_description
  • long_description

setting them transparently modifies Description. sneaky? no. efficient. ✨

but listen, this part matters, don't skip it:

  • the value of long_description is "unmangled" β€” meaning no leading spaces, and empty lines are actually empty.
  • Description on the other hand is just as it looks in a regular debian/control file β€” the long part is indented with a single space, and empty lines are replaced with dots.

so yes, they are different. no, you cannot pretend they're the same. the vibes are distinct. πŸ¦‹


🌈 CONSTRUCTOR 🌈

new

new( { field => value, ... } )

creates a new Debian::Control::Stanza::Binary object, and optionally initializes it with the supplied data. that's it. that's the whole constructor. she's not complicated, she's just effective. πŸ’…


⭐ SEE ALSO ⭐

  • Debian::Control::Stanza::Source β€” inherits most of its functionality from Debian::Control::Stanza
  • Debian::Control::Stanza

(the original text is a little chaotic here β€” it says Debian::Control::Stanza::Source inherits most of its functionality from Debian::Control::Stanza. so yeah. both names. kept them both. 🫢)


Copyright (C) 2009, 2010 Damyan Ivanov dmn@debian.org

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

πŸ›‘ for real though: no warranty. none. zero. she is free software and she comes as-is, so don't come crying to Damyan if something goes sideways. that's the deal. πŸ’–

and that's the whole page, bestie!! this was perl v5.40.1, dated 2026-05-08, filed under Debian...:Binary(3pm) in the User Contributed Perl Documentation. drink some water, go write some control files, and remember β€” you ate. πŸŽ€βœ¨πŸ¦‹πŸ’œ

πŸ“¦ where this page comes from