aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorMichael Büsch <mb@bu3sch.de>2011-01-27 19:52:36 +0000
committerMichael Büsch <mb@bu3sch.de>2011-01-27 19:52:36 +0000
commite99a1560cd93ee94b6e773449c31299845deab3c (patch)
treea29d091baf92040ae2c1a816f24edb073b75442a /tools
parenta580764a9f4715335e23cf7aea7b7716a7ad135c (diff)
downloadupstream-e99a1560cd93ee94b6e773449c31299845deab3c.tar.gz
upstream-e99a1560cd93ee94b6e773449c31299845deab3c.tar.bz2
upstream-e99a1560cd93ee94b6e773449c31299845deab3c.zip
Add missing XAW macros
SVN-Revision: 25159
Diffstat (limited to 'tools')
-rw-r--r--tools/missing-macros/src/README5
-rw-r--r--tools/missing-macros/src/m4/xaw.m465
2 files changed, 70 insertions, 0 deletions
diff --git a/tools/missing-macros/src/README b/tools/missing-macros/src/README
index d1202fb79c..d2305ff557 100644
--- a/tools/missing-macros/src/README
+++ b/tools/missing-macros/src/README
@@ -93,3 +93,8 @@ Always disable GTK docs.
Provide intltool.m4 stubs to allow for autoreconf.
fake-intltool.m4
+
+From XDM:
+XAW macros.
+
+ xaw.m4
diff --git a/tools/missing-macros/src/m4/xaw.m4 b/tools/missing-macros/src/m4/xaw.m4
new file mode 100644
index 0000000000..60404ae8c2
--- /dev/null
+++ b/tools/missing-macros/src/m4/xaw.m4
@@ -0,0 +1,65 @@
+dnl Copyright 2005 Red Hat, Inc
+dnl
+dnl Permission to use, copy, modify, distribute, and sell this software and its
+dnl documentation for any purpose is hereby granted without fee, provided that
+dnl the above copyright notice appear in all copies and that both that
+dnl copyright notice and this permission notice appear in supporting
+dnl documentation.
+dnl
+dnl The above copyright notice and this permission notice shall be included
+dnl in all copies or substantial portions of the Software.
+dnl
+dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+dnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+dnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+dnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR
+dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+dnl OTHER DEALINGS IN THE SOFTWARE.
+dnl
+dnl Except as contained in this notice, the name of the copyright holders shall
+dnl not be used in advertising or otherwise to promote the sale, use or
+dnl other dealings in this Software without prior written authorization
+dnl from the copyright holders.
+dnl
+
+# XAW_CHECK_XPRINT_SUPPORT()
+# --------------------------
+# Adds --enable/disable-xprint and selects the appropriate version of the Xaw
+# library. If neither --enable-xprint nor --disable-xprint are given,
+# the presence of an Xaw with Xprint support will be auto detected
+
+AC_DEFUN([XAW_CHECK_XPRINT_SUPPORT],[
+ AC_ARG_ENABLE(xprint, AC_HELP_STRING([--enable-xprint], [Enable XPrint support]),
+ [use_xprint=$enableval],[use_xprint=auto])
+ if test "x$use_xprint" = "xyes"; then
+ TMP_CHECK1=xaw8
+ TMP_CHECK2=
+ xaw_use_xprint=yes
+ elif test "x$use_xprint" = "xno"; then
+ TMP_CHECK1=xaw7
+ TMP_CHECK2=
+ xaw_use_xprint=no
+ else
+ TMP_CHECK1=xaw8
+ TMP_CHECK2=xaw7
+ xaw_use_xprint=yes
+ fi
+
+ PKG_CHECK_MODULES(TMP_XAW, $TMP_CHECK1, success=yes, success=no)
+ if [[ ! -z $TMP_CHECK2 ]] ; then
+ if test $success = no ; then
+ PKG_CHECK_MODULES(TMP_XAW, $TMP_CHECK2, success=yes, success=no)
+ xaw_use_xprint=no
+ fi
+ fi
+
+ if test "x$success" = "xyes"; then
+ $1_CFLAGS=$TMP_XAW_CFLAGS
+ $1_LIBS=$TMP_XAW_LIBS
+
+ AM_CONDITIONAL([XAW_USE_XPRINT], [test "x$xaw_use_xprint" = "xyes"])
+ else
+ AC_MSG_ERROR([No suitable version of Xaw found])
+ fi
+])