Gentoo Archives: gentoo-commits

From: "Bjarke Istrup Pedersen (gurligebis)" <gurligebis@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-irc/anope/files: anope-1.8.7-libdir-gentoo.patch anope-init.d anope-1.8.7-ldflags-fix.patch anope-conf.d ldflags-fix.patch anope.confd anope.initd
Date: Wed, 28 Dec 2011 20:25:58
Message-Id: 20111228202548.C4A8D2004B@flycatcher.gentoo.org
1 gurligebis 11/12/28 20:25:48
2
3 Added: anope-1.8.7-libdir-gentoo.patch anope-init.d
4 anope-1.8.7-ldflags-fix.patch anope-conf.d
5 Removed: ldflags-fix.patch anope.confd anope.initd
6 Log:
7 Bumping to 1.8.7, removing old version and moving out of /opt.
8 Thanks to everybody who helped out. Fixing bug #395089
9
10 (Portage version: 2.2.0_alpha83/cvs/Linux i686)
11
12 Revision Changes Path
13 1.1 net-irc/anope/files/anope-1.8.7-libdir-gentoo.patch
14
15 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-irc/anope/files/anope-1.8.7-libdir-gentoo.patch?rev=1.1&view=markup
16 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-irc/anope/files/anope-1.8.7-libdir-gentoo.patch?rev=1.1&content-type=text/plain
17
18 Index: anope-1.8.7-libdir-gentoo.patch
19 ===================================================================
20 --- configure.in
21 +++ configure.in
22 @@ -286,6 +286,15 @@
23 ])
24
25 AC_SUBST(DATDEST)
26 +
27 +AC_ARG_WITH(libdir, [ --with-libdir=libdir Specify the location of the services lib folder], [
28 + AC_DEFINE_UNQUOTED(LIB_DIR,"$withval","services lib dir")
29 + AC_DEFINE_UNQUOTED(MODULE_PATH,"${withval}/modules/","Module dir")
30 + DATDEST=$withval
31 + MODULE_PATH=${withval}/modules/
32 +])
33 +
34 +AC_SUBST(LIB_PATH)
35 AC_SUBST(MODULE_PATH)
36
37 AC_CONFIG_FILES( \
38 --- src/Makefile
39 +++ src/Makefile
40 @@ -115,10 +115,6 @@
41 ln $(BINDEST)/services $(BINDEST)/listnicks
42 ln $(BINDEST)/services $(BINDEST)/listchans
43 (cd ../lang ; $(MAKE) install)
44 - $(CP) ../data/* $(DATDEST)
45 - $(INSTALL) bin/mydbgen $(DATDEST)/mydbgen
46 - test -d $(DATDEST)/backups || mkdir $(DATDEST)/backups
47 - test -d $(DATDEST)/logs || mkdir $(DATDEST)/logs
48 @if [ "$(MODULE_PATH)" ] ; then \
49 test -d ${MODULE_PATH} || mkdir ${MODULE_PATH} ; \
50 test -d ${MODULE_PATH}/runtime || mkdir ${MODULE_PATH}/runtime ; \
51 --- include/sysconf.h.in
52 +++ include/sysconf.h.in
53 @@ -96,6 +96,9 @@
54 /* "Module dir" */
55 #undef MODULE_PATH
56
57 +/* "Lib dir" */
58 +#undef LIB_DIR
59 +
60 /* "Has mysql/mysql.h" */
61 #undef MYSQL_HEADER_PREFIX
62
63 --- include/config.h
64 +++ include/config.h
65 @@ -22,10 +22,10 @@
66 /******* General configuration *******/
67
68 /* Name of configuration file (in Services directory) */
69 -#define SERVICES_CONF "services.conf"
70 +#define SERVICES_CONF "/etc/anope/services.conf"
71
72 /* Name of log file (in Services directory) */
73 -#define LOG_FILENAME "services.log"
74 +#define LOG_FILENAME "/var/log/anope/services.log"
75
76 /* Maximum amount of data from/to the network to buffer (bytes). */
77 #define NET_BUFSIZE 65536
78 --- src/log.c
79 +++ src/log.c
80 @@ -33,7 +33,7 @@
81
82 /* fix bug 577 */
83 strftime(timestamp, sizeof(timestamp), "%Y%m%d", tm);
84 - snprintf(name, count, "logs/%s.%s", log_filename, timestamp);
85 + snprintf(name, count, "%s.%s", log_filename, timestamp);
86 curday = tm->tm_yday;
87
88 return 1;
89 --- src/modules.c
90 +++ src/modules.c
91 @@ -2846,7 +2846,7 @@
92
93
94 #ifndef _WIN32
95 - snprintf(dirbuf, BUFSIZE, "%s/modules/runtime", services_dir);
96 + snprintf(dirbuf, BUFSIZE, "%s/modules/runtime", LIB_DIR);
97 #else
98 snprintf(dirbuf, BUFSIZE, "\\%s", "modules/runtime");
99 #endif
100 --- src/language.c
101 +++ src/language.c
102 @@ -71,7 +71,7 @@
103 alog("debug: Loading language %d from file `languages/%s'",
104 index, filename);
105 }
106 - snprintf(buf, sizeof(buf), "languages/%s", filename);
107 + snprintf(buf, sizeof(buf), "%s/languages/%s", LIB_DIR, filename);
108 #ifndef _WIN32
109 if (!(f = fopen(buf, "r"))) {
110 #else
111
112
113
114 1.1 net-irc/anope/files/anope-init.d
115
116 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-irc/anope/files/anope-init.d?rev=1.1&view=markup
117 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-irc/anope/files/anope-init.d?rev=1.1&content-type=text/plain
118
119 Index: anope-init.d
120 ===================================================================
121 #!/sbin/runscript
122 # Copyright 1999-2011 Gentoo Foundation
123 # Distributed under the terms of the GNU General Public License v2
124 # $Header: /var/cvsroot/gentoo-x86/net-irc/anope/files/anope-init.d,v 1.1 2011/12/28 20:25:48 gurligebis Exp $
125
126 extra_started_commands="reload"
127
128 depend() {
129 use net mysql ircd
130 provide irc-services
131 }
132
133 start() {
134 ebegin "Starting Anope IRC Services"
135 start-stop-daemon --start --exec /usr/bin/services \
136 --user ${ANOPE_USER} --pidfile /var/run/anope/services.pid \
137 -- ${ANOPE_OPTS}
138 eend $?
139 }
140
141 stop() {
142 ebegin "Stopping Anope IRC Services"
143 start-stop-daemon --stop --pidfile /var/run/anope/services.pid
144 eend $?
145 }
146
147 reload() {
148 ebegin "Reloading Anope IRC Services"
149 start-stop-daemon --signal USR2 --exec /usr/bin/services \
150 --pidfile /var/run/anope/services.pid
151 eend $?
152 }
153
154
155
156
157 1.1 net-irc/anope/files/anope-1.8.7-ldflags-fix.patch
158
159 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-irc/anope/files/anope-1.8.7-ldflags-fix.patch?rev=1.1&view=markup
160 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-irc/anope/files/anope-1.8.7-ldflags-fix.patch?rev=1.1&content-type=text/plain
161
162 Index: anope-1.8.7-ldflags-fix.patch
163 ===================================================================
164 diff -aurp a/src/core/Makefile b/src/core/Makefile
165 --- a/src/core/Makefile 2010-10-10 19:55:31.396999906 +0000
166 +++ b/src/core/Makefile 2010-10-10 19:53:54.877001245 +0000
167 @@ -24,7 +24,7 @@ distclean: spotless
168 $(CC) ${CFLAGS} ${CDEFS} ${MODULEFLAGS} -I../${INCLUDEDIR} -c $<
169
170 .o.s:
171 - $(CC) ${SHARED} ../mod_version.o $< -o $*.so ${PROFILE}
172 + $(CC) $(CFLAGS) $(LDFLAGS) ${SHARED} ../mod_version.o $< -o $*.so ${PROFILE}
173 @$(TOUCH) $*.s
174
175 subs:
176 diff -aurp a/src/modules/Makefile b/src/modules/Makefile
177 --- a/src/modules/Makefile 2010-10-10 19:55:32.486000023 +0000
178 +++ b/src/modules/Makefile 2010-10-10 19:54:07.240000026 +0000
179 @@ -27,7 +27,7 @@ distclean: spotless
180 $(CC) ${CFLAGS} ${CDEFS} ${MODULEFLAGS} -I../${INCLUDEDIR} -c $<
181
182 .o.s:
183 - $(CC) ${SHARED} ../mod_version.o $< -o $*.so ${PROFILE}
184 + $(CC) $(CFLAGS) $(LDFLAGS) ${SHARED} ../mod_version.o $< -o $*.so ${PROFILE}
185 @$(TOUCH) $*.s
186
187 subs:
188 diff -aurp a/src/protocol/Makefile b/src/protocol/Makefile
189 --- a/src/protocol/Makefile 2010-10-10 19:55:33.605002302 +0000
190 +++ b/src/protocol/Makefile 2010-10-10 19:54:19.271997806 +0000
191 @@ -24,7 +24,7 @@ distclean: clean spotless
192 $(CC) ${CFLAGS} ${CDEFS} ${MODULEFLAGS} -I../${INCLUDEDIR} -c $<
193
194 .o.s:
195 - $(CC) ${SHARED} ../mod_version.o $< -o $*.so ${PROFILE}
196 + $(CC) $(CFLAGS) $(LDFLAGS) ${SHARED} ../mod_version.o $< -o $*.so ${PROFILE}
197 @$(TOUCH) $*.s
198
199 subs:
200 --- a/src/tools/Makefile 2011-12-28 20:00:00.646427623 +0000
201 +++ b/src/tools/Makefile 2011-12-28 20:00:41.030430806 +0000
202 @@ -10,7 +10,7 @@ MAKEARGS = 'CFLAGS=${CFLAGS}' 'CC=${CC}'
203 'RUNGROUP=${RUNGROUP}'
204
205 .c.o:
206 - $(CC) $(CFLAGS) -I../include/ $< -o $*
207 + $(CC) $(LDFLAGS) $(CFLAGS) -I../include/ $< -o $*
208
209 all: ${OBJS}
210
211
212
213
214 1.1 net-irc/anope/files/anope-conf.d
215
216 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-irc/anope/files/anope-conf.d?rev=1.1&view=markup
217 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-irc/anope/files/anope-conf.d?rev=1.1&content-type=text/plain
218
219 Index: anope-conf.d
220 ===================================================================
221 # Copyright 1999-2011 Gentoo Foundation
222 # Distributed under the terms of the GNU General Public License v2
223 # $Header: /var/cvsroot/gentoo-x86/net-irc/anope/files/anope-conf.d,v 1.1 2011/12/28 20:25:48 gurligebis Exp $
224
225 # user to run ultimate-ircd as
226 ANOPE_USER="anope"
227
228 # Additional commandline parameters
229 ANOPE_OPTS=""