2 # Copyright (C) 2009-2010 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_SOURCE_URL
:=http
://znc.in
/releases
16 PKG_MD5SUM
:=5667b4acb1f01309d6eded77abac700c
20 include $(INCLUDE_DIR
)/package.mk
22 define Package
/znc
/default
23 SUBMENU
:=Instant Messaging
27 URL
:=http
://en.znc.in
/
28 MAINTAINER
:=Jonas Gorski
<jonas.gorski
+openwrt@gmail.com
>
32 $(Package
/znc
/default
)
33 DEPENDS
:=+libopenssl
+uclibcxx
37 define Package
/znc
/description
38 ZNC is an IRC bouncer with many advanced features like detaching
,
39 multiple users
, per channel playback buffer
, SSL
, IPv6
, transparent DCC
40 bouncing
, and c
++ module support to name a few.
43 define Package
/znc
/conffiles
49 CXX
="$(STAGING_DIR)/host/bin/g++-uc" \
50 CXXFLAGS
="$(TARGET_CFLAGS) -fno-builtin -fno-rtti -nostdinc++" \
51 CPPFLAGS
="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
52 LDFLAGS
="-nodefaultlibs -L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
53 LIBS
="-luClibc++ -lm -lssl -lcrypto $(LIBGCC_S) -lc"
61 CXX
="$(STAGING_DIR)/host/bin/g++-uc"
63 define Build
/Configure
64 $(call Build
/Configure
/Default
,)
65 $(call libtool_disable_rpath
)
69 $(call Build
/Compile
/Default
,znc modules
)
72 define Package
/znc
/install
73 $(INSTALL_DIR
) $(1)/usr
/bin
74 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/znc
$(1)/usr
/bin
/
75 $(INSTALL_DIR
) $(1)/etc
/init.d
76 $(INSTALL_BIN
) .
/files
/znc.init
$(1)/etc
/init.d
/znc
77 $(INSTALL_DIR
) $(1)/etc
/config
78 $(INSTALL_DATA
) .
/files
/znc.conf
$(1)/etc
/config
/znc
79 $(INSTALL_DIR
) $(1)/usr
/lib
/znc
/
80 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/modules
/extra
/droproot.so
$(1)/usr
/lib
/znc
/
87 define Package
/znc-mod-
$(strip $(1))
88 $(Package
/znc
/default
)
89 TITLE
+= ($(strip $(1)) plugin
)
93 define Package
/znc-mod-
$(strip $(1))/description
97 define Package
/znc-mod-
$(strip $(1))/install
98 $(INSTALL_DIR
) $$(1)/usr
/lib
/znc
/
99 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/modules
/$(strip $(3))$(subst -,_
,$(strip $(1))).so
$$(1)/usr
/lib
/znc
/
102 ZNC_MODULES
+= znc-mod-
$(strip $(1))
108 $(eval
$(call module
,admin
,Allows you to add
/remove
/edit users and settings on \
109 the fly via IRC messages.
))
111 $(eval
$(call module
,adminlog
,Log user connects and disconnects and failed \
112 logins to file or syslog.
))
114 $(eval
$(call module
,autoattach
,Reattaches you to channels on activity.
))
116 $(eval
$(call module
,autocycle
,Cycles a channel when you are the only one in \
117 there and you don
't have op.))
119 $(eval $(call module,autoop,Auto op the good guys.))
121 $(eval $(call module,autoreply,Gives a automatic reply if someone messages you \
124 $(eval $(call module,away,Stores messages while away$(,) also auto away.))
126 $(eval $(call module,awaynick,Change your nick while you are away.))
128 $(eval $(call module,blockuser,Blocks certain users from using ZNC saying \
129 their account was disabled.))
131 $(eval $(call module,buffextras,Add nick changes$(,) joins$(,) parts$(,) topic \
132 changes etc. to your playback buffer.))
134 $(eval $(call module,certauth,This module allows users to log in via SSL \
137 $(eval $(call module,chansaver,Keeping config up to date when user joins and \
140 $(eval $(call module,clientnotify,Notify about new incoming connections to \
143 $(eval $(call module,crypt,Encryption for channel/private messages.))
145 $(eval $(call module,disconkick,This module will kick your client from all \
146 channels where you are$(,) in case if ZNC disconnects from server.))
148 $(eval $(call module,fail2ban,Block IPs for some time after a failed login.))
150 $(eval $(call module,fixfreenode,This module blocks some freenode-specific \
151 feature which results in plus (+) and minus (-) signs being displayed in \
152 front of every message from a client.))
154 $(eval $(call module,keepnick,Tries to get you your primary nick.))
156 $(eval $(call module,kickrejoin,Implements auto-rejoin-on-kick.))
158 $(eval $(call module,lastseen,Logs when a user last logged in to ZNC.))
160 $(eval $(call module,nickserv,Auths you with NickServ.))
162 $(eval $(call module,notes,This modules stores and displays short notes using \
163 a key/note pairs and shows them to you on connect.))
165 $(eval $(call module,partyline,Allows ZNC users to join internal channels and \
166 query other ZNC users on the same ZNC.))
168 $(eval $(call module,perform,Performs commands on connect.))
170 $(eval $(call module,q,Auths you with Q (and a little more).))
172 $(eval $(call module,raw,View all of the raw traffic.))
174 $(eval $(call module,route-replies,Routes back answers to the right client \
175 when connected with multiple clients.))
177 $(eval $(call module,savebuff,Saves your channel buffers into an encrypted \
178 file so they can survive restarts and reboots.))
180 $(eval $(call module,schat,SSL (encrypted) DCC chats.))
182 $(eval $(call module,simple-away,This module will automatically set you away \
183 on IRC while you are disconnected from the bouncer.))
185 $(eval $(call module,stickychan,Keeps you sticked to specific channels.))
187 $(eval $(call module,watch,Monitor activity for specific text patterns from \
188 specific users and have the text sent to a special query window.))
190 $(eval $(call module,webadmin,Allows you to add/remove/edit users and settings \
191 on the fly via a web browser.))
193 $(eval $(call module,antiidle,Hides your idle time.,extra/))
195 $(eval $(call module,autovoice,Autovoices everyone who joins some channel., \
198 $(eval $(call module,block-motd,This module blocks the server's Message of the \
201 $(eval
$(call module
,clearbufferonmsg
,This module keeps the buffer until the \
202 next message from the client.
,extra
/))
204 $(eval
$(call module
,ctcpflood
,This module tries to block ctcp floods.
,extra
/))
206 $(eval
$(call module
,fakeonline
,This module fakes the online status of \
209 $(eval
$(call module
,flooddetach
,This module detaches you from channels which \
210 are flooded.
,extra
/))
212 $(eval
$(call module
,listsockets
,This module displays a list of
all open \
213 sockets in ZNC.
,extra
/))
215 $(eval
$(call module
,log
,Log conversations to file.
,extra
/))
217 $(eval
$(call module
,motdfile
,Reads a MOTD from a file and displays it to \
218 users when they login.
,extra
/))
220 $(eval
$(call module
,notify-connect
,Sends a notice to
all admins when a user \
221 logs in or out.
,extra
/))
223 $(eval
$(call module
,send-raw
,Allows you to send raw traffic to IRC from \
224 other users.
,extra
/))
226 $(eval
$(call module
,shell,Have your unix
shell in a query window right inside \
227 of your IRC client.
,extra
/))
229 $(eval
$(call BuildPackage
,znc
))
231 PKG_CONFIG_DEPENDS
:= $(patsubst %,CONFIG_PACKAGE_
%,$(ZNC_MODULES
))
232 $(foreach m
,$(ZNC_MODULES
),$(eval
$(call BuildPackage
,$(m
))))