Arduino clean reinstall

System: Net boot Raspberry Pi 3 running Arduino 1.8.8.

Issue: After using the system for some considerable time (at least 2 years), installing numerous libraries and Board Support Packages plus a couple of failed attempts to install 1.8.10 I am receiving more and more 'duplicate library' and 'library function argument mismatch' warnings. I thinks it's time for a tidy up.

Arduino appears to have spread itself quite liberally about the system. So far I have found;

./.arduino15 and ./Arduino folders in my $HOME folder,

Arduino-1.8.8 and Arduino-1.8.10 folders in /opt

a link in /usr/local/bin pointing to a bash script in /opt/arduino-1.8.10/arduino

and I'm sure there's more to be found.

I want to completely erase all trace of Arduino from the machine and start with a completely clean installation. OK, a bit of work to put all of the libraries and BSPs back but it's all got rather out of hand.

Snag is, from previous experience, apt-get uninstall only does half a job and it certainly won't get rid of the additional libraries and BSPs. I will also need to find and update any startup or login scripts that set up Arduino specific environment variables or modifications to $PATH.

Can someone please point me in the right direction of what I need to do in terms of what to uninstall, what to simply delete and what scripts I may need to modify before I attempt to perform a clean install of 1.8.12. (Which I assume works where 1.8.10 didn't on the Pi)

P.S. The old Pi fix of simply reformatting the OS is not an option. This machine is used for far more than just Arduino development.

jwalters1955:
Arduino appears to have spread itself quite liberally about the system. So far I have found;

./.arduino15 and ./Arduino folders in my $HOME folder,

Arduino-1.8.8 and Arduino-1.8.10 folders in /opt

a link in /usr/local/bin pointing to a bash script in /opt/arduino-1.8.10/arduino

and I'm sure there's more to be found.

That should be it. Maybe you have other installations of the Arduino IDE itself. I don't know. I always manually install it, so I know exactly which installations I have and where they are.

If you ran the installation script, you can just open up the script in a text editor to see what else it does. I don't think there's any need for that though.

You might check for ~/.arduino left over from using one of the 1.0.x versions of the Arduino IDE. I'm actually not sure what the folder name was back then, but I know it wasn't ~

jwalters1955:
Snag is, from previous experience, apt-get uninstall only does half a job and it certainly won't get rid of the additional libraries and BSPs. I will also need to find and update any startup or login scripts that set up Arduino specific environment variables or modifications to $PATH.

Did you use apt-get install to install it?

jwalters1955:
I will also need to find and update any startup or login scripts that set up Arduino specific environment variables or modifications to $PATH.

Here's the installation script:

Here's an optional post-install script that needs to be run manually, so you should remember if you ran it:

Here's the script that starts the Arduino IDE:

That's everything.

jwalters1955:
Can someone please point me in the right direction of what I need to do in terms of what to uninstall, what to simply delete and what scripts I may need to modify before I attempt to perform a clean install of 1.8.12. (Which I assume works where 1.8.10 didn't on the Pi)

P.S. The old Pi fix of simply reformatting the OS is not an option. This machine is used for far more than just Arduino development.

I think you're going a bit overboard with this. You would likely be fine just deleting ~/Arduino and ~/.arduino15.

Thanks for the feedback, that's a job for the next day or so. To be perfectly honest, it's so long since I installed 1.8.8, I can't actually remember the mechanism I used and things do change with time.

I probably am, as you say, going over the top a bit but there are many hours of my life I won't get back due to some residual bit of an old version of something lying around the system and causing all manner of mayhem. Sometimes it doesn't hurt to deep clean right into the darkest corners.

Now this is why I wanted a clean install....

Downloaded Linux ARM 64 Bit, arduino-1.8.13-linuxaarch64.tar.xz (rpi 3, Quad Core 1.2GHz Broadcom BCM2837 64bit CPU) to $HOME/Downloads.

Unpacked to $HOME/Downloads/arduino-1.8.13

cd to $HOME/Downloads/arduino-1.8.13 and ran ./install.sh which failed due to access permissions.

sudo ./install.sh ran through apparently successfully and added Arduino icon to desktop.

Click icon, get egg timer for a few seconds then nothing.

Run home/john/Downloads/arduino-1.8.13/arduino from the command line and get;

./arduino: line 35: /home/john/Downloads/arduino-1.8.13/java/bin/java: cannot execute binary file: Exec format error

This is why I could never get 1.8.10 to run. What am I doing wrong?

Even though your RPi’s CPU is 64 bit, if your operating system is 32 bit, you still need to use the “Linux ARM 32 bits” download link for the Arduino IDE.

Yep, that'll do it. Bit like opening up the engine bay on your 911 and finding a 1300 Beetle engine!!!

All's happy now, thanks.

You're welcome. I'm glad to hear it's working now. There are 64 bit operating systems available for the RPi.