[game-data-packager] 04/14: avoid packaging "the other game" 's expansion

Simon McVittie smcv at debian.org
Sun Feb 15 15:25:36 UTC 2015


This is an automated email from the git hooks/post-receive script.

smcv pushed a commit to branch master
in repository game-data-packager.

commit 6e9dae7bd502fb31305ed34b6f79e0da304cbc02
Author: Alexandre Detiste <alexandre.detiste at gmail.com>
Date:   Wed Feb 11 17:57:55 2015 +0100

    avoid packaging "the other game" 's expansion
    
    needed for doom3
---
 game_data_packager/__init__.py | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/game_data_packager/__init__.py b/game_data_packager/__init__.py
index 743985d..07b3ada 100644
--- a/game_data_packager/__init__.py
+++ b/game_data_packager/__init__.py
@@ -2108,14 +2108,24 @@ class GameData(object):
                      '"%s" is also avaible', package.name, package.better_version)
                   continue
 
+            abort = False
+
             if (package.expansion_for
               and self.packages[package.expansion_for] not in possible
               and not os.path.exists('/usr/share/doc/' + package.expansion_for)):
+                for fullgame in possible:
+                    if fullgame.type == 'full':
+                        logger.warning("won't generate '%s' expansion, because "
+                          'full game "%s" is not avaible nor already installed;'
+                          ' and we are packaging "%s" instead.',
+                          package.name, package.expansion_for, fullgame.name)
+                        abort = True
+                        break
+                else:
                   logger.warning('will generate "%s" expansion, but full game '
                      '"%s" is not avaible nor already installed.',
                      package.name, package.expansion_for)
 
-            abort = False
             if not build_demos:
                 for demo_for in package.demo_for:
                     if self.packages[demo_for] in possible:

-- 
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