summarylogtreecommitdiffstats
path: root/libx32-python.install
diff options
context:
space:
mode:
authorFantix King2015-11-18 14:37:49 +0800
committerFantix King2015-11-19 18:05:57 +0800
commitbfa70b2a4583a336ffcaa6bc9b10965446490651 (patch)
tree34735a64b7ef0db9181ea1ee8b1f4c4623382896 /libx32-python.install
downloadaur-bfa70b2a4583a336ffcaa6bc9b10965446490651.tar.gz
3.5.0-2.1
Diffstat (limited to 'libx32-python.install')
-rw-r--r--libx32-python.install21
1 files changed, 21 insertions, 0 deletions
diff --git a/libx32-python.install b/libx32-python.install
new file mode 100644
index 000000000000..2cdfcfd29b32
--- /dev/null
+++ b/libx32-python.install
@@ -0,0 +1,21 @@
+post_install() {
+ mv /usr/include/python3.5m/pyconfig.h /usr/include/python3.5m/pyconfig-64.h
+ ln -s pyconfig-stub.h /usr/include/python3.5m/pyconfig.h
+}
+
+post_upgrade() {
+ if [ ! -L /usr/include/python3.5m/pyconfig.h ]; then
+ post_install
+ elif [ ${1::-2} != ${2::-2} ]; then
+ echo WARNING: libx32-python is upgraded before python,
+ echo WARNING: you probably need to reinstall libx32-python.
+ fi
+}
+
+post_remove() {
+ if [ -L /usr/include/python3.5m/pyconfig.h ]; then
+ rm /usr/include/python3.5m/pyconfig.h
+ mv /usr/include/python3.5m/pyconfig-64.h /usr/include/python3.5m/pyconfig.h
+ fi
+}
+