Kali Linux upload error missing libreadline.so.6

Any insight on this one would be most appreciated.

Fresh install of 1.8.2 on Kali Linux 4.9 64 bit

After editing the bash install file, I was able to install the IDE without issue.

I can compile my program and use the serial/USB port for monitoring but...

When I try to upload my file, I get the following error:

An error occurred while uploading the sketch
/root/.arduino15/packages/arduino/tools/avrdude/6.0.1-arduino5/bin/avrdude: error while loading shared libraries: libreadline.so.6: cannot open shared object file: No such file or directory

So I checked my linking and found that libreadline.so.6 is missing:

root@kali-Alien:~# ldconfig -p | grep libreadline
libreadline.so.7 (libc6,x86-64) => /lib/x86_64-linux-gnu/libreadline.so.7
libreadline.so.5 (libc6,x86-64) => /lib/x86_64-linux-gnu/libreadline.so.5

So at the suggestion of google I created a soft link from 6 to 7

root@kali-Alien:~# ln -s /usr/lib/libreadline.so.7 /usr/lib/libreadline.so.6

but that didn't work either.

As a last ditch I downloaded the -dev library

root@kali-Alien:~# apt-get install libreadline-dev

No joy there either.

Any help would be most appreciated.

Thanks

Rick

Found a solution.

I had to download and extract the libreadline 6.3 file from here.

https://ftp.gnu.org/gnu/readline/

Then:

Go to your downloaded file

cd Downloads/readline*

Run config

./configure

Then

make && make install

And finally reset your links with

ldconfig

Rick