2007-09-18 15:23:49 -06:00
|
|
|
#
|
2010-10-31 10:25:10 -06:00
|
|
|
# Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
|
|
|
|
#
|
|
|
|
# Permission is hereby granted, free of charge, to any person obtaining a
|
|
|
|
# copy of this software and associated documentation files (the "Software"),
|
|
|
|
# to deal in the Software without restriction, including without limitation
|
|
|
|
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
|
|
|
# and/or sell copies of the Software, and to permit persons to whom the
|
|
|
|
# Software is furnished to do so, subject to the following conditions:
|
|
|
|
#
|
|
|
|
# The above copyright notice and this permission notice (including the next
|
|
|
|
# paragraph) shall be included in all copies or substantial portions of the
|
|
|
|
# Software.
|
|
|
|
#
|
|
|
|
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
|
|
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
|
|
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
|
|
|
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
|
|
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
|
|
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
|
|
|
# DEALINGS IN THE SOFTWARE.
|
|
|
|
#
|
2007-09-18 15:23:49 -06:00
|
|
|
|
|
|
|
libmandir = $(LIB_MAN_DIR)
|
|
|
|
|
2010-05-10 14:10:07 -06:00
|
|
|
libman_xml = XTest.xml
|
|
|
|
|
|
|
|
libman_PRE = \
|
|
|
|
XTestQueryExtension.man \
|
|
|
|
XTestCompareCursorWithWindow.man \
|
|
|
|
XTestCompareCurrentCursorWithWindow.man \
|
|
|
|
XTestFakeKeyEvent.man \
|
|
|
|
XTestFakeButtonEvent.man \
|
|
|
|
XTestFakeMotionEvent.man \
|
|
|
|
XTestFakeRelativeMotionEvent.man \
|
|
|
|
XTestGrabControl.man \
|
|
|
|
XTestSetGContextOfGC.man \
|
|
|
|
XTestSetVisualIDOfVisual.man \
|
|
|
|
XTestDiscard.man
|
|
|
|
|
|
|
|
EXTRA_DIST = $(libman_PRE) $(libman_xml) x.stamp
|
2007-09-18 15:23:49 -06:00
|
|
|
|
2010-10-31 10:25:10 -06:00
|
|
|
CLEANFILES = $(libman_DATA)
|
2007-09-18 15:23:49 -06:00
|
|
|
|
|
|
|
MAINTAINERCLEANFILES = $(libman_PRE)
|
|
|
|
|
2010-10-31 10:25:10 -06:00
|
|
|
if INSTALL_MANPAGES
|
2007-09-18 15:23:49 -06:00
|
|
|
libman_DATA = $(libman_PRE:man=@LIB_MAN_SUFFIX@)
|
2010-05-10 14:10:07 -06:00
|
|
|
endif
|
2007-09-18 15:23:49 -06:00
|
|
|
|
2010-10-31 10:25:10 -06:00
|
|
|
# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
|
2007-09-18 15:23:49 -06:00
|
|
|
SUFFIXES = .$(LIB_MAN_SUFFIX) .man
|
|
|
|
|
|
|
|
.man.$(LIB_MAN_SUFFIX):
|
2010-10-31 10:25:10 -06:00
|
|
|
$(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
|
2007-09-18 15:23:49 -06:00
|
|
|
|
2010-05-10 14:10:07 -06:00
|
|
|
# This is ugly, but handling of tools with multiple outputs in make is a
|
|
|
|
# huge PITA. The commands below are taken from the automake manual:
|
|
|
|
# http://www.gnu.org/software/automake/manual/automake.html#Multiple-Outputs
|
2007-09-18 15:23:49 -06:00
|
|
|
if HAVE_XMLTO
|
2010-05-10 14:10:07 -06:00
|
|
|
x.stamp: $(libman_xml)
|
|
|
|
@rm -f x.tmp
|
|
|
|
@touch x.tmp
|
|
|
|
$(XMLTO) man $^
|
|
|
|
@for man in $(libman_PRE); do \
|
|
|
|
out=`echo $$man | sed 's/\.man/.__libmansuffix__/'`; \
|
|
|
|
echo mv -f $$out $$man; \
|
|
|
|
mv -f $$out $$man || exit 1; \
|
2007-09-18 15:23:49 -06:00
|
|
|
done
|
2010-05-10 14:10:07 -06:00
|
|
|
@mv -f x.tmp $@
|
|
|
|
$(libman_PRE): x.stamp
|
|
|
|
@if test -f $@; then :; else \
|
|
|
|
rm -f $<; \
|
|
|
|
$(MAKE) $(AM_MAKEFLAGS) $<; \
|
|
|
|
fi
|
|
|
|
CLEANFILES += x.tmp
|
|
|
|
MAINTAINERCLEANFILES += x.stamp
|
|
|
|
endif # HAVE_XMLTO
|