X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=doc%2FPROGRAMMING;h=bcf1c13caaadfdc16d168ced6afabda9a9d9f0c1;hb=9d07928d91124eb723daf79160259cdbb4da9ca3;hp=5f236ebdc4983f090803165ae8c38cc0ee6e4e0b;hpb=1089dbaaa1ccc4b7bade09555e67ae126bf776f2;p=debhelper.git diff --git a/doc/PROGRAMMING b/doc/PROGRAMMING index 5f236eb..bcf1c13 100644 --- a/doc/PROGRAMMING +++ b/doc/PROGRAMMING @@ -197,7 +197,7 @@ autoscript($package, $scriptname, $snippetname, $sedcommands) - script to add to - filename of snippet - sed commands to run on the snippet. Ie, s/#PACKAGE#/$PACKAGE/ - (optional) + (optional) Note: Passed to the shell inside double quotes. This command automatically adds shell script snippets to a debian maintainer script (like the postinst or prerm). Note that in v6 mode and up, the snippets are added in reverse @@ -216,9 +216,10 @@ addsubstvar($package, $substvar, $deppackage, $verinfo, $remove) - version info for the package (optional) (ie: ">= 1.1") - if this last parameter is passed, the thing that would be added is removed instead. This can be useful to ensure that a debhelper - command is idempotent. Note that without this parameter, if you - call the function twice with the same values it will only add one - item to the substvars file. + command is idempotent. (However, we generally don't bother, + and rely on the user calling dh_prep.) Note that without this + parameter, if you call the function twice with the same values it + will only add one item to the substvars file. delsubstvar($package, $substvar) This function removes the entire line for the substvar from the package's shlibs file. @@ -232,9 +233,11 @@ udeb_filename($package) Returns the filename of the udeb package. getpackages($type) Returns a list of packages in the control file. - Must pass "arch" or "indep" or "same" to specify arch-dependent or - -independent or same arch packages. If nothing is specified, returns all - packages. + Pass "arch" or "indep" to specify arch-dependent or + -independent. If nothing is specified, returns all + packages (including packages that are not built + for this architecture). Pass "both" to get the union + of "arch" and "indep" packages. As a side effect, populates %package_arches and %package_types with the types of all packages (not only those returned). inhibit_log()