[game-data-packager] 01/01: workaround for real LHa as seen in Fedora/RPMfusion
Alexandre Detiste
detiste-guest at moszumanska.debian.org
Thu Jun 22 18:41:17 UTC 2017
This is an automated email from the git hooks/post-receive script.
detiste-guest pushed a commit to branch master
in repository game-data-packager.
commit 6c7139473ccc6ca73f325795501844dfdc3126b0
Author: Alexandre Detiste <alexandre.detiste at gmail.com>
Date: Thu Jun 22 20:40:15 2017 +0200
workaround for real LHa as seen in Fedora/RPMfusion
[tchet at fedora tmp]$ ln -s resource.1 'resource.1?xxx'
[tchet at fedora tmp]$ lha x resource.1\?xxx id1/pak0.pak licinfo.txt slicnse.txt
LHa: Warning: Checksum error (LHarc file?)
LHa: Fatal error: Unknown level header
[tchet at fedora tmp]$ lha x resource.1 id1/pak0.pak licinfo.txt slicnse.txt
id1/pak0.pak - Melted : oooooooooooooooooooooooooooooooooooooooooooooooooooo
licinfo.txt - Melted : oo
slicnse.txt - Melted : oo
[tchet at fedora tmp]$
---
debian/changelog | 3 +++
game_data_packager/build.py | 10 +++++++++-
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/debian/changelog b/debian/changelog
index 6e1e34c..71b0cb8 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,9 @@ game-data-packager (53) UNRELEASED; urgency=medium
* Support for new languages and versions:
- Update Quake II: The Reckoning (xatrix) to version 2.05 [adetiste]
- Update Quake II: Ground Zero (rogue) to version 2.04 [smcv]
+ * Enhancementsd and bug fixes:
+ - Workaround for command line parsing of LHa decompressor as seen
+ in Wheezy & RPMfusion; users of lhasa were not affected [adetiste]
-- Simon McVittie <smcv at debian.org> Mon, 12 Jun 2017 13:05:12 +0200
diff --git a/game_data_packager/build.py b/game_data_packager/build.py
index 480a135..7080175 100644
--- a/game_data_packager/build.py
+++ b/game_data_packager/build.py
@@ -929,7 +929,15 @@ class PackagingTask(object):
provider_name + '.d')
mkdir_p(tmpdir)
arg = 'x' if self.verbose else 'xq'
- check_call(['lha', arg, os.path.abspath(found_name)] +
+ # workaround for real LHa as seen in Fedora/RPMfusion
+ # that does not like seeing too many '?' or '.' in filenames
+ src = os.path.abspath(found_name)
+ if '?' in src:
+ newsrc = os.path.join(self.get_workdir(),
+ os.path.basename(src).split('?')[0])
+ os.symlink(src, newsrc)
+ src = newsrc
+ check_call(['lha', arg, src] +
list(to_unpack),
cwd=tmpdir)
self.consider_file_or_dir(tmpdir, provider=provider)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/game-data-packager.git
More information about the Pkg-games-commits
mailing list