Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade Cython to 0.14.1 #10493

Closed
jasongrout opened this issue Dec 18, 2010 · 35 comments
Closed

Upgrade Cython to 0.14.1 #10493

jasongrout opened this issue Dec 18, 2010 · 35 comments

Comments

@jasongrout
Copy link
Member

Version 0.14.1 was recently released, and has some bugfixes and nice features.

Use the following spkg and patch:

  1. http://boxen.math.washington.edu/home/jdemeyer/spkg/cython-0.14.1.p3.spkg
  2. attachment: 10493-cython-0.14.1.patch

CC: @robertwb @kiwifb

Component: packages: standard

Keywords: cython spkg

Author: Robert Bradshaw

Reviewer: François Bissey

Merged: sage-4.7.alpha1

Issue created by migration from https://trac.sagemath.org/ticket/10493

@robertwb
Copy link
Contributor

comment:1

We're in pretty good shape. There's a couple of minor patches to the library that need to go in, but other than that upgrading to 0.14 should be pretty straightforward. See, e.g. https://sage.math.washington.edu:8091/hudson/view/ExtLibs/job/sage-tests/

@jdemeyer
Copy link

Changed keywords from none to cython spkg

@jdemeyer
Copy link

comment:2

Is the __getattr__ patch (in the 0.13 Cython spkg) still needed?

@robertwb
Copy link
Contributor

comment:3

No, that is now handled via a flag. There are several bugfixes in 0.14.1 that I'd like to get in, which should be out shortly (before 4.6.2 is at release candidate for sure, and I knew we missed the window for 4.6.1) which is why I haven't done anything on this ticket yet.

@vbraun
Copy link
Member

vbraun commented Jan 12, 2011

comment:4

Updated package with just the __getattr__ patches removed as they are now in the upstream source:

http://www.stp.dias.ie/~vbraun/Sage/spkg/cython-0.14.spkg

@robertwb
Copy link
Contributor

comment:5

Thanks, but that is not sufficient, as we need to pass the appropriate flags.

The most recent spkg can be found at https://sage.math.washington.edu:8091/hudson/job/sage-build/lastSuccessfulBuild/artifact/cython-devel.spkg (though the Sage library requires a couple of patches as well).

@jasongrout

This comment has been minimized.

@jasongrout
Copy link
Member Author

comment:6

Updating the description to upgrade to 0.14.1, which is now the most recent release. Has anyone worked on an 0.14.1 spkg?

@jasongrout jasongrout changed the title Upgrade Cython to 0.14 Upgrade Cython to 0.14.1 Feb 8, 2011
@robertwb
Copy link
Contributor

robertwb commented Feb 9, 2011

@jasongrout
Copy link
Member Author

comment:9

Replying to @robertwb:

There's a couple of minor patches to the library that need to go in

Is this still the case with the 0.14.1 spkg?

@kiwifb
Copy link
Member

kiwifb commented Feb 9, 2011

comment:10

I think that's what the patch is all about. I applied it to 4.6.2.alpha4 and it happily built and sage -testall did not show any problems for me. But may be the following warnings should be addressed

warning: sage/combinat/combinat_cython.pyx:14:0: 'stdlib' is deprecated, use 'libc.stdlib'
warning: sage/ext/interpreters/wrapper_rdf.pxd:3:0: 'python_object' is deprecated, use 'cpython'
warning: sage/rings/polynomial/polynomial_real_mpfr_dense.pyx:7:0: 'python_int' is deprecated, use 'cpython'
warning: sage/rings/polynomial/polynomial_real_mpfr_dense.pyx:8:0: 'python_float' is deprecated, use 'cpython'
warning: sage/ext/interpreters/wrapper_cdf.pxd:3:0: 'python_object' is deprecated, use 'cpython'
warning: sage/ext/interpreters/wrapper_rdf.pxd:3:0: 'python_object' is deprecated, use 'cpython'
warning: sage/ext/interpreters/wrapper_py.pxd:3:0: 'python_object' is deprecated, use 'cpython'
warning: sage/ext/interpreters/wrapper_rr.pxd:3:0: 'python_object' is deprecated, use 'cpython'
warning: sage/ext/interpreters/wrapper_el.pxd:3:0: 'python_object' is deprecated, use 'cpython'

And possibly

warning: sage/modular/modsym/p1list.pyx:703:17: cdef variable 'i' declared after it is used

Finally I am wondering about these

