Version 2 (modified by broder, 14 years ago) (diff) |
---|
From time to time, we find that modifying configuration files isn't enough to enact the changes we need to build a Debathena system. In cases like these, we need to modify the packages themselves that we're configuring. In the past, some reasons we've needed to modify upstream-distributed packages include:
- Enabling krb4 support in evolution-data-server or alpine before the mail servers supported krb5 authentication.
- Modifying the lprng package, renaming commands like lpr to mit-lpr so they don't conflict with the cups-bsd package.
One of the great strengths of the config-package-dev development model is that mechanisms such as DEB_TRANSFORM_FILES allow you express just your changes, as opposed to the entire result. The Debathenificator framework was designed to serve this purpose for modifying whole packages.
The Debathenificator framework itself lives in source:/trunk/debathena/third/common, and individual Debathenified packages live in other subdirectories of source:/trunk/debathena/third.
A consumer of the Debathenificator is a single shell script, possibly with some ancillary files. The script is called debathenify-PACKAGE, where PACKAGE is the package being debathenified (c.f. source:/trunk/debathena/third/lprng/debathenify-lprng). Each debathenify script MUST do 4 things: set a name variable, set a daversionappend variable, define a hack_package shell function, and source ../common/debathenificator.sh. Here is a basic example:
#!/bin/sh set -e name=lprng daversionappend=debathena1 hack_package() { add_changelog "Rebuild for Evan's amusement." } . ../common/debathenificator.sh