Debian Codegraph @

imake/Makefile.am

raw
1 #
2 # Copyright 2005 Red Hat, Inc.
3 #
4 # Permission to use, copy, modify, distribute, and sell this software and its
5 # documentation for any purpose is hereby granted without fee, provided that
6 # the above copyright notice appear in all copies and that both that
7 # copyright notice and this permission notice appear in supporting
8 # documentation, and that the name of Red Hat not be used in
9 # advertising or publicity pertaining to distribution of the software without
10 # specific, written prior permission. Red Hat makes no
11 # representations about the suitability of this software for any purpose. It
12 # is provided "as is" without express or implied warranty.
13 #
14 # RED HAT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
15 # INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
16 # EVENT SHALL RED HAT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
17 # CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
18 # DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
19 # TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
20 # PERFORMANCE OF THIS SOFTWARE.
21
22 CPP_PROGRAM = @CPP_PROGRAM@
23 XCONFDIR = @XCONFDIR@
24 PREPROCESSCMD_MKDEPEND = @PREPROCESSCMD_MKDEPEND@
25 ARCMD = @ARCMD@
26 RANLIB = @RANLIB@
27
28 if BUILD_REVPATH
29 REVPATH = revpath
30 endif
31
32 bin_PROGRAMS = imake $(REVPATH)
33
34 AM_CFLAGS = $(CWARNFLAGS)
35
36 imake_CFLAGS = $(XPROTO_CFLAGS) -DCPP_PROGRAM='"$(CPP_PROGRAM)"' $(CWARNFLAGS)
37 imake_SOURCES = imake.c imakemdep.h
38
39 revpath_SOURCES = revpath.c
40
41 if BUILD_MAKEG
42 MAKEG = makeg
43 endif
44
45 if BUILD_XMKMF
46 XMKMF = xmkmf
47 endif
48
49 if BUILD_CCMAKEDEP
50 CCMAKEDEP = ccmakedep
51 endif
52
53 if BUILD_MERGELIB
54 MERGELIB = mergelib
55 endif
56
57 if BUILD_MKDIRHIER
58 MKDIRHIER = mkdirhier
59 endif
60
61 if BUILD_CLEANLINKS
62 CLEANLINKS = cleanlinks
63 endif
64
65 if BUILD_MKHTMLINDEX
66 MKHTMLINDEX = mkhtmlindex
67 endif
68
69 bin_SCRIPTS = \
70 $(MAKEG) \
71 $(XMKMF) \
72 $(CCMAKEDEP) \
73 $(MERGELIB) \
74 $(MKDIRHIER) \
75 $(CLEANLINKS) \
76 $(MKHTMLINDEX)
77
78 xmkmf: xmkmf.cpp
79 $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) -DCONFIGDIRSPEC='"-I$(XCONFDIR)"' $(srcdir)/xmkmf.cpp | $(SED) -e /^\#/d | $(SED) -e s/XCOMM/\#/ > $@
80
81 ccmakedep: mdepend.cpp
82 $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) -DPREPROC='"$(PREPROCESSCMD_MKDEPEND)"' $(srcdir)/mdepend.cpp | $(SED) -e /^\#/d | $(SED) -e s/XCOMM/\#/ > $@
83
84 mergelib: mergelib.cpp
85 $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) -DARCMD="$(ARCMD)" -DRANLIB="$(RANLIB)" $(srcdir)/mergelib.cpp | $(SED) -e /^\#/d | $(SED) -e s/XCOMM/\#/ > $@
86
87 if HAS_PERL
88 MKHTMLINDEX_SCRIPT = $(srcdir)/mkhtmlindex.pl
89 else
90 MKHTMLINDEX_SCRIPT = $(srcdir)/mkhtmlindex.sh
91 endif
92
93 mkhtmlindex: $(MKHTMLINDEX_SCRIPT)
94 $(AM_V_GEN)cp $(MKHTMLINDEX_SCRIPT) $@
95
96
97 CLEANFILES = \
98 xmkmf \
99 ccmakedep \
100 mergelib \
101 mkhtmlindex
102
103 EXTRA_DIST = \
104 README.md \
105 makeg \
106 xmkmf.cpp \
107 mdepend.cpp \
108 mergelib.cpp \
109 mkdirhier \
110 cleanlinks \
111 mkhtmlindex.pl \
112 mkhtmlindex.sh
113
114 # Man page
115 appmandir = $(APP_MAN_DIR)
116
117 appman_PRE = \
118 imake.man \
119 makeg.man \
120 xmkmf.man \
121 ccmakedep.man \
122 mergelib.man \
123 revpath.man \
124 mkdirhier.man \
125 cleanlinks.man \
126 mkhtmlindex.man
127
128 # Only need to install man pages for programs/scripts being installed
129 appman_DATA = $(bin_PROGRAMS:%$(EXEEXT)=%.@APP_MAN_SUFFIX@) $(bin_SCRIPTS:%=%.@APP_MAN_SUFFIX@)
130
131 EXTRA_DIST += $(appman_PRE)
132 CLEANFILES += $(appman_DATA)
133
134 # String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
135 MAN_SUBSTS += \
136 -e 's|__cpp__|$(RAWCPP)|g'
137
138 SUFFIXES = .$(APP_MAN_SUFFIX) .man
139
140 .man.$(APP_MAN_SUFFIX):
141 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
142
143 EXTRA_DIST += ChangeLog
144 MAINTAINERCLEANFILES = ChangeLog
145
146 .PHONY: ChangeLog INSTALL
147
148 INSTALL:
149 $(INSTALL_CMD)
150
151 ChangeLog:
152 $(CHANGELOG_CMD)
153
154 dist-hook: ChangeLog INSTALL