]> git.donarmstrong.com Git - cran2deb.git/commitdiff
only Build-Depends on dpatch if we have patches (to make lintian happier), note new...
authoredd <edd@edb9625f-4e0d-4859-8d74-9fd3b1da38cb>
Sat, 21 Mar 2009 20:46:32 +0000 (20:46 +0000)
committeredd <edd@edb9625f-4e0d-4859-8d74-9fd3b1da38cb>
Sat, 21 Mar 2009 20:46:32 +0000 (20:46 +0000)
git-svn-id: svn://svn.r-forge.r-project.org/svnroot/cran2deb@210 edb9625f-4e0d-4859-8d74-9fd3b1da38cb

trunk/R/debcontrol.R

index aa8ba8abd00800286f8021d337a57d8d750894c5..34cc6b69f6dc003f4a7c81961f7f63ade3c2d1ea 100644 (file)
@@ -44,7 +44,10 @@ get_dependencies <- function(pkg,extra_deps) {
     depends <- lapply(depends,unique)
 
     # append the Debian dependencies
-    depends$build=c(depends$build,'debhelper (>> 4.1.0)','cdbs','dpatch')
+    depends$build=c(depends$build,'debhelper (>> 4.1.0)','cdbs')
+    if (file.exists(file.path(patch_dir, pkg$name))) {
+        depends$build <- c(depends$build,'dpatch')
+    }
     if (pkg$archdep) {
         depends$bin=c(depends$bin,'${shlibs:Depends}')
     }
@@ -110,7 +113,7 @@ generate_control <- function(pkg) {
     # construct control file
     control = data.frame()
     control[1,'Source'] = pkg$srcname
-    control[1,'Section'] = 'math'
+    control[1,'Section'] = 'math'  ## to be changed to 'gnu-r' once lintian groks it
     control[1,'Priority'] = 'optional'
     control[1,'Maintainer'] = maintainer
     control[1,'Build-Depends'] = paste(pkg$depends$build,collapse=', ')