[kernel] r10741 - people/waldi/dkt/lib/dkt/hooks/modules
Bastian Blank
waldi at alioth.debian.org
Sat Mar 8 18:16:04 UTC 2008
Author: waldi
Date: Sat Mar 8 18:16:03 2008
New Revision: 10741
Log:
lib/dkt/hooks/modules/backward_symlinks.py: Add deploy function.
Modified:
people/waldi/dkt/lib/dkt/hooks/modules/backward_symlinks.py
Modified: people/waldi/dkt/lib/dkt/hooks/modules/backward_symlinks.py
==============================================================================
--- people/waldi/dkt/lib/dkt/hooks/modules/backward_symlinks.py (original)
+++ people/waldi/dkt/lib/dkt/hooks/modules/backward_symlinks.py Sat Mar 8 18:16:03 2008
@@ -54,13 +54,14 @@
if config.get('backward-compatibility', 'symlink-remove', None):
symlink_remove = i
- if symlink_create is not None:
- if symlink_create not in (symlink_act, symlink_old):
- symlink_old = symlink_act
- symlink_act = symlink_create
+ if symlink_create is not None and symlink_create is not symlink_act and symlink_create is not symlink_old:
+ symlink_old = symlink_act
+ symlink_act = symlink_create
if symlink_remove is not None:
- if symlink_remove in (symlink_act, symlink_old):
+ if symlink_remove is symlink_act:
+ raise NotImplementedError
+ elif symlink_remove is symlink_old:
raise NotImplementedError
ret = []
@@ -72,5 +73,14 @@
ret.append(symlink_act)
return [ret]
+ def boot_config_deploy(self, bootconfigs, systemconfig):
+ if not self._check_active(systemconfig):
+ return
+
+ assert len(bootconfigs) <= 2
+
+ return True
+
register('backward-symlinks', interfaces.IBootConfigPartition, Hook(), default_registry.PRIORITY_FIRST)
+register('backward-symlinks', interfaces.IBootConfigDeploy, Hook(), default_registry.PRIORITY_FIRST)
register('backward-symlinks', interfaces.IImageTask, Hook())
More information about the Kernel-svn-changes
mailing list