Gentoo Archives: gentoo-portage-dev

From: Brian Dolbec <dolsen@g.o>
To: gentoo-portage-dev@l.g.o
Subject: Re: [gentoo-portage-dev] [PATCH 5/6] Install Python modules using setup.py
Date: Fri, 22 Aug 2014 22:31:34
Message-Id: 20140822153015.05db05a0.dolsen@gentoo.org
In Reply to: [gentoo-portage-dev] [PATCH 5/6] Install Python modules using setup.py by "Michał Górny"
1 On Thu, 21 Aug 2014 22:19:43 +0200
2 Michał Górny <mgorny@g.o> wrote:
3
4 > ---
5 > .gitignore | 1 +
6 > Makefile | 215 --------------------
7 > doc/Makefile | 11 -
8 > pym/portage/const.py | 4 +-
9 > setup.py | 557
10 > +++++++++++++++++++++++++++++++++++++++++++++++++++ 5 files changed,
11 > 560 insertions(+), 228 deletions(-) delete mode 100644 Makefile
12 > delete mode 100644 doc/Makefile
13 > create mode 100755 setup.py
14
15
16
17
18 > diff --git a/setup.py b/setup.py new file mode 100755
19 > index 0000000..bd6e506 --- /dev/null
20 > +++ b/setup.py
21 > @@ -0,0 +1,557 @@
22 > +#!/usr/bin/env python
23 > +# vim:fileencoding=utf-8
24 > +# (c) 2010 Michał Górny <mgorny@g.o>
25 > +# Released under the terms of the 2-clause BSD license.
26 > +
27 > +from distutils.core import setup, Command
28 > +from distutils.command.build_scripts import build_scripts
29 > +from distutils.command.clean import clean
30 > +from distutils.command.install import install
31 > +from distutils.command.install_data import install_data
32 > +from distutils.command.install_lib import install_lib
33 > +from distutils.command.install_scripts import install_scripts
34 > +from distutils.dir_util import remove_tree
35 > +from distutils.util import change_root, subst_vars
36 > +
37 > +import codecs, collections, glob, os, os.path, re, subprocess, sys
38 > +
39 > +# TODO:
40 > +# - smarter rebuilds of docs w/ 'install_docbook' and
41 > 'install_epydoc'. +
42 > +package_name = 'portage'
43 > +package_version = '2.2.12'
44
45 Why hard code the version? can you not import it? or did you add this
46 to the sed list in mkrelease.sh?
47
48 --
49 Brian Dolbec <dolsen>

Replies