dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #09187
Re: error with instant
I think the "invalid conversion from const char* to char*" is a known
bug in swig 1.3.29.
--
Anders
On Wed, Aug 20, 2008 at 10:11:53AM -0400, Shawn Walker wrote:
> SWIG Version 1.3.29
>
> Compiled with g++ [x86_64-redhat-linux-gnu]
> Please see http://www.swig.org for reporting bugs and further information
>
> I can ask the admin people here to put version 1.3.36 on. Is this the
> problem?
>
> - Shawn
>
> On Wed, 20 Aug 2008, Martin Sandve Alnæs wrote:
>
>> Which version of swig do you have?
>>
>> swig -version
>>
>>
>>
>>
>> 2008/8/20 Shawn Walker <walker@xxxxxxxxxxxxxxx>:
>>> Here it is:
>>>
>>> ----------------------------------------------------
>>> running build_ext
>>> building '_inline_ext' extension
>>> gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O3 -Wall
>>> -Wstrict-prototypes -fPIC -I. -I/usr/local/pkg/Py
>>> thon-2.5/include/python2.5 -c inline_ext_wrap.cxx -o
>>> build/temp.linux-x86_64-2.5/inline_ext_wrap.o -O2
>>> cc1plus: warning: command line option "-Wstrict-prototypes" is valid for
>>> Ada/C/ObjC but not for C++
>>> inline_ext_wrap.cxx: In function int
>>> SWIG_Python_ConvertFunctionPtr(PyObject*, void**, swig_type_info*):
>>> inline_ext_wrap.cxx:2051: error: invalid conversion from const char* to
>>> char*
>>> inline_ext_wrap.cxx: In function void SWIG_Python_FixMethods(PyMethodDef*,
>>> swig_const_info*, swig_type_info**, s
>>> wig_type_info**):
>>> inline_ext_wrap.cxx:3094: error: invalid conversion from const char* to
>>> char*
>>> error: command 'gcc' failed with exit status 1
>>> ----------------------------------------------------
>>>
>>> - Shawn
>>>
>>> On Wed, 20 Aug 2008, Martin Sandve Alnæs wrote:
>>>
>>>> Can you post the contents of
>>>>>
>>>>> inline_ext/compile.log
>>>>
>>>> ?
>>>>
>>>>
>>>>
>>>>
>>>> 2008/8/20 Shawn Walker <walker@xxxxxxxxxxxxxxx>:
>>>>>
>>>>> No, that did not work either. Here is what I did:
>>>>>
>>>>> ------------------------
>>>>> $ python
>>>>> Python 2.5.2 (r252:60911, Aug 7 2008, 15:50:01)
>>>>> [GCC 4.1.2 20071124 (Red Hat 4.1.2-42)] on linux2
>>>>> Type "help", "copyright", "credits" or "license" for more information.
>>>>>>>>
>>>>>>>> from instant import inline
>>>>>>>> add_func = inline("double add(double a, double b){ return a+b; }")
>>>>>
>>>>> --- Instant: compiling ---
>>>>> --- Instant: compiling ---
>>>>> Traceback (most recent call last):
>>>>> File "<stdin>", line 1, in <module>
>>>>> File "/home/walker/build/lib/python2.5/site-packages/instant.py", line
>>>>> 792, in inline
>>>>> ext.create_extension(**args_dict)
>>>>> File "/home/walker/build/lib/python2.5/site-packages/instant.py", line
>>>>> 370, in create_extension
>>>>> raise RuntimeError("The extension module did not compile, check
>>>>> %s/compile.log" % self.module)
>>>>> RuntimeError: The extension module did not compile, check
>>>>> inline_ext/compile.log
>>>>>>>>
>>>>> ------------------------
>>>>>
>>>>> - Shawn
>>>>>
>>>>> On Wed, 20 Aug 2008, Kent-Andre Mardal wrote:
>>>>>
>>>>>>
>>>>>> Can you be more spesific ?
>>>>>>
>>>>>> Do eg. the follow work
>>>>>>
>>>>>>
>>>>>> from instant import inline
>>>>>>
>>>>>> add_func = inline("double add(double a, double b){ return a+b; }")
>>>>>>
>>>>>> print "The sum of 3 and 4.5 is ", add_func(3, 4.5)
>>>>>>
>>>>>>
>>>>>>
>>>>>> On ti., 2008-08-19 at 15:59 -0400, Shawn Walker wrote:
>>>>>>>
>>>>>>> Hello, I can't seem to run any of the tests with `instant'. I get
>>>>>>> errors
>>>>>>> that look like this:
>>>>>>>
>>>>>>> undefined symbol: Py_InitModule4
>>>>>>>
>>>>>>> I read somewhere that if you have multiple Python versions installed,
>>>>>>> this
>>>>>>> could cause the problem. I have 2.4 and 2.5 installed, but I am using
>>>>>>> 2.5. I had to do this because the default Python was 2.4 for all the
>>>>>>> computers. Does anyone know what to do here?
>>>>>>>
>>>>>>> - Shawn
>>>>>>> _______________________________________________
>>>>>>> DOLFIN-dev mailing list
>>>>>>> DOLFIN-dev@xxxxxxxxxx
>>>>>>> http://www.fenics.org/mailman/listinfo/dolfin-dev
>>>>>>
>>>>>>
>>>>> _______________________________________________
>>>>> DOLFIN-dev mailing list
>>>>> DOLFIN-dev@xxxxxxxxxx
>>>>> http://www.fenics.org/mailman/listinfo/dolfin-dev
>>>>>
>>>
>>
>>
> _______________________________________________
> DOLFIN-dev mailing list
> DOLFIN-dev@xxxxxxxxxx
> http://www.fenics.org/mailman/listinfo/dolfin-dev
Attachment:
signature.asc
Description: Digital signature
Follow ups
References
-
Visualizing basis functions
From: Evan Lezar, 2008-08-10
-
Re: Visualizing basis functions
From: Anders Logg, 2008-08-11
-
Re: Visualizing basis functions
From: Marie Rognes, 2008-08-18
-
error with instant
From: Shawn Walker, 2008-08-19
-
Re: error with instant
From: Kent-Andre Mardal, 2008-08-20
-
Re: error with instant
From: Shawn Walker, 2008-08-20
-
Re: error with instant
From: Martin Sandve Alnæs, 2008-08-20
-
Re: error with instant
From: Shawn Walker, 2008-08-20
-
Re: error with instant
From: Martin Sandve Alnæs, 2008-08-20
-
Re: error with instant
From: Shawn Walker, 2008-08-20