python-pexpect/python-pexpect-2.3.patch

68 lines
1.7 KiB
Diff

---
MANIFEST.in | 15 +++++++++++++++
setup.py | 28 +++++++++++++++++++++++++++-
2 files changed, 42 insertions(+), 1 deletion(-)
--- /dev/null
+++ b/MANIFEST.in
@@ -0,0 +1,15 @@
+include ANSI.py
+include fdpexpect.py
+include FSM.py
+include INSTALL
+include LICENSE
+include Makefile
+include MANIFEST.in
+include pexpect.py
+include pxssh.py
+include PKG-INFO
+include README
+include screen.py
+include setup.py
+recursive-include doc *
+recursive-include examples *
--- a/setup.py
+++ b/setup.py
@@ -3,7 +3,27 @@ $Revision: 485 $
$Date: 2007-07-12 15:23:15 -0700 (Thu, 12 Jul 2007) $
'''
from distutils.core import setup
-setup (name='pexpect',
+from distutils.command.bdist_rpm import bdist_rpm
+
+NAME = "python-pexpect"
+
+def getdoc():
+ import os
+ result = ['INSTALL','LICENSE','README','PKG-INFO']
+ list = os.listdir(os.path.join(os.curdir, 'doc'))
+ for file in list:
+ result.append(os.path.join('doc', file))
+ return result
+
+def getexamples():
+ import os
+ result = []
+ list = os.listdir(os.path.join(os.curdir, 'examples'))
+ for file in list:
+ result.append(os.path.join('examples', file))
+ return result
+
+setup (name=NAME,
version='2.3',
py_modules=['pexpect', 'pxssh', 'fdpexpect', 'FSM', 'screen', 'ANSI'],
description='Pexpect is a pure Python Expect. It allows easy control of other applications.',
@@ -12,6 +32,12 @@ setup (name='pexpect',
url='http://pexpect.sourceforge.net/',
license='MIT license',
platforms='UNIX',
+ data_files = [("share/doc/packages/"+NAME, getdoc()),
+ ("share/doc/packages/"+NAME+"/examples",getexamples())],
+ cmdclass = {
+ 'bdist_rpm': bdist_rpm
+ }
+
)
# classifiers = [