Skip to content
Snippets Groups Projects

abuild: add code for option extract-dir

Closed Thermi requested to merge Thermi/abuild:option-extract-dir into master

It makes the unpack function extract to a file name dependent directory. It is useful to enable maintainer to work with archives that contain all files and directories in the root directory of the archives directly, instead of a subdirectory.

That'd enable me to remove all the custom unpack functions from the kopano-* packages. Other packages use them for the purpose of extracting to specific dirs, too.

The following packages do that:

  • testing/font-fantasque-sans
  • non-free/chromium-widevine
  • main/docbook-xml

From a first glance, adding support for that directly would enable removal of the custom unpack function from those packages.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Thermi mentioned in issue #10039

    mentioned in issue #10039

  • I'm not sure I understand why it is a problem extracting the files directly to srcdir? The example packages you mention seems to handle that just fine?

    What about fixing this upstream, so they provide tarballs with files in a filename dependant subdirectory already?

    Also, why do you strip the version number?

    The whole thing feels hackish and wrong.

    1. Because you can't figure out afterwards which files belong to which archive because they all extract to srcdir without creating their per-archive directories. So it's all jumbled together. No change to figure it out afterwards or to avoid file name collisions effectively mixing it all up.

    2. I'm not upstream and you're not upstream.

    3. Works fine without preserving it.

    4. So you want custom unpack functions in packages? Because that's the alternative. And that's even worse.

  • Also to 3) Got an easy way to only strip the extension, without adding more lines?

  • Contributor

    So you want custom unpack functions in packages? Because that's the alternative. And that's even worse.

    yes, that works fine and there's no issue with a custom unpack for these (very few) cases. all you need is to make the archives with the contents you don't want extracted e.g. .tar.gz.noauto, and then use default_unpack and one additional line to manually unpack the 'bad' archive anywhere you want.

  • A deleted user closed

    closed

Please register or sign in to reply
Loading