changeset 55236:d7852bb72332

8219920: dependency help output in configure-step : support zypper tool Reviewed-by: erikj, ihse
author mbaesken
date Tue, 05 Mar 2019 09:55:00 +0100
parents d870bb08194a
children 3158fae17e80
files make/autoconf/configure make/autoconf/help.m4
diffstat 2 files changed, 28 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/make/autoconf/configure	Tue Mar 05 08:24:58 2019 -0500
+++ b/make/autoconf/configure	Tue Mar 05 09:55:00 2019 +0100
@@ -1,6 +1,6 @@
 #!/bin/bash
 #
-# Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2012, 2019, Oracle and/or its affiliates. All rights reserved.
 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 #
 # This code is free software; you can redistribute it and/or modify it
@@ -78,9 +78,12 @@
   APT_GET="`which apt-get 2> /dev/null | grep -v '^no apt-get in'`"
   YUM="`which yum 2> /dev/null | grep -v '^no yum in'`"
   BREW="`which brew 2> /dev/null | grep -v '^no brew in'`"
+  ZYPPER="`which zypper 2> /dev/null | grep -v '^no zypper in'`"
   CYGWIN="`which cygpath 2> /dev/null | grep -v '^no cygpath in'`"
 
-  if test "x$APT_GET" != x; then
+  if test "x$ZYPPER" != x; then
+    PKGHANDLER_COMMAND="sudo zypper install autoconf"
+  elif test "x$APT_GET" != x; then
     PKGHANDLER_COMMAND="sudo apt-get install autoconf"
   elif test "x$YUM" != x; then
     PKGHANDLER_COMMAND="sudo yum install autoconf"
--- a/make/autoconf/help.m4	Tue Mar 05 08:24:58 2019 -0500
+++ b/make/autoconf/help.m4	Tue Mar 05 09:55:00 2019 +0100
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 #
 # This code is free software; you can redistribute it and/or modify it
@@ -25,7 +25,7 @@
 
 AC_DEFUN_ONCE([HELP_SETUP_DEPENDENCY_HELP],
 [
-  AC_CHECK_PROGS(PKGHANDLER, apt-get yum brew port pkgutil pkgadd)
+  AC_CHECK_PROGS(PKGHANDLER, zypper apt-get yum brew port pkgutil pkgadd)
 ])
 
 AC_DEFUN([HELP_MSG_MISSING_DEPENDENCY],
@@ -54,6 +54,8 @@
         pkgutil_help $MISSING_DEPENDENCY ;;
       pkgadd)
         pkgadd_help  $MISSING_DEPENDENCY ;;
+      zypper)
+        zypper_help  $MISSING_DEPENDENCY ;;
     esac
 
     if test "x$PKGHANDLER_COMMAND" != x; then
@@ -110,6 +112,25 @@
   esac
 }
 
+zypper_help() {
+  case $1 in
+    devkit)
+      PKGHANDLER_COMMAND="sudo zypper install gcc gcc-c++" ;;
+    alsa)
+      PKGHANDLER_COMMAND="sudo zypper install alsa-devel" ;;
+    cups)
+      PKGHANDLER_COMMAND="sudo zypper install cups-devel" ;;
+    fontconfig)
+      PKGHANDLER_COMMAND="sudo zypper install fontconfig-devel" ;;
+    freetype)
+      PKGHANDLER_COMMAND="sudo zypper install freetype-devel" ;;
+    x11)
+      PKGHANDLER_COMMAND="sudo zypper install libX11-devel libXext-devel libXrender-devel libXrandr-devel libXtst-devel libXt-devel libXi-devel" ;;
+    ccache)
+      PKGHANDLER_COMMAND="sudo zypper install ccache" ;;
+  esac
+}
+
 yum_help() {
   case $1 in
     devkit)