]> git.donarmstrong.com Git - debhelper.git/blobdiff - Debian/Debhelper/Dh_Lib.pm
dpkg-buildflags is only used to set environment in v9
[debhelper.git] / Debian / Debhelper / Dh_Lib.pm
index 0c779d1f944bfea939a3d4829f6504530959d3ad..5a7c3e4a696172de077ba3f387241d0fa162517b 100644 (file)
@@ -903,13 +903,13 @@ sub cross_command {
 # Sets environment variables from dpkg-buildflags. Avoids changing
 # any existing environment variables.
 sub set_buildflags {
-       # optimisation
-       return if $ENV{DH_INTERNAL_BUILDFLAGS};
+       return if $ENV{DH_INTERNAL_BUILDFLAGS} || compat(8);
        $ENV{DH_INTERNAL_BUILDFLAGS}=1;
 
        eval "use Dpkg::BuildFlags";
        if ($@) {
                warning "unable to load build flags: $@";
+               return;
        }
 
        my $buildflags = Dpkg::BuildFlags->new();