I know I know nobody cares about s390 but on this platform we got this error during the build
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute.cpp:691:25: instantiated from here
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute_numpy.hpp:242:42: error: invalid initialization of reference of type 'Py_ssize_t& {aka long int&}' from expression of type 'npy_intp {aka int}'
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute_numpy.hpp:243:42: error: invalid initialization of reference of type 'Py_ssize_t& {aka long int&}' from expression of type 'npy_intp {aka int}'
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute.cpp: In function 'void PyDeviceAttribute::_fill_list_attribute(Tango::DeviceAttribute&, bool, const boost::python::api::object&) [with long int tangoTypeConst = 2l]':
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute.cpp:693:25: instantiated from here
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute.cpp:627:17: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute.cpp: In function 'void PyDeviceAttribute::_fill_list_attribute(Tango::DeviceAttribute&, bool, const boost::python::api::object&) [with long int tangoTypeConst = 3l]':
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute.cpp:693:25: instantiated from here
/build/buildd-pytango_8.0.3-1-s390-5JWxzh/pytango-8.0.3/src/boost/cpp/device_attribute.cpp:627:17: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
Indeed on this patform Py_ssize_t is a long int and npy_intp is a int..
the warning is just because I hate warning during the build :)
Cheers
Fred
Just for information this bug will block the migration of pytango AND tango into Debian testing.
Hello Tiago,
I try to understand the problem, so here is the offending code.
So npy_intp and Py_ssize_t are different on powerpc. I do not know why but
this is a fact.
Now I do not understant the comment about the isImage.
Why do you want to know the coordinates x and y ? can't you just push the data in the buffer the way they are filled in the numpy array.
to my opinion the code for the spectrum should work also for the image but instead of using coordinates you could use the total number of elements of the array.
Did I missed something ?
Cheers
Fred
Hi Frederic,
In fact I did not write the comment. It seems a little strange indeed.
I trust the guy who did it (Ramon Sune) so I prefer to leave it like that and do the fix with a simple cast for now.
Anyway I am thinking of trying to remove all numpy dependencies on C++ level so this code will disapeear in the future (if everything goes well :-)
proposed patch
can you confirm that it is ok ?
Hi Frederic,
I fixed it before seeing your proposed patch with a simple data type cast.
Sorry for that.
Hello,
Fixed in SVN trunk since revision #23071
Will become visible in next PyTango 8.0.4