diff --git a/Makefile b/Makefile index ac7394b..69a0d0f 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ include src/options.mk -.PHONY: pybinding install devel venv doc clean +.PHONY: pybinding install devel venv doc clean _attrdict pybinding: @@ -37,20 +37,28 @@ light: venv @$(INSIDE_VENV) pip install src/ -_build_wx/wxPython.target: +_attrdict: + # Check if virtualenv python version > 3.3.0 + # If so, install the patched version of attrdict used to build the version 4.2.0 of wxPython + @$(INSIDE_VENV) if `python -c "import sys; exit(sys.version_info > (3,3))"`; then \ + pip install --no-cache attrdict; \ + else \ + pip install thirdparty/attrdict-2.0.1.tar.gz; \ + fi + + +_build_wx/wxPython.target: _attrdict @$(INSIDE_VENV) echo "Building wxPython for your `python --version 2>&1` under Linux $(DISTRO_RELEASE)..." # Create a folder to build wx into @mkdir -p _build_wx - @$(INSIDE_VENV) pip install attrdict sip - # TODO: attrdict is no longer compatible with collections package. The build will fail # download the wheel or the source if it cannot find a wheel - @$(INSIDE_VENV) cd _build_wx && pip download -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/$(DISTRO_RELEASE) wxPython + $(INSIDE_VENV) cd _build_wx && pip download -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/$(DISTRO_RELEASE) wxPython # Build the source if a tar.gz was downloaded @$(INSIDE_VENV) cd _build_wx && \ if [ -e wxPython*.tar.gz ]; then \ tar -x --skip-old-files -vzf wxPython*.tar.gz; \ cd `ls -d wxPython*/`; \ - pip install requests; \ + pip install requests sip; \ python build.py dox etg --nodoc sip build bdist_wheel; \ ln -sf `readlink -f dist/wxPython*.whl` ../; \ fi; diff --git a/thirdparty/attrdict-2.0.1.tar.gz b/thirdparty/attrdict-2.0.1.tar.gz new file mode 100644 index 0000000..ec2ae4e Binary files /dev/null and b/thirdparty/attrdict-2.0.1.tar.gz differ