From: Fabian Groffen Date: Sun, 18 Oct 2009 14:52:19 +0000 (-0000) Subject: remove files that should be links X-Git-Url: http://git.tremily.us/gitweb.cgi?a=commitdiff_plain;h=35f4e0b56dc5f29cd76757bbf198ef7ec77a857d;p=portage.git remove files that should be links svn path=/main/branches/prefix/; revision=14674 --- diff --git a/pym/cvstree.py b/pym/cvstree.py deleted file mode 100644 index 9e5e691a9..000000000 --- a/pym/cvstree.py +++ /dev/null @@ -1,35 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname)) -sys.modules[__oldname] = __realmodule diff --git a/pym/eclass_cache.py b/pym/eclass_cache.py deleted file mode 100644 index 9e5e691a9..000000000 --- a/pym/eclass_cache.py +++ /dev/null @@ -1,35 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname)) -sys.modules[__oldname] = __realmodule diff --git a/pym/emergehelp.py b/pym/emergehelp.py deleted file mode 100644 index 9e5e691a9..000000000 --- a/pym/emergehelp.py +++ /dev/null @@ -1,35 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname)) -sys.modules[__oldname] = __realmodule diff --git a/pym/getbinpkg.py b/pym/getbinpkg.py deleted file mode 100644 index 9e5e691a9..000000000 --- a/pym/getbinpkg.py +++ /dev/null @@ -1,35 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname)) -sys.modules[__oldname] = __realmodule diff --git a/pym/output.py b/pym/output.py deleted file mode 100644 index 9e5e691a9..000000000 --- a/pym/output.py +++ /dev/null @@ -1,35 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname)) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_checksum.py b/pym/portage_checksum.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_checksum.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_compat_namespace.py b/pym/portage_compat_namespace.py deleted file mode 100644 index 736b67833..000000000 --- a/pym/portage_compat_namespace.py +++ /dev/null @@ -1,46 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except (ImportError, AttributeError): - raise ImportError("No module named %s" % __oldname) - -def _showwarning(message, category, filename, lineno, file=None, line=None): - if file is None: - import sys - file = sys.stderr - try: - file.write("%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message)) - except IOError: - pass - -warnings.showwarning = _showwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_const.py b/pym/portage_const.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_const.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_data.py b/pym/portage_data.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_data.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_debug.py b/pym/portage_debug.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_debug.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_dep.py b/pym/portage_dep.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_dep.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_exception.py b/pym/portage_exception.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_exception.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_exec.py b/pym/portage_exec.py deleted file mode 100644 index aa8da0aa0..000000000 --- a/pym/portage_exec.py +++ /dev/null @@ -1,15 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -Special edition of portage_compat_namespace.py as for this module we can't translate -name automatically as "import portage.exec" is a SyntaxError. -""" - -import sys, warnings - -import portage.process -warnings.warn("DEPRECATION NOTICE: The portage_exec module was replaced by portage.process") -sys.modules["portage_exec"] = portage.process diff --git a/pym/portage_gpg.py b/pym/portage_gpg.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_gpg.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_localization.py b/pym/portage_localization.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_localization.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_locks.py b/pym/portage_locks.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_locks.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_mail.py b/pym/portage_mail.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_mail.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_manifest.py b/pym/portage_manifest.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_manifest.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_news.py b/pym/portage_news.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_news.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_selinux.py b/pym/portage_selinux.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_selinux.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_update.py b/pym/portage_update.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_update.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_util.py b/pym/portage_util.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_util.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/portage_versions.py b/pym/portage_versions.py deleted file mode 100644 index b6c3da569..000000000 --- a/pym/portage_versions.py +++ /dev/null @@ -1,40 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -def _formatwarning(message, category, filename, lineno): - return "%s:%s: %s: %s\n" % (filename, lineno, category.__name__, message) - -warnings.formatwarning = _formatwarning - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname), DeprecationWarning) -sys.modules[__oldname] = __realmodule diff --git a/pym/xpak.py b/pym/xpak.py deleted file mode 100644 index 9e5e691a9..000000000 --- a/pym/xpak.py +++ /dev/null @@ -1,35 +0,0 @@ -# portage_compat_namespace.py -- provide compability layer with new namespace -# Copyright 2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -""" -This module checks the name under which it is imported and attempts to load -the corresponding module of the new portage namespace, inserting it into the -loaded modules list. -It also issues a warning to the caller to migrate to the new namespace. -Note that this module should never be used with it's true name, but only by -links pointing to it. Also it is limited to portage_foo -> portage.foo -translations, however existing subpackages shouldn't use it anyway to maintain -compability with 3rd party modules (like elog or cache plugins), and they -shouldn't be directly imported by external consumers. - -This module is based on an idea by Brian Harring. -""" - -import sys, warnings - -__oldname = __name__ -if __name__.startswith("portage_"): - __newname = __name__.replace("_", ".") -else: - __newname = "portage."+__name__ - -try: - __package = __import__(__newname, globals(), locals()) - __realmodule = getattr(__package, __newname[8:]) -except ImportError, AttributeError: - raise ImportError("No module named %s" % __oldname) - -warnings.warn("DEPRECATION NOTICE: The %s module was replaced by %s" % (__oldname, __newname)) -sys.modules[__oldname] = __realmodule