Description of problem: Sadly, it appears that R2spec is silently losing version information. Version-Release number of selected component (if applicable): R2spec-2.5.2 How reproducible: $ R2spec --cran -u http://cran.at.r-project.org/src/contrib/chron_2.3-30.tar.gz Steps to Reproduce: reviewing the spec file it yields, the '-30' information is lost %define packname chron Name: R-%{packname} Version: 2.3 Release: 1%{?dist} Summary: Chronological objects which can handle dates and times Group: Applications/Engineering License: GPL-2 URL: http://cran.r-project.org/web/packages/chron/index.html Source0: http://cran.at.r-project.org/src/contrib/chron_2.3-30.tar.gz ... Actual results: I think probably I expected two things: 1. not to lose information 2. some reasonable 'flattening' similar to: Version: 2.3-30 => 2.3_30 Expected results: As above ... I am sorry to expose this, as I have packaged a lot of files without noticing it, and I need to audit and fix them ;) Additional info:
To me this sounds like not a bug, but I've asked the question on the fedora-r-devel mailing list: https://www.redhat.com/archives/fedora-r-devel-list/2009-May/msg00000.html and I am open for discussion :)
Reading further in an example as to how Red Hat's internal release engineering does its packaging, I find (unhappily): %define packname DBI %define packrel 4 Name: R-%{packname} Version: 0.2 Release: 3%{?dist} Source0: ftp://cran.r-project.org/pub/R/contrib/main/%{packname}_%{version}-%{packrel}.tar.gz License: LGPLv2+ URL: http://cran.r-project.org/web/packages/DBI/index.html Group: Applications/Engineering Summary: Database interface module for R ------------------ I think their use of the '%packrel' construct into the Release space represents an error in approach [it also conceals the upstream version information, which version information sadly contains the '-']. This is because mis-packagings cannot be 'corrected' by bumping the Release tag, and issuing a new offering, which RPM using perhaps YUM, can use the customary RPMVERCMP rules to drop in a replacement. A workaround may be to add the 'local packagers' release AFTER a separator in the '${dist}' tag ... something like this: Release: ${packrel}%{?dist}.%{localrel} This may require putting forward a proposed R packager's standard for Fedora, to merge your approach in R2spec, and Red Hat release engineering's differing approaches. -- Russ herrold
I think this issue should be brought to the fedora-devel list for further discussion. Could you start the discussion there ?
I wanted to complete my packaging run in cran toward a few targets I mentioned in my blog a while back first, to get 'seasoned' on where the remaining issues in packaging in that archive were. I also have a 'circular dependencies' solution method, to outline as well; and an automated 'prospector' like builder to handle version bumps in R automatically in process. I will perhaps add it there, or simply send you patches to implement my variant of 'Version:' mungeing with a command line switch; the circular dependencies solution also will be submitted with a different command line switch Curiously, the 'doc' directory, and the NEWS file are very often missing in CRAN packages, and I would default R2spec to omit including these by default. Let me do some more development first, before floating this upstream, to make sure I understand where most of the the problems are. ;) -- Russ herrold
Base on the discussion on Fedora-r-devel we decided that for the R package any '-' in the version can be replace to '.' R2spec therefore now replaces the '-' to '.'