diff recipes/kde/maemo/kde_l10n.py @ 381:51c447a6792e

merged maemo packager into enterprise packager maemo generic is obsolete with builder_cls: sbdmock setting maemo sepecific kde_l10n packager are still necessary
author Bjoern Ricks <bricks@intevation.de>
date Wed, 07 Jul 2010 09:33:49 +0000
parents 7a1385c1207c
children
line wrap: on
line diff
--- a/recipes/kde/maemo/kde_l10n.py	Mon Jun 21 13:06:51 2010 +0000
+++ b/recipes/kde/maemo/kde_l10n.py	Wed Jul 07 09:33:49 2010 +0000
@@ -1,4 +1,4 @@
-# Copyright (C) 2007, 2008, 2009 by Intevation GmbH
+# Copyright (C) 2007 - 2010 by Intevation GmbH
 # Authors:
 # Bernhard Herzog <bh@intevation.de>
 # Bjoern Ricks <bjoern.ricks@intevation.de>
@@ -15,7 +15,7 @@
 from treepkg.cmdexpand import cmdexpand
 from treepkg import run
 
-import recipes.kde.maemo.generic as generic
+import recipes.kde.enterprise.kde_l10n as generic
 
 
 class SourcePackager(generic.SourcePackager):
@@ -63,20 +63,6 @@
 
     def __init__(self, *args, **kw):
         super(SourcePackager, self).__init__(*args, **kw)
-        self.enterprise_version = (time.strftime("%Y%m%d", time.localtime())
-                                   + "." + str(self.revision))
-        self.maemo_version =  "%s.%s" % (self.revision,
-                              self.parent.pkg_date)
-
-    def determine_package_version(self, directory):
-        enterprise_version = self.enterprise_version
-        maemo_version = self.maemo_version
-        revision = self.revision
-        rules_revision = self.parent.rules_revision
-        pkg_revision = self.parent.pkg_revision
-        pkg_date = self.parent.pkg_date
-
-        return self.track.version_template % locals()
 
     def create_l10n_de_tarball(self, pkgbasedir, pkgbaseversion):
         logging.info("Creating kde-l10n-de tarball")
@@ -91,6 +77,7 @@
         treepkg.util.writefile(script_name, script, 0755)
         treepkg.util.ensure_directory(self.src_dir)
         treepkg.util.ensure_directory(self.log_dir)
+        # do not run scratchbox
         #self.track.builder.run_script([script_name],
         #                              logfile=os.path.join(self.log_dir,
         #                                                   "tarball_log.txt"),
@@ -101,17 +88,10 @@
         return de_tarball
 
     def run_script(self, script_name, logfile):
+        ''' run script outside of scratchbox '''
         run.call(cmdexpand("@script", script=script_name),
                  suppress_output=False, logfile=logfile)
 
-    def prepare_sources_for_tarball(self, pkgbasedir, pkgbaseversion):
-        de_tarball = self.create_l10n_de_tarball(pkgbasedir, pkgbaseversion)
-        shutil.rmtree(pkgbasedir)
-        os.mkdir(pkgbasedir)
-        os.rename(de_tarball,
-                  os.path.join(pkgbasedir, os.path.basename(de_tarball)))
-
-
 class RevisionPackager(generic.RevisionPackager):
 
     source_packager_cls = SourcePackager
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)