[Cs-dev] OSC re-entry..
Date | 2014-03-07 23:29 |
From | Rory Walsh |
Subject | [Cs-dev] OSC re-entry.. |
Attachments | None None |
Oeyvind has brought to my attention the fact that some of his Cabbage OSC instruments are causing a crash. I tried here and if I open, close and reopen the same csd file containing a call to OSCListen I get a segfault. Here's the backtrace. I don't get the same problem on Linux. I can try to prepare a simple example tomorrow, but I just thought I'd post in case anyone spots anything obvious. It looks like the ports are not being closed, and when the csd is opened again, and tries to access the same port it pulls the whole thing down.
0 0x6c5310bd cs_hash_table_remove C:\\Users\\Rory\\Documents\\SourceCode\\cabbageaudio\\csound6-git\\Engine\\csound_data_structures.c 219 1 0x6c5252da csoundDestroyGlobalVariable C:\\Users\\Rory\\Documents\\SourceCode\\cabbageaudio\\csound6-git\\Engine\\namedins.c 293
2 0x67a81b91 OSC_reset c:/Users/mike/csound-csound6-git/Opcodes/OSC.c 238 3 0x6c66681c reset C:\\Users\\Rory\\Documents\\SourceCode\\cabbageaudio\\csound6-git\\Top\\csound.c 2643 4 0x6c666f55 csoundReset C:\\Users\\Rory\\Documents\\SourceCode\\cabbageaudio\\csound6-git\\Top\\csound.c 2787
5 0x006d33c2 Csound::Reset C:\\Users\\Rory\\Documents\\SourceCode\\cabbageaudio\\csound6-git\\include\\csound.hpp 367 6 0x00472b5d CabbagePluginAudioProcessor::reCompileCsound |
Date | 2014-03-08 07:51 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | example1.cpp OSCListen.csd None None |
Attached is a simple program that will illustrate the problem. In one case I simply recompile Csound, in the other I delete my Csound object and create a new instance. Both cases results in the same problem.
OSC server error 9904 in path (null): cannot find free port Csound tidy up: Segmentation violation Once again, this seems related to Windows only. On 7 March 2014 23:29, Rory Walsh <rorywalsh@ear.ie> wrote:
|
Date | 2014-03-08 08:07 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
Ok, tested on OSX and passed. I will try to look what the matter is on Windows later. Victor On 8 Mar 2014, at 07:51, Rory Walsh |
Date | 2014-03-08 08:12 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
I'm trying to build liblo for windows so I can step through this and give you some more info, but I can't seem to get it to build. The make file generated by config contains some errors. I fixed a few but the rest are beyond me.
On 8 March 2014 08:07, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote: Ok, tested on OSX and passed. I will try to look what the matter is on Windows later. |
Date | 2014-03-08 10:00 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
try the previous version. On 8 Mar 2014, at 08:12, Rory Walsh |
Date | 2014-03-08 10:29 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
It couldn’t find pthread in MinGW, but it build OK in mingw64.Now trying to add it to Csound. Victor On 8 Mar 2014, at 10:00, Victor Lazzarini |
Date | 2014-03-08 11:11 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
Of course, that was bound to happen: it works here. This is a 64bit Windows build, so it’s different from the released version. Also it includes the fixes to the build options that Steven did, which fixed the soundfont issues on Windows. It could be related. I will try to get liblo to build on 32bit to see if there is any difference. ============== 0dBFS level = 32768.0 Csound version 6.02.0 (double samples) Feb 26 2014 libsndfile-1.0.25 UnifiedCSD: OSCListen.csd STARTING FILE Creating options Creating orchestra Creating score rtaudio: PortAudio module enabled ... using callback interface Elapsed time at end of orchestra compile: real: 0.001s, CPU: 0.000s sorting score ... ... done Elapsed time at end of score sort: real: 0.001s, CPU: 0.000s Csound version 6.02.0 (double samples) Feb 26 2014 graphics suppressed, ascii substituted 0dBFS level = 32768.0 orch now loaded audio buffered in 4096 sample-frame blocks PortAudio V19-devel (built Feb 26 2014 13:47:19) 0: dac0 (Microsoft Sound Mapper - Output) 1: dac1 (Headphones (High Definition Aud) 2: dac2 (Speakers (High Definition Audio) PortAudio: selected output device 'Headphones (High Definition Aud' writing 8192 sample blks of 64-bit floats to dac SECTION 1: Csound is already started, call csoundReset() before starting again ftable 1: ftable 1: 2 points, scalemax 0.000 new alloc for instr 1: B 0.000 .. 2.000 T 2.000 TT 2.000 M: 0.0 0.0 Score finished in csoundPerform(). resetting Csound instance handle=0 OSC deinitiatised inactive allocs returned to freespace end of score. overall amps: 0.0 0.0 overall samples out of range: 0 0 0 errors in performance Elapsed time at end of performance: real: 1.981s, CPU: 2.001s closing device 22 8192 sample blks of 64-bit floats written to dac 0dBFS level = 32768.0 Csound version 6.02.0 (double samples) Feb 26 2014 libsndfile-1.0.25 end of score. overall amps: 0.0 overall samples out of range: 0 0 errors in performance Elapsed time at end of performance: real: 0.000s, CPU: 0.000s 0dBFS level = 32768.0 Csound version 6.02.0 (double samples) Feb 26 2014 libsndfile-1.0.25 UnifiedCSD: OSCListen.csd STARTING FILE Creating options Creating orchestra Creating score rtaudio: PortAudio module enabled ... using callback interface Elapsed time at end of orchestra compile: real: 0.001s, CPU: 0.000s sorting score ... ... done Elapsed time at end of score sort: real: 0.001s, CPU: 0.000s Csound version 6.02.0 (double samples) Feb 26 2014 graphics suppressed, ascii substituted 0dBFS level = 32768.0 orch now loaded audio buffered in 4096 sample-frame blocks PortAudio V19-devel (built Feb 26 2014 13:47:19) 0: dac0 (Microsoft Sound Mapper - Output) 1: dac1 (Headphones (High Definition Aud) 2: dac2 (Speakers (High Definition Audio) PortAudio: selected output device 'Headphones (High Definition Aud' writing 8192 sample blks of 64-bit floats to dac SECTION 1: ftable 1: ftable 1: 2 points, scalemax 0.000 new alloc for instr 1: B 0.000 .. 2.000 T 2.000 TT 2.000 M: 0.0 0.0 Score finished in csoundPerform(). handle=0 OSC deinitiatised inactive allocs returned to freespace end of score. overall amps: 0.0 0.0 overall samples out of range: 0 0 0 errors in performance Elapsed time at end of performance: real: 1.989s, CPU: 2.008s closing device 22 8192 sample blks of 64-bit floats written to dac On 8 Mar 2014, at 10:29, Victor Lazzarini |
Date | 2014-03-08 11:46 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
OK, confirmed on 32-bit exe, it runs with no segfaults. So this must have been fixed. Victor On 8 Mar 2014, at 11:11, Victor Lazzarini |
Date | 2014-03-08 12:31 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
Can you send me a liblo library?
On 8 Mar 2014 11:46, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
OK, confirmed on 32-bit exe, it runs with no segfaults. So this must have been fixed. |
Date | 2014-03-08 12:34 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
32bit windows or 64bit windows? On 8 Mar 2014, at 12:31, Rory Walsh |
Date | 2014-03-08 13:20 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
Do you happen to have pre-compiled 32-bit windows binary? I searched the package you send my via dropbox and could find any libs in there. I still can't get past the make errors with the previous version of liblo either.
On 8 March 2014 12:34, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote: 32bit windows or 64bit windows? |
Date | 2014-03-08 15:38 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
It’s there (in src/.libs), but you can also just type make install in the msys shell. Victor On 8 Mar 2014, at 13:20, Rory Walsh |
Date | 2014-03-08 16:51 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
Thanks Victor. I seem to be missing a cmake flag for building the OSC opcodes. I have BUILD_OSC_OPCODES turned on and I also set LIBLO_LIBRARY. Where do I set the location of the headers? I tried: OSC_HEADER:PATH=C:/Users/Rory/Documents/SourceCode/liblo-0.27 But it bawks and says it can't find lo/lo.h. What am I missing? On 8 March 2014 15:38, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote: It’s there (in src/.libs), but you can also just type make install in the msys shell. |
Date | 2014-03-08 17:13 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
yes, that’s a pain. Copy the header directory (lo) into the MinGW/include/ directory and try again. Victor On 8 Mar 2014, at 16:51, Rory Walsh |
Date | 2014-03-08 17:31 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
Still no play. fatal error: lo/lo.h: No such file or directory #include <lo/lo.h> ^ compilation terminated.
Opcodes\CMakeFiles\osc.dir\build.make:57: recipe for target 'Opcodes/CMakeFiles/ osc.dir/OSC.c.obj' failed mingw32-make[2]: *** [Opcodes/CMakeFiles/osc.dir/OSC.c.obj] Error 1 CMakeFiles\Makefile2:462: recipe for target 'Opcodes/CMakeFiles/osc.dir/all' fai
led mingw32-make[1]: *** [Opcodes/CMakeFiles/osc.dir/all] Error 2 Makefile:145: recipe for target 'all' failed mingw32-make: *** [all] Error 2 Here's ls from my mingw/include dir:
-rw-r--r-- 1 Rory Administ 14497 Aug 28 2013 ansidecl.h -rw-r--r-- 1 Rory Administ 228276 Aug 28 2013 bfd.h -rw-r--r-- 1 Rory Administ 31405 Aug 28 2013 bfdlink.h
-rw-r--r-- 1 Rory Administ 17641 Aug 28 2013 dis-asm.h drwxr-xr-x 3 Rory Administ 0 Dec 7 15:13 gdb -rw-r--r-- 1 Rory Administ 2754 Aug 28 2013 gnumake.h
-rw-r--r-- 1 Rory Administ 3700 Aug 28 2013 libmangle.h drwxr-xr-x 16 Rory Administ 4096 Mar 8 17:16 lo -rw-r--r-- 1 Rory Administ 2198 Aug 28 2013 symcat.h
I also tried placing it in Opcodes folder that houses the OSC.c file but no joy there either. Any other ideas? |
Date | 2014-03-08 17:33 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
Whoa. Turns out there are two include folders in my mingw dir. Placing it in the second one worked. Just building now.. On 8 March 2014 17:31, Rory Walsh <rorywalsh@ear.ie> wrote:
|
Date | 2014-03-08 17:36 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
That does not look like the correct directory. C:/MinGW/include should have many more files and subdirectories. Victor On 8 Mar 2014, at 17:31, Rory Walsh |
Date | 2014-03-08 17:53 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
Ok, I can build now but when I run Csound it gives me lots of .dll errors about MSVCR100. So I tried building it myself again, and if I don't run ./configure first it makes. It gives me a liblo.a which I then pass to cmake instead of your liblo.dll.a. Now when I run cmake I get: C:\Users\Rory\Documents\SourceCode\liblo-0.27\src\.libs\liblo.a(liblo_la-address .o): In function `lo_inaddr_find_iface': c:\Users\Rory\Documents\SourceCode\liblo-0.27\src/address.c:654: undefined refer
ence to `GetAdaptersAddresses@20' collect2.exe: error: ld returned 1 exit status Opcodes\CMakeFiles\osc.dir\build.make:90: recipe for target 'osc.dll' failed mingw32-make[2]: *** [osc.dll] Error 1
CMakeFiles\Makefile2:462: recipe for target 'Opcodes/CMakeFiles/osc.dir/all' fai led mingw32-make[1]: *** [Opcodes/CMakeFiles/osc.dir/all] Error 2 Makefile:145: recipe for target 'all' failed
mingw32-make: *** [all] Error 2 I'm going to see if I can get liblo building here. It should produce a .dll no?
On 8 March 2014 17:36, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote: That does not look like the correct directory. C:/MinGW/include should have many more files |
Date | 2014-03-08 18:23 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
I managed to build liblo myself. My build errors were all down to me not having mingw in the correct place. Oh well. That's a few hours I won't get back. But each time I run Csound I now get errors MSVCR110? I'm going to do another clean but this is annoying.
On 8 March 2014 17:53, Rory Walsh <rorywalsh@ear.ie> wrote:
|
Date | 2014-03-08 18:32 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
It seems that I can't avoid that MSVCR110 dependency that results from building the OSC opcodes. Anyhow, finally everything builds and no more problems. Thanks for the help. Rory.
On 8 March 2014 18:23, Rory Walsh <rorywalsh@ear.ie> wrote:
|
Date | 2014-03-08 19:05 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
did you get your test program to run? I guess the MSVCR110 must be in my Windows 7 system. On 8 Mar 2014, at 18:32, Rory Walsh |
Date | 2014-03-08 19:10 |
From | Rory Walsh |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None None |
The dependency is there when I build the liblo library from scratch too. I think one could go and modify the configure script for liblo and remove the need for the dependency, but I'm not going anywhere near it! My test program is running fine and I've sent Oeyvind an updated build. On the plus side I nearly have a complete Csound build on Windows. The option of cross-compiling mingw-32 builds from Linux would be a God-send. On 8 March 2014 19:05, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote: did you get your test program to run? I guess the MSVCR110 must be in my Windows 7 system. |
Date | 2014-03-08 20:14 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
yes, building on Windows is yucky. Having said that, I’ve got now a 32 and 64bit windows toolchains working, so I can debug stuff. On 8 Mar 2014, at 19:10, Rory Walsh |
Date | 2014-03-09 14:59 |
From | jpff@cs.bath.ac.uk |
Subject | Re: [Cs-dev] OSC re-entry.. |
Attachments | None |
Date | 2014-03-09 15:10 |
From | Victor Lazzarini |
Subject | Re: [Cs-dev] OSC re-entry.. |
I installed this one http://git-scm.com/download/win Victor On 9 Mar 2014, at 14:59, jpff@cs.bath.ac.uk wrote: > Do ypu have a version of git on Windows? I failed to get that aspect > working. Otherwise I have an XP-32bit Csound running, also for > debugging > ==John ff > Quoting Victor Lazzarini |