Fix Ardour VAMP plugins (FFT)
authorRobin Gareus <robin@gareus.org>
Mon, 13 Jan 2020 23:43:34 +0000 (00:43 +0100)
committerRobin Gareus <robin@gareus.org>
Mon, 13 Jan 2020 23:52:24 +0000 (00:52 +0100)
Bug was introduced in 8ed33f1bc714c1 symbol visibility setting
in CFLAGS, CXXFLAGS was overridden. This resulted in publicly exposed
and bound kiss_fft symbols in libqm-dsp.

At runtime those symbols were resolved using previously bound
symbols in libcodec  (see below) that uses a mismatching implementation
(ardour/qm-dsp uses -Dkiss_fft_scalar=double)

#0  0x00007fffea793d40 in kiss_fftr () at /usr/lib/x86_64-linux-gnu/libcodec2.so.0.8.1
#1  0x00007fffcf4516ab in FFTReal::D::forward(double const*, double*, double*) (this=0x5555571d73a0, ri=0x55555a734810, ro=0x55555a7262b0, io=0x55555a728590)
    at ../libs/qm-dsp/dsp/transforms/FFT.cpp:121
#2  0x00007fffcf4510fd in FFTReal::forward(double const*, double*, double*) (this=0x555559868190, ri=0x55555a734810, ro=0x55555a7262b0, io=0x55555a728590)
    at ../libs/qm-dsp/dsp/transforms/FFT.cpp:186

libs/qm-dsp/wscript

index 728d1fa94e5add54ade8a0ee36815850ffbeca1d..e9573aeb97f93fe3a14ed98a6dc6c31bf426f635 100644 (file)
@@ -79,8 +79,8 @@ def build(bld):
     obj.vnum         = QM_DSP_VERSION
     obj.install_path = bld.env['LIBDIR']
     if bld.env['build_target'] != 'mingw':
-        obj.cxxflags = [  bld.env['compiler_flags_dict']['pic'] ]
-        obj.cflags = [ bld.env['compiler_flags_dict']['pic'] ]
+        obj.cxxflags += [ bld.env['compiler_flags_dict']['pic'] ]
+        obj.cflags   += [ bld.env['compiler_flags_dict']['pic'] ]
 
 
 def shutdown():