1 | # Top-level Makefile for cyrus software |
---|
2 | # $Id: Makefile.in,v 1.1.1.2 2003-02-14 21:39:32 ghudson Exp $ |
---|
3 | # |
---|
4 | # @configure_input@ |
---|
5 | # |
---|
6 | # Copyright (c) 1998-2000 Carnegie Mellon University. All rights reserved. |
---|
7 | # |
---|
8 | # Redistribution and use in source and binary forms, with or without |
---|
9 | # modification, are permitted provided that the following conditions |
---|
10 | # are met: |
---|
11 | # |
---|
12 | # 1. Redistributions of source code must retain the above copyright |
---|
13 | # notice, this list of conditions and the following disclaimer. |
---|
14 | # |
---|
15 | # 2. Redistributions in binary form must reproduce the above copyright |
---|
16 | # notice, this list of conditions and the following disclaimer in |
---|
17 | # the documentation and/or other materials provided with the |
---|
18 | # distribution. |
---|
19 | # |
---|
20 | # 3. The name "Carnegie Mellon University" must not be used to |
---|
21 | # endorse or promote products derived from this software without |
---|
22 | # prior written permission. For permission or any other legal |
---|
23 | # details, please contact |
---|
24 | # Office of Technology Transfer |
---|
25 | # Carnegie Mellon University |
---|
26 | # 5000 Forbes Avenue |
---|
27 | # Pittsburgh, PA 15213-3890 |
---|
28 | # (412) 268-4387, fax: (412) 268-7395 |
---|
29 | # tech-transfer@andrew.cmu.edu |
---|
30 | # |
---|
31 | # 4. Redistributions of any form whatsoever must retain the following |
---|
32 | # acknowledgment: |
---|
33 | # "This product includes software developed by Computing Services |
---|
34 | # at Carnegie Mellon University (http://www.cmu.edu/computing/)." |
---|
35 | # |
---|
36 | # CARNEGIE MELLON UNIVERSITY DISCLAIMS ALL WARRANTIES WITH REGARD TO |
---|
37 | # THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY |
---|
38 | # AND FITNESS, IN NO EVENT SHALL CARNEGIE MELLON UNIVERSITY BE LIABLE |
---|
39 | # FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES |
---|
40 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN |
---|
41 | # AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING |
---|
42 | # OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
---|
43 | # |
---|
44 | |
---|
45 | SUBDIRS = man @PRE_SUBDIRS@ acap lib @SERVER_SUBDIRS@ \ |
---|
46 | imtest @SNMP_SUBDIRS@ @EXTRA_SUBDIRS@ |
---|
47 | DISTSUBDIRS = doc |
---|
48 | |
---|
49 | srcdir = @srcdir@ |
---|
50 | VPATH = @srcdir@ |
---|
51 | |
---|
52 | INSTALL = @INSTALL@ |
---|
53 | |
---|
54 | SHELL = /bin/sh |
---|
55 | @SET_MAKE@ |
---|
56 | |
---|
57 | prefix = @prefix@ |
---|
58 | exec_prefix = @exec_prefix@ |
---|
59 | cyrus_prefix = @cyrus_prefix@ |
---|
60 | |
---|
61 | VERSION = 2.1.12 |
---|
62 | |
---|
63 | all:: |
---|
64 | @for d in $(SUBDIRS); \ |
---|
65 | do \ |
---|
66 | (cd $$d; echo "### Making" all "in" `pwd`; \ |
---|
67 | $(MAKE) $(MFLAGS) DESTDIR=$(DESTDIR) all) || exit 1; \ |
---|
68 | done |
---|
69 | |
---|
70 | dist:: distcvs |
---|
71 | @echo "creating configure" |
---|
72 | @cd dist/cyrus-imapd-$(VERSION) ; sh SMakefile |
---|
73 | @for d in $(SUBDIRS) $(DISTSUBDIRS); \ |
---|
74 | do \ |
---|
75 | (cd dist/cyrus-imapd-$(VERSION)/$$d; \ |
---|
76 | if [ -f Makefile.dist ]; then \ |
---|
77 | echo "### Making" dist "in" `pwd`; \ |
---|
78 | $(MAKE) $(MFLAGS) DESTDIR=$(DESTDIR) -f Makefile.dist dist ; \ |
---|
79 | fi) || exit 1; \ |
---|
80 | done |
---|
81 | @echo "creating tarfile" |
---|
82 | @cd dist ; tar cf - cyrus-imapd-$(VERSION) | \ |
---|
83 | gzip -9 > ../cyrus-imapd-$(VERSION).tar.gz |
---|
84 | rm -f distcvs |
---|
85 | rm -rf dist |
---|
86 | |
---|
87 | distcvs: |
---|
88 | if [ \! -d dist ]; then mkdir dist ; fi |
---|
89 | @echo "checking out the distribution" |
---|
90 | @cd dist ; cvs -Q -d :pserver:anoncvs@cvs.andrew.cmu.edu:/cvs \ |
---|
91 | co -d cyrus-imapd-$(VERSION) cyrus |
---|
92 | touch distcvs |
---|
93 | |
---|
94 | install:: |
---|
95 | $(srcdir)/install-sh -d ${DESTDIR}$(exec_prefix)/bin |
---|
96 | $(srcdir)/install-sh -d ${DESTDIR}$(exec_prefix)/lib |
---|
97 | $(srcdir)/install-sh -d ${DESTDIR}$(prefix)/include/cyrus |
---|
98 | $(srcdir)/install-sh -d ${DESTDIR}$(prefix)/man/man1 |
---|
99 | $(srcdir)/install-sh -d ${DESTDIR}$(prefix)/man/man3 |
---|
100 | $(srcdir)/install-sh -d ${DESTDIR}$(prefix)/man/man5 |
---|
101 | $(srcdir)/install-sh -d ${DESTDIR}$(prefix)/man/man8 |
---|
102 | @for d in $(SUBDIRS); \ |
---|
103 | do \ |
---|
104 | (cd $$d; echo "### Making" install "in" `pwd`; \ |
---|
105 | $(MAKE) $(MFLAGS) DESTDIR=$(DESTDIR) install) || exit 1; \ |
---|
106 | done |
---|
107 | |
---|
108 | clean:: |
---|
109 | @-for d in $(SUBDIRS); \ |
---|
110 | do \ |
---|
111 | (cd $$d; echo "### Making" clean "in" `pwd`; \ |
---|
112 | $(MAKE) $(MFLAGS) DESTDIR=$(DESTDIR) clean ; \ |
---|
113 | echo "### Done with" `pwd`); \ |
---|
114 | done |
---|
115 | |
---|
116 | distclean:: |
---|
117 | @-for d in $(SUBDIRS); \ |
---|
118 | do \ |
---|
119 | (cd $$d; echo "### Making" clean "in" `pwd`; \ |
---|
120 | $(MAKE) $(MFLAGS) DESTDIR=$(DESTDIR) distclean ; \ |
---|
121 | echo "### Done with" `pwd`); \ |
---|
122 | done |
---|
123 | rm -f Makefile Makefile.bak \ |
---|
124 | config.status config.log config.cache config.h |
---|
125 | |
---|
126 | depend:: |
---|
127 | @for d in $(SUBDIRS); \ |
---|
128 | do \ |
---|
129 | (cd $$d; echo "### Making" depend "in" `pwd`; \ |
---|
130 | $(MAKE) $(MFLAGS) DESTDIR=$(DESTDIR) depend) || exit 1; \ |
---|
131 | done |
---|
132 | |
---|
133 | Makefile: Makefile.in config.status |
---|
134 | $(SHELL) config.status |
---|
135 | config.status: configure |
---|
136 | $(SHELL) config.status --recheck |
---|
137 | configure: configure.in |
---|
138 | cd $(srcdir); rm -f config.cache; autoconf |
---|
139 | |
---|
140 | checkdepend:: |
---|
141 | |
---|
142 | depend:: |
---|
143 | echo '/^# DO NOT DELETE THIS LINE/+2,$$d' >eddep |
---|
144 | echo 'w' >>eddep |
---|
145 | cp Makefile Makefile.bak |
---|
146 | ed -s Makefile < eddep |
---|
147 | rm eddep |
---|
148 | echo '' >> Makefile |
---|
149 | echo '# IF YOU PUT STUFF HERE IT WILL GO AWAY' >> Makefile |
---|
150 | echo '# see make depend above' >> Makefile |
---|
151 | |
---|
152 | # DO NOT DELETE THIS LINE -- make depend uses it |
---|
153 | |
---|
154 | # The following rule ensures that "make depend" gets run at least |
---|
155 | # once before a "make all". The "depend" rule above removes |
---|
156 | # this rule from the Makefile the first time the "make depend" |
---|
157 | # has been run after the Makefile is generated by Configure |
---|
158 | |
---|
159 | checkdepend:: depend |
---|
160 | |
---|
161 | # IF YOU PUT STUFF HERE IT WILL GO AWAY |
---|
162 | # see make depend above |
---|