warning: sage/matrix/matrix0.pyx:53:22: Function signature does not match previous declaration
warning: sage/matrix/matrix_window.pyx:9:17: Function signature does not match previous declaration
warning: sage/matrix/matrix_sparse.pyx:18:33: Function signature does not match previous declaration

But all these were present before upgrading to cython-0.14.1.
We could use the opportunity to fix some of them before they bite us later, especially the deprecated ones.

@kiwifb
Copy link
Member

kiwifb commented Feb 9, 2011

comment:11

Forgot these two:

warning: sage/structure/parent.pyx:124:4: dict already a builtin Cython type
warning: sage/symbolic/pynac.pyx:589:5: Function 'py_get_parent_char' previously declared as 'extern'

@robertwb
Copy link
Contributor

robertwb commented Feb 9, 2011

comment:12

Yes, the (attached) patch is still needed. There's some significant cleanup that I want to do, including fixing these warnings, but I think that should be a separate ticket.

@kiwifb
Copy link
Member

kiwifb commented Feb 9, 2011

comment:13

Well if you open a separate ticket for these warnings I am quite happy to give this a positive review. I have built it on linux-86, linux-amd64 and OS X 10.5.
It all looks good to me.

@kiwifb

This comment has been minimized.

@robertwb
Copy link
Contributor

comment:14

Ticket for warnings at #10764.

@jdemeyer
Copy link

Reviewer: François Bissey

@jdemeyer
Copy link

Author: Robert Bradshaw

@jdemeyer jdemeyer modified the milestones: sage-4.6.2, sage-4.7 Feb 10, 2011
@jdemeyer
Copy link

comment:16

After building sage-4.6.2.rc0 and applying the spkg and patch from this ticket:

$ ./sage -ba-force
[...]
gcc -fno-strict-aliasing -g -O2 -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC -I/usr/local/src/sage-4.6.2.rc0/local//include -I/usr/local/src/sage-4.6.2.rc0/local//include/csage -I/usr/local/src/sage-4.6.2.rc0/devel//sage/sage/ext -I/usr/local/src/sage-4.6.2.rc0/local/include/python2.6 -c sage/combinat/combinat_cython.c -o build/temp.linux-x86_64-2.6/sage/combinat/combinat_cython.o -w
sage/combinat/combinat_cython.c: In function '__pyx_pf_4sage_8combinat_15combinat_cython__stirling_number2':
sage/combinat/combinat_cython.c:2431:13: error: incompatible types when assigning to type 'mpz_t' from type 'struct __mpz_struct *'
error: command 'gcc' failed with exit status 1
sage: There was an error installing modified sage library code.

This is using

$ gcc --version
gcc-4.4.3 (Gentoo 4.4.3-r2 p1.2) 4.4.3
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

@robertwb
Copy link
Contributor

comment:20

I've created a new spkg. All tests pass.

@robertwb

This comment has been minimized.

@kiwifb
Copy link
Member

kiwifb commented Feb 25, 2011

comment:21

Replying to @robertwb:

Somehow one of the fixes for http://trac.cython.org/cython_trac/ticket/654 was merged into the release at the last minute, which is incompatible with how we declare many of the *_t types. I'll post a new spkg disabling this "fix."

How come you and I never got affected by it?

@robertwb
Copy link
Contributor

comment:22

I'm not sure, but maybe the last spkg was the rc, and the fix for this issue was not supposed to go in this release, but we messed up and it did.

@jdemeyer
Copy link

comment:23

It works for me now, so I'm putting back the positive review.

@robertwb
Copy link
Contributor

comment:24

Thanks.

@jdemeyer
Copy link

jdemeyer commented Mar 8, 2011

Merged: sage-4.7.alpha1

@jdemeyer
Copy link

jdemeyer commented May 4, 2011

comment:26

Please fix: the SPKG.txt must be updated, there is no mention of this ticket.

@robertwb
Copy link
Contributor

robertwb commented May 5, 2011

comment:27

The SPKG.txt has been updated, see http://sage.math.washington.edu/home/robertwb/cython/cython-0.14.1.p2.spkg

@robertwb

This comment has been minimized.

@jdemeyer
Copy link

jdemeyer commented May 5, 2011

comment:28

Attachment: cython-SPKG.txt.diff.gz

I made some further changes to SPKG.txt: http://boxen.math.washington.edu/home/jdemeyer/spkg/cython-0.14.1.p3.spkg

@jdemeyer

This comment has been minimized.

@robertwb
Copy link
Contributor

robertwb commented May 6, 2011

comment:29

I'm happy with your spkg.txt.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants