[packages] glib2: fix autoreconf
[openwrt/svn-archive/archive.git] / net / znc / Makefile
1 #
2 # Copyright (C) 2009-2010 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=znc
11 PKG_VERSION:=0.096
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=@SF/znc
16 PKG_MD5SUM:=38eec4f1911a68b4d2fc704170e7cbf6
17
18 PKG_BUILD_PARALLEL:=1
19
20 include $(INCLUDE_DIR)/package.mk
21
22 define Package/znc/default
23 SUBMENU:=Instant Messaging
24 SECTION:=net
25 CATEGORY:=Network
26 TITLE:=ZNC
27 URL:=http://en.znc.in/
28 endef
29
30 define Package/znc
31 $(Package/znc/default)
32 DEPENDS:=+libopenssl +uclibcxx
33 MENU:=1
34 endef
35
36 define Package/znc/description
37 ZNC is an IRC bouncer with many advanced features like detaching,
38 multiple users, per channel playback buffer, SSL, IPv6, transparent DCC
39 bouncing, and c++ module support to name a few.
40 endef
41
42 define Package/znc/conffiles
43 /etc/config/znc
44 endef
45
46
47 CONFIGURE_VARS += \
48 CXX="$(STAGING_DIR)/host/bin/g++-uc" \
49 CXXFLAGS="$(TARGET_CFLAGS) -fno-builtin -fno-rtti -nostdinc++" \
50 CPPFLAGS="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
51 LDFLAGS="-nodefaultlibs -L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
52 LIBS="-luClibc++ -lm -lssl -lcrypto $(LIBGCC_S) -lc"
53
54 CONFIGURE_ARGS += \
55 --disable-c-ares \
56 --enable-extra \
57 --disable-perl
58
59 MAKE_FLAGS += \
60 CXX="$(STAGING_DIR)/host/bin/g++-uc"
61
62 define Build/Configure
63 # webadmin doesn't compile
64 $(RM) $(PKG_BUILD_DIR)/modules/webadmin.cpp
65 $(call Build/Configure/Default,)
66 $(call libtool_disable_rpath)
67 endef
68
69 define Package/znc/install
70 $(INSTALL_DIR) $(1)/usr/bin
71 $(INSTALL_BIN) $(PKG_BUILD_DIR)/znc $(1)/usr/bin/
72 $(INSTALL_DIR) $(1)/etc/init.d
73 $(INSTALL_BIN) ./files/znc.init $(1)/etc/init.d/znc
74 $(INSTALL_DIR) $(1)/etc/config
75 $(INSTALL_DATA) ./files/znc.conf $(1)/etc/config/znc
76 $(INSTALL_DIR) $(1)/usr/lib/znc/
77 $(INSTALL_BIN) $(PKG_BUILD_DIR)/modules/extra/droproot.so $(1)/usr/lib/znc/
78 endef
79
80
81 ZNC_MODULES :=
82
83 define module
84 define Package/znc-mod-$(strip $(1))
85 $(Package/znc/default)
86 TITLE+= ($(strip $(1)) plugin)
87 DEPENDS:=znc
88 endef
89
90 define Package/znc-mod-$(strip $(1))/description
91 $(strip $(2))
92 endef
93
94 define Package/znc-mod-$(strip $(1))/install
95 $(INSTALL_DIR) $$(1)/usr/lib/znc/
96 $(INSTALL_BIN) $(PKG_BUILD_DIR)/modules/$(strip $(3))$(subst -,_,$(strip $(1))).so $$(1)/usr/lib/znc/
97 endef
98
99 ZNC_MODULES += znc-mod-$(strip $(1))
100 endef
101
102
103 , := ,
104
105 $(eval $(call module,admin,Allows you to add/remove/edit users and settings on \
106 the fly via IRC messages.))
107
108 $(eval $(call module,adminlog,Log user connects and disconnects and failed \
109 logins to file or syslog.))
110
111 $(eval $(call module,autoattach,Reattaches you to channels on activity.))
112
113 $(eval $(call module,autocycle,Cycles a channel when you are the only one in \
114 there and you don't have op.))
115
116 $(eval $(call module,autoop,Auto op the good guys.))
117
118 $(eval $(call module,autoreply,Gives a automatic reply if someone messages you \
119 if you are away.))
120
121 $(eval $(call module,away,Stores messages while away$(,) also auto away.))
122
123 $(eval $(call module,awaynick,Change your nick while you are away.))
124
125 $(eval $(call module,blockuser,Blocks certain users from using ZNC saying \
126 their account was disabled.))
127
128 $(eval $(call module,buffextras,Add nick changes$(,) joins$(,) parts$(,) topic \
129 changes etc. to your playback buffer.))
130
131 $(eval $(call module,certauth,This module allows users to log in via SSL \
132 client keys.))
133
134 $(eval $(call module,chansaver,Keeping config up to date when user joins and \
135 parts.))
136
137 $(eval $(call module,clientnotify,Notify about new incoming connections to \
138 your user.))
139
140 $(eval $(call module,crypt,Encryption for channel/private messages.))
141
142 $(eval $(call module,disconkick,This module will kick your client from all \
143 channels where you are$(,) in case if ZNC disconnects from server.))
144
145 $(eval $(call module,fail2ban,Block IPs for some time after a failed login.))
146
147 $(eval $(call module,fixfreenode,This module blocks some freenode-specific \
148 feature which results in plus (+) and minus (-) signs being displayed in \
149 front of every message from a client.))
150
151 $(eval $(call module,keepnick,Tries to get you your primary nick.))
152
153 $(eval $(call module,kickrejoin,Implements auto-rejoin-on-kick.))
154
155 $(eval $(call module,lastseen,Logs when a user last logged in to ZNC.))
156
157 $(eval $(call module,nickserv,Auths you with NickServ.))
158
159 $(eval $(call module,notes,This modules stores and displays short notes using \
160 a key/note pairs and shows them to you on connect.))
161
162 $(eval $(call module,partyline,Allows ZNC users to join internal channels and \
163 query other ZNC users on the same ZNC.))
164
165 $(eval $(call module,perform,Performs commands on connect.))
166
167 $(eval $(call module,q,Auths you with Q (and a little more).))
168
169 $(eval $(call module,raw,View all of the raw traffic.))
170
171 $(eval $(call module,route-replies,Routes back answers to the right client \
172 when connected with multiple clients.))
173
174 $(eval $(call module,savebuff,Saves your channel buffers into an encrypted \
175 file so they can survive restarts and reboots.))
176
177 $(eval $(call module,schat,SSL (encrypted) DCC chats.))
178
179 $(eval $(call module,simple-away,This module will automatically set you away \
180 on IRC while you are disconnected from the bouncer.))
181
182 $(eval $(call module,stickychan,Keeps you sticked to specific channels.))
183
184 $(eval $(call module,watch,Monitor activity for specific text patterns from \
185 specific users and have the text sent to a special query window.))
186
187 $(eval $(call module,antiidle,Hides your idle time.,extra/))
188
189 $(eval $(call module,autovoice,Autovoices everyone who joins some channel., \
190 extra/))
191
192 $(eval $(call module,block-motd,This module blocks the server's Message of the \
193 Day.,extra/))
194
195 $(eval $(call module,clearbufferonmsg,This module keeps the buffer until the \
196 next message from the client.,extra/))
197
198 $(eval $(call module,ctcpflood,This module tries to block ctcp floods.,extra/))
199
200 $(eval $(call module,fakeonline,This module fakes the online status of \
201 ZNC-*users.,extra/))
202
203 $(eval $(call module,flooddetach,This module detaches you from channels which \
204 are flooded.,extra/))
205
206 $(eval $(call module,listsockets,This module displays a list of all open \
207 sockets in ZNC.,extra/))
208
209 $(eval $(call module,log,Log conversations to file.,extra/))
210
211 $(eval $(call module,motdfile,Reads a MOTD from a file and displays it to \
212 users when they login.,extra/))
213
214 $(eval $(call module,notify-connect,Sends a notice to all admins when a user \
215 logs in or out.,extra/))
216
217 $(eval $(call module,send-raw,Allows you to send raw traffic to IRC from \
218 other users.,extra/))
219
220 $(eval $(call module,shell,Have your unix shell in a query window right inside \
221 of your IRC client.,extra/))
222
223 $(eval $(call BuildPackage,znc))
224
225 PKG_CONFIG_DEPENDS := $(patsubst %,CONFIG_PACKAGE_%,$(ZNC_MODULES))
226 $(foreach m,$(ZNC_MODULES),$(eval $(call BuildPackage,$(m))))