1 dnl Copyright 2005 Red Hat, Inc
3 dnl Permission to use, copy, modify, distribute, and sell this software and its
4 dnl documentation for any purpose is hereby granted without fee, provided that
5 dnl the above copyright notice appear in all copies and that both that
6 dnl copyright notice and this permission notice appear in supporting
9 dnl The above copyright notice and this permission notice shall be included
10 dnl in all copies or substantial portions of the Software.
12 dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
13 dnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
14 dnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
15 dnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR
16 dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
17 dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
18 dnl OTHER DEALINGS IN THE SOFTWARE.
20 dnl Except as contained in this notice, the name of the copyright holders shall
21 dnl not be used in advertising or otherwise to promote the sale, use or
22 dnl other dealings in this Software without prior written authorization
23 dnl from the copyright holders.
26 # XAW_CHECK_XPRINT_SUPPORT()
27 # --------------------------
28 # Adds --enable/disable-xprint and selects the appropriate version of the Xaw
29 # library. If neither --enable-xprint nor --disable-xprint are given,
30 # the presence of an Xaw with Xprint support will be auto detected
32 AC_DEFUN([XAW_CHECK_XPRINT_SUPPORT],[
33 AC_ARG_ENABLE(xprint, AC_HELP_STRING([--enable-xprint], [Enable XPrint support]),
34 [use_xprint=$enableval],[use_xprint=auto])
35 if test "x$use_xprint" = "xyes"; then
39 elif test "x$use_xprint" = "xno"; then
49 PKG_CHECK_MODULES(TMP_XAW, $TMP_CHECK1, success=yes, success=no)
50 if [[ ! -z $TMP_CHECK2 ]] ; then
51 if test $success = no ; then
52 PKG_CHECK_MODULES(TMP_XAW, $TMP_CHECK2, success=yes, success=no)
57 if test "x$success" = "xyes"; then
58 $1_CFLAGS=$TMP_XAW_CFLAGS
61 AM_CONDITIONAL([XAW_USE_XPRINT], [test "x$xaw_use_xprint" = "xyes"])
63 AC_MSG_ERROR([No suitable version of Xaw found])