Linking error with new Matrix class


#1

So I’m just giving the new Matrix class a quick spin, but I’m running into some issues.

I’m getting linking errors when using any function that is defined in juce_Matrix.cpp

I’m running the latest tip on the develop branch and I can easily recreate this by making a new JUCE audio plugin, adding the dsp module and then adding the following line to the pluginProcessor constructor:
auto outputMatrix = dsp::Matrix<float>::identity ((size_t) 2);

This is the error I get:
Undefined symbols for architecture x86_64:
“juce::dsp::Matrix::identity(unsigned long)”, referenced from:
MatrixTestAudioProcessor::MatrixTestAudioProcessor() in libMatrixTest.a(PluginProcessor.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I’m building using Xcode 8.3.1.

Any suggestions?


#2

This issue has been reported on the GitHub repository here: https://github.com/WeAreROLI/JUCE/issues/244.

https://github.com/m-hilgendorf/JUCE/commit/53b2247753c7260609bb21a4dfb63ffa83d82c66 should fix the problem.


#3

Fixed on the develop branch

and cherry-picked onto the master branch


#4

That seems to have fixed it. Thanks!