Browse code

Import xattr with sudo early on

xattr fails to import due to being unable to build cffi bindings unless
it is imported as root beforehand.

Depends-On: I6a9d64277974933ae9b7bbe2a40b8a0eb0fa8c6a

Change-Id: I835e55bbafc7e0640987e6f3c8ee0c873f875ee0
Closes-Bug: #1451992

Gregory Haynes authored on 2015/05/06 07:14:24
Showing 1 changed files
... ...
@@ -708,6 +708,12 @@ source $TOP_DIR/tools/fixup_stuff.sh
708 708
 # Pre-build some problematic wheels
709 709
 if [[ -n ${WHEELHOUSE:-} && ! -d ${WHEELHOUSE:-} ]]; then
710 710
     source $TOP_DIR/tools/build_wheels.sh
711
+
712
+    # Due to https://bugs.launchpad.net/swift/+bug/1451992 we have to import
713
+    # this package with root once so the CFFI bindings can be built. We have
714
+    # to therefore install it so we can import it.
715
+    pip_install xattr
716
+    sudo python -c "import xattr"
711 717
 fi
712 718
 
713 719