Closed rbnpi closed 4 years ago
Umm, interesting, I'll have a look.
On Sat, 30 May 2020, 13:49 Robin Newman, notifications@github.com wrote:
Just built 64bit Sonic Pi 3.2.2 on raspberry pi 64bit beta OS It works OK including using OSC messages but no midi.. Both m2o and o2m are giving error messages.
o2m: /home/pi/Downloads/osmid/external_libs/oscpack_1_1_0/osc/OscOutboundPacketStream.cpp:166: osc::OutboundPacketStream::OutboundPacketStream(char*, std::size_t): Assertion `sizeof(osc::int32) == 4' failed.
m2o: /home/pi/Downloads/osmid/external_libs/oscpack_1_1_0/osc/OscOutboundPacketStream.cpp:166: osc::OutboundPacketStream::OutboundPacketStream(char*, std::size_t): Assertion `sizeof(osc::int32) == 4' failed.
Not sure if the problem is in SP or osmid. I have built o0n other 64bit OS eg ubuntu 20.03 without problem. Any ideas appreciated about whre to start looking. both m2o and o2m behave ok when listing midi sources using -l parameter.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/llloret/osmid/issues/58, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJOL43GRI7TLEVC6GMIJFDRUD6G3ANCNFSM4NOV3AFQ .
Ok, so this is the code in oscpack (one of the open source libs I am using in osmid) that is triggering the assertion, and that might explain why MIDI has stopped working, because the types are not matching their expected sizes anymore. I'll see if this has been fixed upstream, and update the oscpack library version: OutboundPacketStream::OutboundPacketStream( char *buffer, std::sizet capacity ) : data( buffer ) , end( data + capacity ) , typeTagsCurrent( end ) , messageCursor( data ) , argumentCurrent( data ) , elementSizePtr( 0 ) , messageIsInProgress( false ) { // sanity check integer types declared in OscTypes.h // you'll need to fix OscTypes.h if any of these asserts fail assert( sizeof(osc::int32) == 4 ); assert( sizeof(osc::uint32) == 4 ); assert( sizeof(osc::int64) == 8 ); assert( sizeof(osc::uint64) == 8 ); }
Thank you for bringing this to my attention.
Hi, @rbnpi , I have a potential fix for this. The problem is that I do not have a system to easily replicate it.
Can you please try the fix that I put in the branch fix_oscpack_types
(pr #59 )? I've tested it on Windows and Linux and it seems ok. If it works for the system that is causing you trouble, I'll update master and tag a new release.
Thank you, Luis
@rbnpi , I see that that there is a new package for the raspberry pi 64 bits. Were you able to make it work with the fix in branch fix_oscpack_types
? I would really want to know so that I can make the fix final.
Thank you
tried building on the Raspbery Pi 64bit OS with the modified OscTypes.h file Wont compile error shown below.
Building CXX object external_libs/oscpack_1_1_0/CMakeFiles/oscpack.dir/osc/OscReceivedElements.cpp.o
cd /home/pi/Downloads/osmid/build/external_libs/oscpack_1_1_0 && /usr/bin/c++ -I/home/pi/Downloads/osmid/external_libs/oscpack_1_1_0 -std=c++14 -Wall -Wextra -Wno-long-long -pedantic -o CMakeFiles/oscpack.dir/osc/OscReceivedElements.cpp.o -c /home/pi/Downloads/osmid/external_libs/oscpack_1_1_0/osc/OscReceivedElements.cpp
In file included from /home/pi/Downloads/osmid/external_libs/oscpack_1_1_0/osc/OscReceivedElements.cpp:37:
/home/pi/Downloads/osmid/external_libs/oscpack_1_1_0/osc/OscReceivedElements.h:104:5: error: ‘osc::ReceivedPacket::ReceivedPacket(const char*, int)’ cannot be overloaded with ‘osc::ReceivedPacket::ReceivedPacket(const char*, osc::osc_bundle_element_size_t)’
ReceivedPacket( const char *contents, int size )
Otherwise SOnicPI 3.2.2 builds and runs fine on the 64bit OS. Only non working bit is osmid so no midi support at rpesent. All osc comms seem OK otherwise.
Let me know if any further info would be useful.
Hi, @rbnpi, can you check with the new contents of the branch?
gets a bit further now. similar probem here:
[ 22%] Building CXX object external_libs/oscpack_1_1_0/CMakeFiles/oscpack.dir/osc/OscOutboundPacketStream.cpp.o
cd /home/pi/Downloads/osmid/build/external_libs/oscpack_1_1_0 && /usr/bin/c++ -I/home/pi/Downloads/osmid/external_libs/oscpack_1_1_0 -std=c++14 -Wall -Wextra -Wno-long-long -pedantic -o CMakeFiles/oscpack.dir/osc/OscOutboundPacketStream.cpp.o -c /home/pi/Downloads/osmid/external_libs/oscpack_1_1_0/osc/OscOutboundPacketStream.cpp
In file included from /home/pi/Downloads/osmid/external_libs/oscpack_1_1_0/osc/OscOutboundPacketStream.cpp:37:
/home/pi/Downloads/osmid/external_libs/oscpack_1_1_0/osc/OscOutboundPacketStream.h:109:27: error: ‘osc::OutboundPacketStream& osc::OutboundPacketStream::operator<<(int)’ cannot be overloaded with ‘osc::OutboundPacketStream& osc::OutboundPacketStream::operator<<(osc::int32)’
OutboundPacketStream& operator<<( int rhs )
made similar change to OscOutboundPacketStream.h and looks like its building OK now. About to test...
Yes with OscOutboundPacketStream.h patched as well (removing lines. 109 to 111 then it builds and works OK.Removed lines are below
#if !(defined(__x86_64__) || defined(_M_X64))
OutboundPacketStream& operator<<( int rhs )
{ *this << (int32)rhs; return *this; }
#endif
Brilliant, I'll merge into master. Thank you for your work on this.
Thanks!
Just built 64bit Sonic Pi 3.2.2 on raspberry pi 64bit beta OS It works OK including using OSC messages but no midi.. Both m2o and o2m are giving error messages.
Not sure if the problem is in SP or osmid. I have built o0n other 64bit OS eg ubuntu 20.04 without problem. Any ideas appreciated about whre to start looking. both m2o and o2m behave ok when listing midi sources using -l parameter.