Install pycairo in virtualenv

后端 未结 6 1393
梦毁少年i
梦毁少年i 2020-12-13 09:44

I\'ve tried to install pycairo in a virtualenv to use in a Django project. I\'ve ran the pip install pycairo==1.10.0 command which finds the packag

6条回答
  •  春和景丽
    2020-12-13 09:47

    Although py2cairo doesn't install nicely using pip, you can still install py2cairo into the virtual environment using the build instructions in the INSTALL file from the distribution.

    You will need the cairo-dev/cairo-devel package for you os installed in order to build the package.

    Do the following to install into your virtual environment:

    1. download, unpack, and cd into the the py2cairo directory
    2. Activate your virtual environment
    3. Follow the standard build procedure

    ./waf configure --prefix=$VIRTUAL_ENV

    ./waf build

    ./waf install

提交回复
热议问题