]> git.pld-linux.org Git - SPECS.git/blob - python-virtualenv-clone.spec
SPECS updated Mon 29 Apr 22:05:02 CEST 2024
[SPECS.git] / python-virtualenv-clone.spec
1 #
2 # Conditional build:
3 %bcond_without  doc             # don't build doc
4 %bcond_without  tests   # do not perform "make test"
5 %bcond_without  python2 # CPython 2.x module
6 %bcond_with     python3 # CPython 3.x module
7
8 %define         module  virtualenv-clone
9 Summary:        Script to clone virtualenvs
10 Name:           python-virtualenv-clone
11 Version:        0.2.4
12 Release:        4
13 License:        MIT
14 Group:          Development/Libraries
15 Source0:        http://pypi.python.org/packages/source/v/%{module}/%{module}-%{version}.tar.gz
16 # Source0-md5:  71168b975eaaa91e65559bcc79290b3b
17 URL:            http://pypi.python.org/pypi/virtualenv-clone
18 BuildRequires:  rpm-pythonprov
19 BuildRequires:  rpmbuild(macros) >= 1.710
20 %if %{with python2}
21 BuildRequires:  python-distribute
22 BuildRequires:  python-virtualenv
23 %endif
24 %if %{with python3}
25 BuildRequires:  python3-virtualenv
26 %endif
27 Requires:       python-virtualenv
28 BuildArch:      noarch
29 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31 %description
32 A script for cloning a non-relocatable virtualenv.
33
34 Virtualenv provides a way to make virtualenv's relocatable which could
35 then be copied as we wanted. However making a virtualenv relocatable
36 this way breaks the no-site-packages isolation of the virtualenv as
37 well as other aspects that come with relative paths and '/usr/bin/env'
38 shebangs that may be undesirable.
39
40 Also, the .pth and .egg-link rewriting doesn't seem to work as
41 intended. This attempts to overcome these issues and provide a way to
42 easily clone an existing virtualenv.
43
44 %package -n python3-virtualenv-clone
45 Summary:        Script to clone virtualenvs
46 Group:          Development/Libraries
47 Requires:       python3-virtualenv
48
49 %description -n python3-virtualenv-clone
50 virtualenv cloning script.
51
52 A script for cloning a non-relocatable virtualenv.
53
54 Virtualenv provides a way to make virtualenv's relocatable which could
55 then be copied as we wanted. However making a virtualenv relocatable
56 this way breaks the no-site-packages isolation of the virtualenv as
57 well as other aspects that come with relative paths and '/usr/bin/env'
58 shebangs that may be undesirable.
59
60 Also, the .pth and .egg-link rewriting doesn't seem to work as
61 intended. This attempts to overcome these issues and provide a way to
62 easily clone an existing virtualenv.
63
64 %prep
65 %setup -q -n %{module}-%{version}
66
67 %build
68 %if %{with python2}
69 %py_build
70 %endif
71
72 %if %{with python3}
73 %py3_build
74 %endif
75
76 %install
77 rm -rf $RPM_BUILD_ROOT
78 %if %{with python2}
79 %py_install
80
81 %py_postclean
82 %endif
83
84 %if %{with python3}
85 %py3_install
86 %endif
87
88 %clean
89 rm -rf $RPM_BUILD_ROOT
90
91 %if %{with python2}
92 %files
93 %defattr(644,root,root,755)
94 %doc README
95 %attr(755,root,root) %{_bindir}/virtualenv-clone
96 %{py_sitescriptdir}/clonevirtualenv.py[co]
97 %{py_sitescriptdir}/virtualenv_clone-%{version}-py*.egg-info
98 %endif
99
100 %if %{with python3}
101 %files -n python3-%{module}
102 %defattr(644,root,root,755)
103 %doc README
104 %attr(755,root,root) %{_bindir}/virtualenv-clone
105 %{py3_sitescriptdir}/clonevirtualenv.*
106 %{py3_sitescriptdir}/virtualenv_clone-%{version}-*
107 %{py3_sitescriptdir}/__pycache__/*clonevirtualenv*
108 %endif
This page took 0.467001 seconds and 3 git commands to generate.