2018-11-29 09:03:22 +08:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
if [ -e /usr/bin/apt-get ]; then
|
2020-06-19 08:08:31 +08:00
|
|
|
export DEBIAN_FRONTEND=noninteractive
|
2018-11-29 09:03:22 +08:00
|
|
|
apt-get -qy update
|
2020-06-19 08:08:31 +08:00
|
|
|
apt-get -qy --no-install-suggests --no-install-recommends \
|
2018-11-29 09:03:22 +08:00
|
|
|
install \
|
2020-06-19 08:08:31 +08:00
|
|
|
ca-certificates \
|
|
|
|
build-essential \
|
|
|
|
git \
|
|
|
|
g++ \
|
|
|
|
debhelper \
|
|
|
|
automake \
|
2020-08-05 18:14:42 +08:00
|
|
|
fakeroot \
|
2020-06-19 08:08:31 +08:00
|
|
|
libtool \
|
|
|
|
lsb-release
|
|
|
|
apt-get -qy --no-install-suggests --no-install-recommends install python
|
|
|
|
apt-get -qy --no-install-suggests --no-install-recommends install python3
|
2018-11-29 09:03:22 +08:00
|
|
|
elif [ -e /usr/bin/dnf ]; then
|
|
|
|
dnf -y update
|
|
|
|
dnf -y install \
|
2020-06-19 08:08:31 +08:00
|
|
|
git rpm-build gcc-c++ make which python3 automake \
|
2018-11-29 09:03:22 +08:00
|
|
|
libtool gettext-devel
|
|
|
|
elif [ -e /usr/bin/yum ]; then
|
|
|
|
yum -y update
|
|
|
|
yum -y install \
|
|
|
|
git rpm-build gcc-c++ make which \
|
|
|
|
python python-argparse \
|
|
|
|
automake libtool gettext-devel
|
|
|
|
elif [ -e /sbin/apk ]; then
|
|
|
|
apk add \
|
|
|
|
abuild git gcc g++ make autoconf \
|
|
|
|
automake libtool gettext-dev linux-headers
|
2019-02-07 10:41:25 +08:00
|
|
|
elif [ -e /usr/sbin/pkg ]; then
|
|
|
|
pkg install \
|
|
|
|
git gmake gcc autoconf automake libtool \
|
|
|
|
gettext-tools
|
2018-11-29 09:03:22 +08:00
|
|
|
fi
|
2020-06-19 08:08:31 +08:00
|
|
|
|
|
|
|
if [ ! -e /usr/bin/python ]; then
|
|
|
|
if [ -e /usr/bin/python3 ]; then
|
|
|
|
ln -s /usr/bin/python3 /usr/bin/python
|
|
|
|
elif [ -e /usr/bin/python2 ]; then
|
|
|
|
ln -s /usr/bin/python2 /usr/bin/python
|
|
|
|
fi
|
|
|
|
fi
|