more sanity checks

This commit is contained in:
joey
2000-04-22 01:58:31 +00:00
parent d50d1982d5
commit 624306abba
2 changed files with 8 additions and 0 deletions

2
TODO
View File

@@ -1 +1,3 @@
* handling postinst script when converting to/from .slp packages. * handling postinst script when converting to/from .slp packages.
* patches

6
alien
View File

@@ -279,6 +279,12 @@ if (! %destformats) {
} }
# A few sanity checks. # A few sanity checks.
if (($generate || $single) && $install) {
die "You can not use --generate or --single with --install.\n";
}
if (($generate || $single) && keys %destformats > 1) {
die "--generate and --single may noly be used when converting to a single format.\n";
}
if ($patchfile && ! -f $patchfile) { if ($patchfile && ! -f $patchfile) {
die "Specified patch file, \"$patchfile\" cannot be found.\n"; die "Specified patch file, \"$patchfile\" cannot be found.\n";
} }