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. π
PackageArchitectureSectionPriorityEssentialDependsRecommendsSuggestsEnhancesReplacesPre_DependsConflictsBreaksProvidesBuilt_UsingMulti_ArchDescriptionPackage_TypeBuild_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 withPre-Dependsand expect the accessor to be named that. it'sPre_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_descriptionlong_description
setting them transparently modifies Description. sneaky? no. efficient. β¨
but listen, this part matters, don't skip it:
- the value of
long_descriptionis "unmangled" β meaning no leading spaces, and empty lines are actually empty. Descriptionon the other hand is just as it looks in a regulardebian/controlfile β 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 fromDebian::Control::StanzaDebian::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 & LICENSE π
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
- ubuntu stonking: libdebian-source-perl 0.133 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms