diff --git a/make-ring.py b/make-ring.py index f75a63a08c810736012953bcb63d61afc6d6bb4f..6bbedf84f1c0f5f052ea8765dc50016486844727 100755 --- a/make-ring.py +++ b/make-ring.py @@ -28,6 +28,10 @@ PACMAN_BASED_DISTROS = [ 'Arch Linux', ] +SUSE_BASED_DISTROS = [ + 'openSUSE', +] + APT_INSTALL_SCRIPT = [ 'apt-get update', 'apt-get install -y %(packages)s' @@ -49,6 +53,27 @@ PACMAN_INSTALL_SCRIPT = [ 'sudo pacman -S %(packages)s' ] +ZYPPER_INSTALL_SCRIPT = [ + 'sudo zypper update', + 'sudo zypper install -y %(packages)s' +] + +OPENSUSE_DEPENDENCIES = [ +# build system + 'autoconf', 'automake', 'cmake', 'patch', 'gcc-c++', 'libtool', +# daemon + 'speexdsp-devel', 'speex-devel', 'libdbus-c++-devel', 'jsoncpp-devel', 'yaml-cpp-devel', + 'libupnp-devel', 'boost-devel', 'yasm', 'libuuid-devel', 'libsamplerate-devel', + 'libnettle-devel', 'libopus-devel', 'libgnutls-devel', 'msgpack-devel', 'libavcodec-devel', + 'libavdevice-devel', 'pcre-devel', 'libogg-devel', 'libsndfile-devel', 'libvorbis-devel', + 'flac-devel', 'libgsm-devel', 'alsa-devel', 'libpulse-devel', 'libudev-devel', +# lrc + 'libQt5Core-devel', 'libQt5DBus-devel', 'libqt5-linguist-devel', +# gnome client + 'gtk3-devel', 'clutter-gtk-devel', 'qrencode-devel', 'evolution-data-server-devel', + 'gettext-tools', 'libnotify-devel', 'libappindicator3-devel', +] + FEDORA_DEPENDENCIES = [ 'autoconf', 'automake', 'cmake', 'speexdsp-devel', 'pulseaudio-libs-devel', 'libsamplerate-devel', 'libtool', 'dbus-devel', 'expat-devel', 'pcre-devel', @@ -143,6 +168,12 @@ def run_dependencies(args): {"packages": ' '.join(ARCH_LINUX_DEPENDENCIES)} ) + elif args.distribution == "openSUSE": + execute_script( + ZYPPER_INSTALL_SCRIPT, + {"packages": ' '.join(OPENSUSE_DEPENDENCIES)} + ) + elif args.distribution == "OSX": execute_script( BREW_INSTALL_SCRIPT, @@ -190,6 +221,8 @@ def run_install(args): os.chdir("./client-android") execute_script(["./compile.sh"]) else: + if args.distribution == "openSUSE": + os.environ['JSONCPP_LIBS'] = "-ljsoncpp" #fix jsoncpp pkg-config bug, remove when jsoncpp package bumped install_args += ' -c client-gnome' execute_script(["./scripts/install.sh " + install_args]) @@ -286,7 +319,7 @@ def validate_args(parsed_args): """Validate the args values, exit if error is found""" # Check arg values - supported_distros = ['Android', 'Ubuntu', 'Debian', 'OSX', 'Fedora', 'Arch Linux', 'Automatic'] + supported_distros = ['Android', 'Ubuntu', 'Debian', 'OSX', 'Fedora', 'Arch Linux', 'openSUSE', 'Automatic'] if parsed_args.distribution not in supported_distros: print('Distribution not supported.\nChoose one of: %s' \