Don't exclude symlinks when loading plugins

FreeIPA uses custom helpers to enumerate and load plugins. These plugins,
 provided by the ipalib module, are excluded due to being symlinked in from
 /usr/lib/pyshared as part of the dh_python2 installation process.

 This change can probably be submitted upstream, but I have no idea why the
 original author would exclude symlinks in the first place, nor why a custom
 loader is being used.

Conflicts:
	debian/patches/series
This commit is contained in:
Nick Hatch
2013-02-20 16:30:13 -08:00
committed by Timo Aaltonen
parent a484849389
commit 662b048455
2 changed files with 23 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
Description: Don't exclude symlinks when loading plugins
FreeIPA uses custom helpers to enumerate and load plugins. These plugins,
provided by the ipalib module, are excluded due to being symlinked in from
/usr/lib/pyshared as part of the dh_python2 installation process.
.
This change can probably be submitted upstream, but I have no idea why the
original author would exclude symlinks in the first place, nor why a custom
loader is being used.
Author: Nick Hatch <nicholas.hatch@gmail.com>
Last-Update: 2013-03-20
--- freeipa.orig/ipalib/util.py
+++ freeipa/ipalib/util.py
@@ -81,7 +81,7 @@
if not name.endswith(suffix):
continue
pyfile = os.path.join(src_dir, name)
- if os.path.islink(pyfile) or not os.path.isfile(pyfile):
+ if not os.path.isfile(pyfile):
continue
module = name[:-len(suffix)]
if module == '__init__':

View File

@@ -8,3 +8,4 @@ correct-python-path.diff
dont-search-platform-path.diff
fix-install-layout.diff
fix-ntpdate-opts.diff
fix-symlink-exclusion.diff