Created
January 11, 2020 20:15
-
-
Save darosior/a5d93c6245a32f7a8bed2ac4e33a0011 to your computer and use it in GitHub Desktop.
Install libdb4.8 on Debian (from Ubuntu ppa) for i386 or amd64
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
if [ "$#" -ne "1" ]; then | |
echo "usage :" | |
echo " $0 <amd64|i386>" | |
elif ! [ "$1" = "amd64" ] && ! [ "$1" = "i386" ]; then | |
echo "Bad architecture argument. First and only argument must be amd64 or i386." | |
else | |
mkdir "tmplibdb" && cd "tmplibdb" | |
if [ "$1" = "amd64" ]; then | |
wget -qq "https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin/+files/libdb4.8_4.8.30-trusty1_amd64.deb" | |
wget -qq "https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin/+files/libdb4.8-dev_4.8.30-trusty1_amd64.deb" | |
wget -qq "https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin/+files/libdb4.8++_4.8.30-trusty1_amd64.deb" | |
wget -qq "https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin/+files/libdb4.8++-dev_4.8.30-trusty1_amd64.deb" | |
elif [ "$1" = "i386" ]; then | |
wget -qq "https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin/+files/libdb4.8_4.8.30-trusty1_i386.deb" | |
wget -qq "https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin/+files/libdb4.8-dev_4.8.30-trusty1_i386.deb" | |
wget -qq "https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin/+files/libdb4.8++_4.8.30-trusty1_i386.deb" | |
wget -qq "https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin/+files/libdb4.8++-dev_4.8.30-trusty1_i386.deb" | |
fi | |
dpkg -i *.deb | |
cd .. && rm -rf "tmplibdb" | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I was tired of setting up libdb4.8 each time I install core on a new machine so it's both a reminder and an useful access point, for example (as root because of
dpkg -i
):