Add support for python packaging.

Added a setup.py for packaging. This will install the .py files as autospec
library in dist-packages. Because of the way the imports are currently done, autospec.py
is installed in dist-packages dir. The rpm packaging should create a symlink to this file at
/usr/bin/autospec.py
This commit is contained in:
Archana
2015-12-09 20:57:53 -08:00
parent 71461e2e5e
commit eb1b2f61cc
22 changed files with 45 additions and 5 deletions
+2
View File
@@ -0,0 +1,2 @@
include README.rst
include LICENSE
+6
View File
@@ -0,0 +1,6 @@
import sys
import os
__all__ = ["buildreq", "build", "buildpattern", "config", "docs","files",
"git","lang", "license", "patches", "specdescription", "tarball",
"util", "commitmessage", "test", "patches"]
+5 -5
View File
@@ -17,6 +17,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
import argparse
import sys
import os
import re
import types
import build
import buildpattern
import buildreq
@@ -26,14 +31,10 @@ import git
import lang
import license
import docs
import os
import patches
import re
import specdescription
import sys
import tarball
import test
import types
import commitmessage
from tarball import name
@@ -41,7 +42,6 @@ from util import _file_write
sys.path.append(os.path.dirname(__file__))
def write_sources(file):
"""Append additonal source files.
systemd unit files, gcov and additional source tarballs
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
+2
View File
@@ -0,0 +1,2 @@
[egg_info]
tag_build =
+30
View File
@@ -0,0 +1,30 @@
from setuptools import setup, find_packages
import sys, os
version = "1.0.0"
def readme():
with open("README.rst") as f:
return f.read()
setup(name="autospec",
description="Automated creation of RPM packaging",
long_description=readme(),
version = version,
license = "GPLv3",
packages = ["autospec"],
package_data = {
'': ['*.pl', '*.dic'],
},
classifiers=[
'Intended Audience :: Developers',
'Topic :: Software Development :: Build Tools',
'License :: OSI Approved :: GNU General Public License v3 (GPLv3)',
# Python versions supported.
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
],
include_package_data = True,
)