]> git.donarmstrong.com Git - cran2deb.git/blobdiff - trunk/R/debianpkg.R
rip bundles
[cran2deb.git] / trunk / R / debianpkg.R
index 22bb5b475db10babe094ceea4df65c20abaca02e..e3656d31e8ae284133600aef506fe2db0a9ac618 100644 (file)
@@ -24,10 +24,10 @@ generate_changelog <- function(pkg) {
 generate_changelog_entry <- function(build, changelog) {
     # TODO: should say 'New upstream release' when necessary
     debversion <- version_new(build$r_version, build$deb_revision, build$deb_epoch)
-    cat(paste(paste(build$srcname,' (',debversion,') unstable; urgency=low',sep='')
+    cat(paste(paste(build$srcname,' (',debversion,') testing; urgency=low',sep='')
              ,'' ,paste('  * cran2deb ',build$scm_revision
                        ,' with DB version ',as.integer(build$db_version),'.',sep='')
-             ,'',paste(' --',maintainer,'',build$date_stamp)
+             ,'',paste(' --',maintainer,'',format(build$date_stamp,'%a, %d %b %Y %H:%M:%S %z'))
              ,'','','',sep='\n'),file=changelog, append=TRUE)
 }
 
@@ -109,18 +109,7 @@ prepare_new_debian <- function(pkg,extra_deps) {
     # says: ``The sources and headers for the compiled code are in src, plus
     # optionally file Makevars or Makefile.'' It seems unlikely that
     # architecture independent code would end up here.
-    if (pkg$is_bundle) {
-        # if it's a bundle, check each of the packages
-        pkg$archdep = F
-        for (pkgname in r_bundle_contains(pkg$name)) {
-            pkg$archdep = file.exists(file.path(pkg$path,pkgname,'src'))
-            if (pkg$archdep) {
-                break
-            }
-        }
-    } else {
-        pkg$archdep = file.exists(file.path(pkg$path,'src'))
-    }
+    pkg$archdep = file.exists(file.path(pkg$path,'src'))
     pkg$arch <- 'all'
     if (pkg$archdep) {
         pkg$arch <- host_arch()
@@ -129,10 +118,13 @@ prepare_new_debian <- function(pkg,extra_deps) {
     pkg$license <- accept_license(pkg)
     pkg$depends <- get_dependencies(pkg,extra_deps)
     apply_patches(pkg)
+    generate_lintian(pkg)
     generate_changelog(pkg)
     generate_rules(pkg)
     generate_copyright(pkg)
     generate_control(pkg)
+    ## debdir <- file.path(pkg$path,'debian')
+    ## system(paste("ls ", debdir, "; ls -l ", debdir, "/patches/*", sep=""))
 
     # convert text to utf8 (who knows what the original character set is --
     # let's hope iconv DTRT).