]> jfr.im git - irc/rqf/shadowircd.git/blame - Makefile.in
Commit error
[irc/rqf/shadowircd.git] / Makefile.in
CommitLineData
212380e3 1#************************************************************************
2#* IRC - Internet Relay Chat, Makefile
3#* Copyright (C) 1990, Jarkko Oikarinen
4#*
5#* This program is free software; you can redistribute it and/or modify
6#* it under the terms of the GNU General Public License as published by
7#* the Free Software Foundation; either version 1, or (at your option)
8#* any later version.
9#*
10#* This program is distributed in the hope that it will be useful,
11#* but WITHOUT ANY WARRANTY; without even the implied warranty of
12#* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13#* GNU General Public License for more details.
14#*
15#* You should have received a copy of the GNU General Public License
16#* along with this program; if not, write to the Free Software
17#* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18#*
19#* $Id: Makefile.in 1347 2006-05-17 14:49:13Z nenolod $
20#*/
21
22RM=@RM@
23prefix = @prefix@
24exec_prefix = @exec_prefix@
25bindir = @bindir@
26mandir = @mandir@
e8da6cce
NPB
27libdir = @libdir@
28pkglibdir = @pkglibdir@
212380e3 29moduledir = @moduledir@
30helpdir = @helpdir@
68ebdf7f 31sysconfdir = @sysconfdir@
212380e3 32logdir = @logdir@
e8da6cce
NPB
33rundir = @rundir@
34pkgrundir = @pkgrundir@
35localstatedir = @localstatedir@
36pkglocalstatedir= @pkglocalstatedir@
37PACKAGE_TARNAME = @PACKAGE_TARNAME@
212380e3 38
39# Default CFLAGS
40# CFLAGS = -g -O2 -DNDEBUG
41CFLAGS = @CFLAGS@
42# Developers CFLAGS
43#CFLAGS= -g -O2 -Wunused -Wall -ggdb -pedantic -Wshadow -Wmissing-declarations
44
45# Default make flags - you may want to uncomment this on a multicpu machine
46#MFLAGS = -j 4
47
48#
49# For developers
50#CFLAGS= -g -O2 -Wall
51
52# You may need to define the FD_SETSIZE in order to overrule
53# the system one.
54#CFLAGS= -DNDEBUG -g -O2 -D"FD_SETSIZE=1024"
55SHELL=/bin/sh
e131a2ed 56# `extensions' must be after `modules' for proper creation of $(moduledir).
90728edb 57SUBDIRS=libratbox modules extensions src tools ssld bandb doc help
212380e3 58CLEANDIRS = ${SUBDIRS}
59RSA_FILES=rsa_respond/README rsa_respond/respond.c rsa_respond/Makefile
60
61MAKE = make ${MFLAGS}
62
63all: build
64
65
66autoconf: configure.ac
67 autoconf
68 autoheader
69 ${RM} -f config.cache
70
71build:
72 -@if [ ! -f include/setup.h ] ; then \
73 echo "Hmm...doesn't look like you've run configure..."; \
74 echo "Doing so now."; \
75 sh configure; \
76 fi
cb57dfe5 77 @if [ -d .hg ] ; then \
8329f99c 78 revh=`hg parents --template '{date|shortdate}_{node|short}' 2>/dev/null | sed -e s/-//g -e s/_/-/`;\
cb57dfe5
JT
79 [ -z "$$revh" ] || echo '#define SERNO "'$$revh'"' >include/serno.h ; \
80 fi
81 @[ -f include/serno.h ] || echo '#define SERNO "unknown"' >include/serno.h
212380e3 82 @for i in $(SUBDIRS); do \
83 echo "build ==> $$i";\
84 cd $$i;\
e5808548 85 ${MAKE} || exit; cd ..;\
212380e3 86 done
87
88clean:
89 ${RM} -f *~ core rsa_respond.tar rsa_respond.tar.gz
90 @for i in $(CLEANDIRS); do \
91 echo "clean ==> $$i";\
92 cd $$i;\
93 ${MAKE} clean; cd ..;\
94 done
95 -@if [ -f include/setup.h ] ; then \
96 echo "To really restart installation, make distclean" ; \
97 fi
98
99distclean:
100 ${RM} -f Makefile *~ *.rej *.orig core ircd.core
101 ${RM} -f config.status config.cache config.log
102 cd include; ${RM} -f setup.h *~ *.rej *.orig ; cd ..
103 @for i in $(CLEANDIRS); do \
104 echo "distclean ==> $$i";\
105 cd $$i;\
106 ${MAKE} distclean; cd ..;\
107 done
108
109depend:
cb57dfe5 110 @[ -f include/serno.h ] || echo '#define SERNO "unknown"' >include/serno.h
212380e3 111 @for i in $(SUBDIRS); do \
112 echo "depend ==> $$i";\
113 cd $$i;\
114 ${MAKE} depend; cd ..;\
115 done
116
117lint:
118 @for i in $(SUBDIRS); do \
119 echo "lint ==> $$i";\
120 cd $$i;\
121 ${MAKE} lint; cd ..;\
122 done
123
124install-mkdirs:
125 @echo "ircd: setting up ircd directory structure"
126 -@if test ! -d $(DESTDIR)$(prefix); then \
e8da6cce 127 mkdir -p -m 755 $(DESTDIR)$(prefix); \
212380e3 128 fi
129 -@if test ! -d $(DESTDIR)$(bindir); then \
e8da6cce 130 mkdir -p -m 755 $(DESTDIR)$(bindir); \
212380e3 131 fi
68ebdf7f
NPB
132 -@if test ! -d $(DESTDIR)$(sysconfdir); then \
133 mkdir -p -m 755 $(DESTDIR)$(sysconfdir); \
212380e3 134 fi
135 -@if test ! -d $(DESTDIR)$(mandir); then \
e8da6cce 136 mkdir -p -m 755 $(DESTDIR)$(mandir); \
212380e3 137 fi
212380e3 138 -@if test ! -d $(DESTDIR)$(logdir); then \
e8da6cce 139 mkdir -p -m 755 $(DESTDIR)$(logdir); \
212380e3 140 fi
e8da6cce
NPB
141 -@if test ! -d '$(DESTDIR)$(pkgrundir)'; then \
142 mkdir -p -m 755 '$(DESTDIR)$(pkgrundir)'; \
143 fi
144 -@if test ! -d '$(DESTDIR)$(pkglocalstatedir)'; then \
145 mkdir -p -m 755 '$(DESTDIR)$(pkglocalstatedir)'; \
146 fi
147
212380e3 148install: install-mkdirs all
149 @for i in $(SUBDIRS); do \
150 echo "install ==> $$i";\
151 cd $$i;\
152 ${MAKE} install; \
153 cd ..; \
154 done
155
156rsa_respond:
157 @cd tools;\
158 echo "Creating rsa_respond.tar.gz";\
159 tar cf ../rsa_respond.tar $(RSA_FILES);\
160 cd ..;\
161 gzip rsa_respond.tar