Bug 108994 - [MAINTAINER] devel/py-ode: fix gcc4x build
Summary: [MAINTAINER] devel/py-ode: fix gcc4x build
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Martin Wilke
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-02-09 21:50 UTC by Dmitry Marakasov
Modified: 2007-02-10 13:20 UTC (History)
0 users

See Also:


Attachments
py-ode.patch (833 bytes, patch)
2007-02-09 21:50 UTC, Dmitry Marakasov
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dmitry Marakasov 2007-02-09 21:50:00 UTC
Here's detailed description, maybe this PR should be referenced in the wiki: http://wiki.freebsd.org/gcc4

py-ode fails to build with gcc4x, with following errors:

gcc41:
ode_notrimesh.c:3776: error: invalid lvalue in assignment
ode_notrimesh.c:3784: error: invalid lvalue in assignment

gcc42:
ode_notrimesh.c:3776: error: lvalue required as left operand of assignment
ode_notrimesh.c:3784: error: lvalue required as left operand of assignment

All errors point to expressions like this:

((PyObject*)__pyx_v_m) = Py_None; /* __pyx_v_m is pointer to some struct /*

Actual cause of the problem is that erroneous code was generated by old version of pyrex (0.9.3) (while pyrex 0.9.4.1 gives correct code), so this error may be encountered in not-updated-for-a-long-time python modules. I've notified upstream developers via py-ode maillist, and made a patch (don't want to add pyrex dependancy) to change above mentioned code like that:

__pyx_v_m = (struct somestruct*)Py_None;

, which solves the problem and also matches pyrex 0.9.4.1 output.

How-To-Repeat: Build py-ode with gcc4x
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2007-02-09 21:50:15 UTC
Responsible Changed
From-To: freebsd-ports-bugs->freebsd-python

freebsd-python@ wants to have py- PRs
Comment 2 Martin Wilke freebsd_committer freebsd_triage 2007-02-10 09:15:14 UTC
Responsible Changed
From-To: freebsd-python->miwi

I'll take it.
Comment 3 dfilter service freebsd_committer freebsd_triage 2007-02-10 13:17:51 UTC
miwi        2007-02-10 13:17:47 UTC

  FreeBSD ports repository

  Modified files:
    devel/py-ode         Makefile 
  Log:
  - Fix build with gcc 4.X
  
  PR:             108994
  Submitted by:   Dmitry Marakasov <amdmi3@amdmi3.ru> (maintainer)
  
  Revision  Changes    Path
  1.2       +5 -0      ports/devel/py-ode/Makefile
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 4 Martin Wilke freebsd_committer freebsd_triage 2007-02-10 13:17:59 UTC
State Changed
From-To: open->closed

Committed. Thanks!