]> git.ipfire.org Git - people/amarx/ipfire-3.x.git/blob - pakfire/patches/0003-macros-Add-python-variables.patch
sqlite: Split libs into separate package.
[people/amarx/ipfire-3.x.git] / pakfire / patches / 0003-macros-Add-python-variables.patch
1 From b59029f9d6c226a70f333e52db43dd62fb89dcc8 Mon Sep 17 00:00:00 2001
2 From: Michael Tremer <michael.tremer@ipfire.org>
3 Date: Tue, 2 Oct 2012 22:07:24 +0200
4 Subject: [PATCH 3/4] macros: Add python variables.
5
6 ---
7 macros/python.macro | 15 +++++++++++++++
8 1 file changed, 15 insertions(+)
9 create mode 100644 macros/python.macro
10
11 diff --git a/macros/python.macro b/macros/python.macro
12 new file mode 100644
13 index 0000000..1b417f2
14 --- /dev/null
15 +++ b/macros/python.macro
16 @@ -0,0 +1,15 @@
17 +# A bunch of predefined things for Python.
18 +
19 +# Python 3 constants.
20 +python3 = /usr/bin/python3
21 +
22 +python3_sitearch = %(%{python3} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")
23 +python3_sitelib = %(%{python3} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")
24 +python3_version = %(%{python3} -c "import sys; sys.stdout.write(sys.version[:3])")
25 +
26 +# Python 2 constants.
27 +python = /usr/bin/python2
28 +
29 +python_sitearch = %(%{python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")
30 +python_sitelib = %(%{python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")
31 +python_version = %(%{python} -c "import sys; sys.stdout.write(sys.version[:3])")
32 --
33 1.7.11.4
34