v7b1 / mi-UGens

some mutable instruments eurorack modules ported to SuperCollider
179 stars 20 forks source link

Error in build.sh #15

Closed gilfuser closed 2 years ago

gilfuser commented 2 years ago

Hi there!

Thanks for everybody involved in this beautiful project.

Trying to build i got this error: ./build.sh: 6: Syntax error: "(" unexpected

I thought I could simply change parenthesis for brackets. This make it pass the error, but will result in ./build.sh: 21: Bad substitution

v7b1 commented 2 years ago

Hi Gil - that sounds weird. I just cloned the repo on a new M1 machine and built all the projects with the included build.sh script. No problems with brackets/parenthesis, the built went fine - only Ripples doesn't compile on the M1 at the moment. What os are you on? Are you able to build single UGens without using build.sh?

gilfuser commented 2 years ago

Hi I'm using UbuntuStudio 22.04 I'm not able to build single UGens without build.sh, probably because I don't know how to do it properly. Here is what I'm doing:

cd MiWarps
cmake -DSC_PATH=/../../supercollider -DCMAKE_BUILD_TYPE=Release . 
cmake --build . --config Release

this will give me

Consolidate compiler generated dependencies of target MiWarps
[ 11%] Building CXX object CMakeFiles/MiWarps.dir/home/skmecs/builds/mi-UGens/eurorack/stmlib/utils/random.cc.o
[ 22%] Building CXX object CMakeFiles/MiWarps.dir/home/skmecs/builds/mi-UGens/eurorack/stmlib/dsp/units.cc.o
[ 33%] Building CXX object CMakeFiles/MiWarps.dir/home/skmecs/builds/mi-UGens/eurorack/warps/dsp/filter_bank.cc.o
[ 44%] Building CXX object CMakeFiles/MiWarps.dir/home/skmecs/builds/mi-UGens/eurorack/warps/dsp/modulator.cc.o
[ 55%] Building CXX object CMakeFiles/MiWarps.dir/home/skmecs/builds/mi-UGens/eurorack/warps/dsp/oscillator.cc.o
[ 66%] Building CXX object CMakeFiles/MiWarps.dir/home/skmecs/builds/mi-UGens/eurorack/warps/dsp/vocoder.cc.o
[ 77%] Building CXX object CMakeFiles/MiWarps.dir/home/skmecs/builds/mi-UGens/eurorack/warps/resources.cc.o
[ 88%] Building CXX object CMakeFiles/MiWarps.dir/MiWarps.cpp.o

/home/skmecs/builds/mi-UGens/MiWarps/MiWarps.cpp:31:10: fatal error: SC_PlugIn.h: No such file or directory
   31 | #include "SC_PlugIn.h"
      |          ^~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [CMakeFiles/MiWarps.dir/build.make:174: CMakeFiles/MiWarps.dir/MiWarps.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/MiWarps.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2
v7b1 commented 2 years ago

Looks like it can't find the sc sources, make sure the path is correct.

v7b1 commented 2 years ago

@gilfuser and I would recommend to use a build folder:

cd MiWarps mkdir build && cd build cmake -DSC_PATH=/path/to/sc-sources -DCMAKE_BUILD_TYPE=Release .. (two dots!) cmake --build . --config Release

gilfuser commented 2 years ago

The path was incorrect. So, building individual UGens work.