'pip install pyobjc==2.4' compiles pyobjc-core multiple times

Issue #21 resolved
Ronald Oussoren
repo owner created an issue

Installing pyobjc 2.4 using either pip or easy_install compiles pyobjc-core multiple times.

This is probably because most framework wrappers have pyobjc-core in their setup-requires list, which is needed for all wrappers that contain C extensions because they use a header provided by pyobjc-core.

Look into a way to work around this problem (either in pyobjc, or by tweaking pip and easy_install)

Comments (8)

  1. Tai Lee

    Adding wheels to PyPI would also probably resolve this issue? In #91 you said it takes too much time to do manually, but it seems there hasn't been a release of PyObjC since 2014 anyway, so manually building and uploading wheels for 3.0.4 to PyPI would go a long way to alleviating the problem here.

    Instead of being able to tell users to just pip install -e . (with pyobjc as a dependency in setup.py) or pip install -r requirements.txt (with pyobjc as a dependency, along side other dependencies), I have to tell them to first pip install pyobjc-core then pip install pyobjc then pip install -e .

  2. Ronald Oussoren reporter

    Wheels would fix the issue, but would require to build wheels for every release. While there haven't been releases in a while I do want to change that and anything that increases the amount of work for a release tends to make it harder to cut releases.

    Maybe I should spent some time on something I should have done a long while back: automate as much as possible of the current manual pre-release process (in particular building and testing with various Python version on a number of OSX releases). With an automated process it is possible to generate wheels without increasing the amount of work I have to do around releases.

  3. Ronald Oussoren reporter

    The build-time dependency from the framework wrappers to pyobjc-core is present because framework wrappers with extensions use two header files from pyobjc-core. Those files are included in the egg-info of pyobjc-core to make it easier to update these files.

    I'm going to look into a way to include the files in the sdist archives of the various framework wrappers, that would remove the build-time dependency and hence would make it possible to install all of PyObjC without building pyobjc-core multiple times.

  4. Ronald Oussoren reporter

    Tweak the build procedure to avoid building pyobc-core multipel times

    See issue #21

    This patch adds symlinks to pyobjc-api.h and pyobjc-compat.h to all framework wrappers that have an Exension module. The setup.py file removes the setup_requires on pyobjc-core when those headers are present (the setup_requires is still present).

    This does not yet close the issue because I haven't tested if this completely fixes the problem.

    → <<cset 8c888972a099>>

  5. Log in to comment