Ticket #3410 enhancement closed fixed

Opened 5 years ago

Last modified 5 years ago

Exclude extensions for Jython

Reported by: thijs Owned by:
Priority: normal Milestone:
Component: core Keywords: jython
Cc: thijs Branch: branches/jython-ext-3410
Author: thijs Launchpad Bug:

Description

When trying to build Twisted for Jython it dies with:

$ jython setup.py install
running install
running build
running build_py
copying twisted/protocols/dns.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/ethernet.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/imap4.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/ip.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/irc.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/jabber.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/msn.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/nntp.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/oscar.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/pop3.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/raw.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/rawudp.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/smtp.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/sux.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/protocols/toc.py -> build/lib.java1.6.0_05-2.3/twisted/protocols
copying twisted/web/xmlrpc.py -> build/lib.java1.6.0_05-2.3/twisted/web
copying twisted/web/test/test_xmlrpc.py -> build/lib.java1.6.0_05-2.3/twisted/web/test
running build_ext
error: Compiling extensions is not supported on Jython

jbaker suggested to use something like:

if not sys.platform.startswith('java'):
    # ...

Change History

1

follow-ups: ↓ 3 ↓ 5   Changed 5 years ago by thijs

The command for the Jython buildslave also needs to change and exclude the extension build process.

2

  Changed 5 years ago by thijs

  • keywords jython added

3

in reply to: ↑ 1   Changed 5 years ago by thijs

Replying to thijs:

The command for the Jython buildslave also needs to change and exclude the extension build process.

Cause it currently dies with  http://buildbot.twistedmatrix.com/builders/ubuntu64-jython2.5-select/builds/5/steps/compile/logs/stdio/text

4

  Changed 5 years ago by thijs

  • branch set to branches/jython-ext-3410
  • author set to thijs

(In [24687]) Branching to 'jython-ext-3410'

5

in reply to: ↑ 1   Changed 5 years ago by thijs

  • owner glyph deleted
  • keywords jython, review added; jython removed

Replying to thijs:

The command for the Jython buildslave also needs to change and exclude the extension build process.

I'll open a new ticket for this as suggested by exarkun.

I committed a fix in r24688, and the buildslave now  shows the expected output:

running build_ext

Putting it up for review.

6

  Changed 5 years ago by exarkun

  • owner set to thijs
  • keywords jython added; jython, review removed

I had some ideas for doing this check in twisted/python/dist.py where it could be unit tested. However, it seems that ConditionalExtension, the thing I was hoping we would be able to use, does not actually work unless you can run build_ext. As it seems Jython can't do this, I suppose there's no obvious way to use twisted/python/dist.py to do this.

So, please merge.

7

  Changed 5 years ago by thijs

  • status changed from new to closed
  • resolution set to fixed

(In [24692]) Merge jython-ext-3410: exclude extensions in the build process when using Jython

Author: thijs Reviewer: exarkun Fixes: #3410

8

  Changed 2 years ago by <automation>

  • owner thijs deleted
Note: See TracTickets for help on using tickets.