[LAU] jack2 turned verbose

Robin Gareus robin at gareus.org
Fri Jun 1 12:52:03 UTC 2012


On 05/31/2012 01:58 AM, David Adler wrote:
> On Thu, May 31, 2012 at 1:00 AM, mark hadman wrote:
> 
>> I have the same verbose behaviour problem with jack2 on Arch Linux 64 bit.
> 
> Thanks Mark, good to know I'm not the only one.
> I have it on both, 64 and 32 bit.
> 
> best,
> d

It might have to do with Arch's compiler[-flags] and how jack2 uses
unions .. or scoping: JackGlobals vs Engine-Parameters.. although I
don't have an explanation.. all seems good.

A hunch: it could be caused by using 'server_ptr->verbose.b' (a union)
as boolean. The sever only checks "if (server_ptr->verbose.b)". The
union itself comprises other uninitialized values that could make it
evaluate to true (though it shouldn't, but maybe some compiler
optimization casts it to (int) instead of (bool) )


I know this is the '-users' list (I'm ccing jack-devel), but could
someone who experiences the problem try to track it down?

Basically just add a few printf()'s. Start at: common/JackControlAPI.cpp
- line 926 - before the call to  "new JackServer(..)" add

  printf("DEBUG verbose: %s\n",(server_ptr->verbose.b)?"on":"off");

recompile, launch jackd. If it prints "verbose: on", sth is wrong with
parameter initialization in main() or with using unions. If it's "off"
the problem sits deeper:

add a line just after common/JackServer.cpp line 66
  printf("DEBUG verbose2: %s\n",(JackGlobals::fVerbose)?"on":"off");
...

A crude test for the union() hunch would be to change
common/JackControlAPI.h line 53:
 replace
  "union jackctl_parameter_value"
with
  "struct jackctl_parameter_value"

and compile with '-fpermissive' like this:

  CXXFLAGS="-fpermissive" ./waf  configure
  ./waf

..not sure if that'll work though..

HTH,
robin


More information about the Linux-audio-user mailing list