Re: [sage-devel] redefinition of sage_malloc

2015-04-05 Thread Jeroen Demeyer
I created http://trac.sagemath.org/ticket/18125 (but like I said, I cannot reproduce your problem) -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsub

Re: [sage-devel] redefinition of sage_malloc

2015-04-05 Thread Jeroen Demeyer
After removing the stuff about homotopyPath, I cannot reproduce your problem. I can see several reasons: (A) The problem is really with homotopyPath (B) Your Sage build is broken (obvious question: did you run make?) (C) Your GCC version plays a role If you want to help debugging this, could you

Re: [sage-devel] redefinition of sage_malloc

2015-04-05 Thread mmarco
What is the difference? El domingo, 5 de abril de 2015, 9:17:39 (UTC+2), Jeroen Demeyer escribió: > > This line is very likely to be relevant (you should have mentioned in > your original bug report that you were talking about a loaded/attached > file) > > On 2015-04-04 12:14, mmarco wrote > >

Re: [sage-devel] redefinition of sage_malloc

2015-04-05 Thread Jeroen Demeyer
This line is very likely to be relevant (you should have mentioned in your original bug report that you were talking about a loaded/attached file) On 2015-04-04 12:14, mmarco wrote ### reloading attached file my_library.pyx modified at 10:13:30 ### -- You received this message because you are

Re: [sage-devel] redefinition of sage_malloc

2015-04-04 Thread mmarco
Thank you for the answer, but it still doesn't work. The solution with check_allocarray now gives the following message: ### reloading attached file my_library.pyx modified at 10:13:30 ### Compiling /home/mmarco/integrado/my_library.pyx... Error compiling cython file: Error converting /home/mmarc

Re: [sage-devel] redefinition of sage_malloc

2015-04-03 Thread Jeroen Demeyer
The minimal fix is to add include "sage/ext/stdsage.pxi" However, you better use check_allocarray() instead, for which you also need to add from sage.ext.memory import check_allocarray and then replace c_values = sage_malloc(sizeof(double)*len(values)) by c_values = check_allocarray(len(v

[sage-devel] redefinition of sage_malloc

2015-04-03 Thread mmarco
I am having some trouble writing a cython interface to a library. It does something pretty simple: creates a malloc'ed array of values, passes it to a external function in the library, and gets a malloc'ed array back. In the past i made something similar to this work: #clib homotopyPath cde