Build tools?

Hi,.

I’m trying to be able to build externals on the organelle - presuming I need to compile on the organelle itself?

I’ve got @thetechnobear Mutable ports as a starting point and just trying to build those to make sure I’ve got everything - I can make them on my Mac

On the organelle - just trying to install CMake:

pacman -S cmake

error: failed retrieving file ‘jsoncpp-1.6.5-1-armv7h.pkg.tar.xz’ from mirror.archlinuxarm.org : The requested URL returned error: 404
warning: failed to retrieve some files
error: failed retrieving file ‘cmake-3.3.2-3-armv7h.pkg.tar.xz’ from mirror.archlinuxarm.org : The requested URL returned error: 404
warning: failed to retrieve some files

I suspect i need to update the pacman db or something but can’t work out how to do that?

any tips?

(and any pointers if I am going about the whole building externals thing the right way - I’ve got some ideas for Orac modules but my C/C++ is much stronger than my PD these days and easier to just make an external :slight_smile: )

pacman -Sy will update the database.

be careful what you update on the Organelle, arch linux uses a continuous upgrade model… so using the latest and greatest, but if you try to upgrade everything you will find the organelle does not boot.
so you need to do partial upgrades, but that is not a supported model on arch Linux, which means you might find that you get incompatibilities creeping in.
… so you need to take care.

obviously all the things needed to build on my stuff work fine.

one warning, do not attempt to install gdb, this will not work it requires an upgrade readline, which will then break tons of other stuff.

theoretically, you could cross-compile, but i find that more effort than its worth.

what i tend to do is:

  • develop on the mac (but making sure it cross-platform)
  • once its working, compile on organelle.
  • if there are issues, only on the Organelle, i then build on a rPI and see if its an issue there where i have gdb etc.
    (another option would be to cross compile on the rPI, since that’s basically the same environment, just different compile options)

one word of warning, the version of gcc on the organelle is a bit older, and it has issue with static initialisation, which can cause some odd issues in PD , they are a pain to find - since you don’t have any tools on the Organelle to tell you whats going on.
so be very careful with statics.

oh… and as with all cross-platform dev, test regularly on all platforms… much easier to spot problem early, that when you written/changed 1000’s of lines of code :wink:

yup same here, i think PD is best used as glue.
C++ is much more efficient, and also better structured… once you’ve written a couple of externals, its tempting to do as little as possible in PD :wink:

95% (probably more) of Orac is C++ … with only a thin wrapping to make it an 2 externals… which has the advantage much of the code could be moved to support (e.g) supercollider.

that said, PD is quite good for knocking stuff up quickly/prototyping, i guess i just don’t think it scales well.
(actually i think this is true of Axoloti/Max, so all visual patching really)

ok cool - thank you - some helpful tips.

Glad it’s not just me on the visual patching front (one reason I’ve taken to supercollider - much prefer code)

one last question - I’m getting

error: failed to commit transaction (conflicting files)
libnsl: /usr/include/rpcsvc/nis.h exists in filesystem

I’m, guessing I need to upgrade that package? or perhaps remove that package and replace it with another - eek!

Ive not seen (afaik) that, so no idea…

as you say, sounds like another package needs upgrading, but no idea which/

unfortunately, although ive actually installed the dev tools etc on multiple organelles many times, i also install other things, (e.g. for otc dev) so it might be these upgraded something else.
if you have a lot of work on the organelle sd card, id recommend you back it up if your unsure.

for me, ive all my code in GitHub, so i just go with it, knowing I can rebuild my dev environment reasonably quickly - faster than backing up regularly - and its only bitten me a couple of times :wink:

ok for reference here:

pacman -Sy
pacman -S gcc glibc cmake libmpc libtirpc mpfr pam

gives a working build environment

2 Likes

hmm ha ha

So - ADVICE - make copies of things prior to trying any of this.

In other news this: https://www.paragon-software.com/home/extfs-mac/ lets you mount your Organelle SD card on a Mac!

(also managed to take out organelle SD card and put it back in several times without losing it inside the organelle!)

ha ha, i did warn you :wink:

yeah, I use a linux box to mount sdcards on if i need to ‘rescue’ them…
(using a virtual machine, which is quite handy to have around anyway… so Im can combine x86_64 linux binaries)

yeah - since I’ve stopped earning my living writing code (my job has ‘evolved’ & I let other younger more competent engineers do the coding :slight_smile: ) my tool set is a bit neglected and I’ve not got separate VMs set up any more,

All working well now though and I can setup the organelle from an empty SD card in ~10 mins now!

ripping out the quantiser from braids into a separate module for my first go - I’ve got some ideas for generative modules I want to make…

3 Likes

braids is a good source of code for a few things… unlike some MI modules its got quite a few bits that are independent e.g. all the ‘oscillators’ (except complex) are all separate classes :slight_smile:

generative sounds good not something I did any off , and with new synths/fx could be a rich vein of discovery.

quantizer, yeah, I think one that handles multiples scales would be very useful, a kind of ‘uScale’ , handy for things like turing machine.

I have a working quantiser! (it only does major scales but it works)

the braids one works on some internal voltage number so wrote my own midi number based one instead.

(only exciting to me - but pleased with my progress - watch this space for some generative music modules now )

2 Likes

Awesome :slight_smile:
I believe @thetechnobear has made a quantiser in PD before? Might be misremembering. Otherwise there is certainly a good one in ‘turingmachina’ by ringhof.

I’ve not found anything that is quite what I have in mind

Also good to limber up on it - last time I wrote PD externals was nearly 20 years ago! it’s all coming back though :slight_smile:

there’s a working Quantizer in else and i just uploaded the raspi externals for it yesterday

pp

Help–>get externals [else]

greets

there’s alos a scale/mode based on that works very well in Automationism

cheers - I’ll take a look