8279958: Provide configure hints for Alpine/apk package managers

Reviewed-by: erikj
This commit is contained in:
Aleksey Shipilev 2022-01-17 08:19:08 +00:00
parent 590eb86033
commit a30aa52b77

View File

@ -1,5 +1,5 @@
#
# Copyright (c) 2011, 2021, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2011, 2022, 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],
[
UTIL_LOOKUP_PROGS(PKGHANDLER, zypper apt-get yum brew port pkgutil pkgadd pacman)
UTIL_LOOKUP_PROGS(PKGHANDLER, zypper apt-get yum brew port pkgutil pkgadd pacman apk)
])
AC_DEFUN([HELP_MSG_MISSING_DEPENDENCY],
@ -58,6 +58,8 @@ AC_DEFUN([HELP_MSG_MISSING_DEPENDENCY],
zypper_help $MISSING_DEPENDENCY ;;
*pacman)
pacman_help $MISSING_DEPENDENCY ;;
*apk)
apk_help $MISSING_DEPENDENCY ;;
esac
if test "x$PKGHANDLER_COMMAND" != x; then
@ -192,6 +194,27 @@ pkgadd_help() {
PKGHANDLER_COMMAND=""
}
apk_help() {
case $1 in
devkit)
PKGHANDLER_COMMAND="sudo apk add alpine-sdk linux-headers" ;;
alsa)
PKGHANDLER_COMMAND="sudo apk add alsa-lib-dev" ;;
cups)
PKGHANDLER_COMMAND="sudo apk add cups-dev" ;;
fontconfig)
PKGHANDLER_COMMAND="sudo apk add fontconfig-dev" ;;
freetype)
PKGHANDLER_COMMAND="sudo apk add freetype-dev" ;;
harfbuzz)
PKGHANDLER_COMMAND="sudo apk add harfbuzz-dev" ;;
x11)
PKGHANDLER_COMMAND="sudo apk add libxtst-dev libxt-dev libxrender-dev libxrandr-dev" ;;
ccache)
PKGHANDLER_COMMAND="sudo apk add ccache" ;;
esac
}
# This function will check if we're called from the "configure" wrapper while
# printing --help. If so, we will print out additional information that can
# only be extracted within the autoconf script, and then exit. This must be