Strum / Strums_Mental_VCV_Modules

Strum's Mental Modules for VCV Rack
BSD 3-Clause "New" or "Revised" License
63 stars 15 forks source link

build fail with new module #4

Closed davephillips closed 6 years ago

davephillips commented 6 years ago

Building from fresh git pull on Fedora 21, GCC 4.9.2, pretty old system :

g++ -fPIC -I../../include -I../../dep/include -MMD -O3 -march=nocona -ffast-math -Wall -Wextra -Wno-unused-parameter -g -DARCH_LIN -std=c++11 -c -o build/src/MentalCartesian.cpp.o src/MentalCartesian.cpp src/MentalCartesian.cpp:52:44: error: too many initializers for ‘float [4][4]’ 0.0,0.0,0.0,0.0}; ^ src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:52:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: too many initializers for ‘float [4][4]’ 0.0,0.0,0.0,0.0}; ^ src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer src/MentalCartesian.cpp:57:44: error: array must be initialized with a brace-enclosed initializer ../../compile.mk:51: recipe for target 'build/src/MentalCartesian.cpp.o' failed make: *** [build/src/MentalCartesian.cpp.o] Error 1

Strum commented 6 years ago

hmm not had a problem here but i am only building it on windows

could be something with your setup.

i'm trying to work out a better way to initialise the arrays but haven't got that sorted out yet.

davephillips commented 6 years ago

This problem is solved here.

The form :

{0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, ... 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0};

should be changed to

{{0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0}, {0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0}, ... {0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0}};

and the error disappears.

Strum commented 6 years ago

cool, thought that might be the issue, strange how it compiles ok in windows.

will sort it out in the next couple of days, got gigs this weekend so not much time for development.