-my $sequence;
-if (! compat(7)) {
- # From v8, the sequence is the very first parameter.
- $sequence=shift @ARGV_orig;
- if ($sequence=~/^-/) {
- error "Unknown sequence $sequence (options should not come before the sequence)";
- }
-}
-else {
- # Before v8, the sequence could be at any position in the parameters,
- # so was what was left after parsing.
- $sequence=shift;
- if (defined $sequence) {
- @ARGV_orig=grep { $_ ne $sequence } @ARGV_orig;
- }
-}
-if (! defined $sequence) {
- error "specify a sequence to run";
-}
-# make -B causes the rules file to be run as a target.
-# Also support completly empty override targets.
-# Note: it's not safe to use rules_explicit_target before this check.
-if ($sequence eq 'debian/rules' ||
- $sequence =~ /^override_dh_/) {
- exit 0;
-}
-elsif (! exists $sequences{$sequence}) {