Fink:Major New Feature Plans:XMLish Source and Patch

From the Fink Wiki
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.


All the *Source*-related fields are a pain to parse, can lead to a messy .info. We could cluster all fields for a given source "item". Easy to add new features (dmalloc wants stronger checksums) without making even more of a top-level fieldname mess.

SourceFile: <<
  Source: http://whatever
  Rename: %n-%v.tar.gz
  MD5: whatever
<<
SourceFile2: <<
  Source: http://whatever
  Rename: %n-%v.tar.gz
  MD5: whatever
<<

Easy to extend to patchfiles (for example, MD5 for patchfiles is a longstanding request).

PatchFile: <<
  Source: foo.patch
  MD5: whatever
<<
PatchFile2: <<
  Source: foo-ssl.patch
  MD5: whatever
<<

The full path to each file would be available as a %-exp and %a would be abolished. That way only files that have passed the MD5 check would be usable.

Extensions

  • vasi:
It would be nice to have a patch folder per package rather than one monster patch.
  • dmacks:
This is already possible (subdirs in %a), and I expect that way would continue to work correctly with the new syntax. One can already even cluster [.info and its .patch] in its own %n subdir.
Make the application of the patches part of the default Patch field instead of an automatic action triggered by the mere presence of the patchfile field (whatever it's called).
  • vasi&dmacks: (on #fink?)
Have a "Substitutions" field in the PatchFile* that lists regexps to apply to the patchfile before applying it to the source tree. That way we can devise a clean solution to the pipefail that plagues the standard "sed ... | patch" approach.
  • We should probably deprecate implicit source around the time we do this. That feature has not been used in 10.4T ever, or 10.3 or 10.2-gcc3.3 in at least a year. This is an annoying special case to support IMO...it means we need hacks like Source:none and Type:nosource instead of just treating "no source listed means there is no Source".