]> git.donarmstrong.com Git - debhelper.git/blobdiff - Debian/Debhelper/Dh_Buildsystems.pm
cmake: Pass CPPFLAGS in CFLAGS. Closes: #668813 Thanks, Simon Ruderich for the patch...
[debhelper.git] / Debian / Debhelper / Dh_Buildsystems.pm
index 9c3fc0597c969b6639d8355c46a2ad21b266584d..0a51a4d228ea6fa81cf5df75d8640d8e82f358a1 100644 (file)
@@ -28,6 +28,7 @@ our @BUILDSYSTEMS = (
        "cmake",
        "ant",
        "qmake",
+       "qmake_qt4",
 );
 
 my $opt_buildsys;
@@ -166,19 +167,12 @@ sub buildsystems_init {
 sub set_parallel {
        my $max=shift;
 
-       $opt_parallel=1;
-
-       if (exists $ENV{DEB_BUILD_OPTIONS}) {
-               # Get number of processes from parallel=n tag limiting it
-               # with $max if needed
-               foreach my $opt (split(/\s+/, $ENV{DEB_BUILD_OPTIONS})) {
-                       if ($opt =~ /^parallel=(-?\d+)$/) {
-                               $opt_parallel = $1;
-                               if ($max > 0 && $opt_parallel > $max) {
-                                       $opt_parallel = $max;
-                               }
-                       }
-               }
+       # Get number of processes from parallel=n option, limiting it
+       # with $max if needed
+       $opt_parallel=get_buildoption("parallel") || 1;
+
+       if ($max > 0 && $opt_parallel > $max) {
+               $opt_parallel = $max;
        }
 }