make distversion on this
This commit is contained in:
parent
9750ec5030
commit
d9d4b64114
5 changed files with 4115 additions and 2984 deletions
52
Makefile.in
52
Makefile.in
|
@ -46,7 +46,7 @@ DIST_COMMON = $(am__configure_deps) $(dist_data_DATA) $(dist_doc_DATA) \
|
|||
autotools/mkinstalldirs install-sh
|
||||
subdir = .
|
||||
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||
am__aclocal_m4_deps = \
|
||||
am__aclocal_m4_deps = $(top_srcdir)/autotools/ax_distversion.m4 \
|
||||
$(top_srcdir)/autotools/ax_maintainer_mode_auto_silent.m4 \
|
||||
$(top_srcdir)/autotools/ccdv.m4 $(top_srcdir)/configure.in
|
||||
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||
|
@ -87,7 +87,6 @@ HEADERS = $(noinst_HEADERS)
|
|||
ETAGS = etags
|
||||
CTAGS = ctags
|
||||
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
|
||||
distdir = $(PACKAGE)-$(VERSION)
|
||||
top_distdir = $(distdir)
|
||||
am__remove_distdir = \
|
||||
{ test ! -d $(distdir) \
|
||||
|
@ -121,6 +120,7 @@ CYGPATH_W = @CYGPATH_W@
|
|||
DEFS = @DEFS@
|
||||
DEPDIR = @DEPDIR@
|
||||
DIRINST = @DIRINST@
|
||||
DISTDIRVERSION = @DISTDIRVERSION@
|
||||
ECHO = @ECHO@
|
||||
ECHO_C = @ECHO_C@
|
||||
ECHO_N = @ECHO_N@
|
||||
|
@ -129,6 +129,7 @@ EGREP = @EGREP@
|
|||
EXEEXT = @EXEEXT@
|
||||
F77 = @F77@
|
||||
FFLAGS = @FFLAGS@
|
||||
GREP = @GREP@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
|
@ -157,12 +158,9 @@ SHELL = @SHELL@
|
|||
STRIP = @STRIP@
|
||||
USECCDV = @USECCDV@
|
||||
VERSION = @VERSION@
|
||||
ac_ct_AR = @ac_ct_AR@
|
||||
ac_ct_CC = @ac_ct_CC@
|
||||
ac_ct_CXX = @ac_ct_CXX@
|
||||
ac_ct_F77 = @ac_ct_F77@
|
||||
ac_ct_RANLIB = @ac_ct_RANLIB@
|
||||
ac_ct_STRIP = @ac_ct_STRIP@
|
||||
am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
|
||||
am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
|
||||
am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
|
||||
|
@ -179,23 +177,30 @@ build_cpu = @build_cpu@
|
|||
build_os = @build_os@
|
||||
build_vendor = @build_vendor@
|
||||
datadir = $(prefix)/data
|
||||
datarootdir = @datarootdir@
|
||||
docdir = $(prefix)/doc
|
||||
dvidir = @dvidir@
|
||||
exec_prefix = @exec_prefix@
|
||||
host = @host@
|
||||
host_alias = @host_alias@
|
||||
host_cpu = @host_cpu@
|
||||
host_os = @host_os@
|
||||
host_vendor = @host_vendor@
|
||||
htmldir = @htmldir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
install_sh = @install_sh@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localedir = @localedir@
|
||||
localstatedir = @localstatedir@
|
||||
mandir = @mandir@
|
||||
mkdir_p = @mkdir_p@
|
||||
oldincludedir = @oldincludedir@
|
||||
pdfdir = @pdfdir@
|
||||
prefix = @prefix@
|
||||
program_transform_name = @program_transform_name@
|
||||
psdir = @psdir@
|
||||
sbindir = @sbindir@
|
||||
sharedstatedir = @sharedstatedir@
|
||||
sysconfdir = @sysconfdir@
|
||||
|
@ -211,10 +216,10 @@ feedserv_la_LDFLAGS = -module -avoid-version
|
|||
EXTRA_DIST = autotools/ccdv.c autotools/shtool RELNOTES
|
||||
dist_doc_DATA = README.feedserv README.feedserv.html
|
||||
dist_data_DATA = feeds.dat
|
||||
LINK = $(LIBTOOL) --tag=CXX --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
|
||||
LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
|
||||
$(AM_LDFLAGS) $(LDFLAGS) -o $@
|
||||
|
||||
docdir = $(prefix)/doc
|
||||
distdir = @DISTDIRVERSION@
|
||||
all: modconfig.h
|
||||
$(MAKE) $(AM_MAKEFLAGS) all-am
|
||||
|
||||
|
@ -482,24 +487,6 @@ distcheck: dist
|
|||
@(echo "$(distdir) archives ready for distribution: "; \
|
||||
list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
|
||||
sed -e '1{h;s/./=/g;p;x;}' -e '$${p;x;}'
|
||||
distuninstallcheck:
|
||||
@cd $(distuninstallcheck_dir) \
|
||||
&& test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \
|
||||
|| { echo "ERROR: files left after uninstall:" ; \
|
||||
if test -n "$(DESTDIR)"; then \
|
||||
echo " (check DESTDIR support)"; \
|
||||
fi ; \
|
||||
$(distuninstallcheck_listfiles) ; \
|
||||
exit 1; } >&2
|
||||
distcleancheck: distclean
|
||||
@if test '$(srcdir)' = . ; then \
|
||||
echo "ERROR: distcleancheck can only run from a VPATH build" ; \
|
||||
exit 1 ; \
|
||||
fi
|
||||
@test `$(distcleancheck_listfiles) | wc -l` -eq 0 \
|
||||
|| { echo "ERROR: files left in build directory after distclean:" ; \
|
||||
$(distcleancheck_listfiles) ; \
|
||||
exit 1; } >&2
|
||||
check-am: all-am
|
||||
check: check-am
|
||||
all-am: Makefile $(LTLIBRARIES) $(DATA) $(HEADERS) modconfig.h
|
||||
|
@ -729,6 +716,21 @@ install-libLTLIBRARIES: $(lib_LTLIBRARIES)
|
|||
if test "x#" != "x@USECCDV@"; then echo "Installing $$f"; fi; \
|
||||
else :; fi; \
|
||||
done
|
||||
|
||||
install-neoSCRIPTS: $(neo_SCRIPTS)
|
||||
@$(NORMAL_INSTALL)
|
||||
test -z "$(neodir)" || $(mkdir_p) "$(DESTDIR)$(neodir)"
|
||||
@list='$(neo_SCRIPTS)'; for p in $$list; do \
|
||||
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
|
||||
if test -f $$d$$p; then \
|
||||
f=`echo "$$p" | sed 's|^.*/||;$(transform)'`; \
|
||||
$(CCDV) $(neoSCRIPT_INSTALL) "$$d$$p" "$(DESTDIR)$(neodir)/$$f"; \
|
||||
else :; fi; \
|
||||
done
|
||||
distcleancheck:
|
||||
@:
|
||||
distuninstallcheck:
|
||||
@:
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
.NOEXPORT:
|
||||
|
|
20
aclocal.m4
vendored
20
aclocal.m4
vendored
|
@ -1578,27 +1578,10 @@ linux*)
|
|||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
# find out which ABI we are using
|
||||
libsuff=
|
||||
case "$host_cpu" in
|
||||
x86_64*|s390x*|powerpc64*)
|
||||
echo '[#]line __oline__ "configure"' > conftest.$ac_ext
|
||||
if AC_TRY_EVAL(ac_compile); then
|
||||
case `/usr/bin/file conftest.$ac_objext` in
|
||||
*64-bit*)
|
||||
libsuff=64
|
||||
sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
rm -rf conftest*
|
||||
;;
|
||||
esac
|
||||
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
||||
sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
|
@ -7271,5 +7254,6 @@ AC_SUBST([am__tar])
|
|||
AC_SUBST([am__untar])
|
||||
]) # _AM_PROG_TAR
|
||||
|
||||
m4_include([autotools/ax_distversion.m4])
|
||||
m4_include([autotools/ax_maintainer_mode_auto_silent.m4])
|
||||
m4_include([autotools/ccdv.m4])
|
||||
|
|
|
@ -91,6 +91,9 @@ esac],
|
|||
AC_MSG_RESULT(no)
|
||||
AX_MAINTAINER_MODE_AUTO_SILENT
|
||||
)
|
||||
|
||||
AX_DISTVERSION
|
||||
|
||||
AC_SUBST(DIRINST)
|
||||
AC_SUBST(CFLAGS)
|
||||
AC_SUBST(PACKAGE)
|
||||
|
|
81
feed.c
81
feed.c
|
@ -32,6 +32,8 @@ static int feed_cmd_del( const CmdParams *cmdparams );
|
|||
static int feed_cmd_info( const CmdParams *cmdparams );
|
||||
static int feed_set_exclusions_cb( const CmdParams *cmdparams, SET_REASON reason );
|
||||
static int feed_cmd_subscribe(const CmdParams *cmdparams);
|
||||
static int fs_subscribe_list(Client *c, char *what);
|
||||
static int fs_signoff_user(const CmdParams *cmdparams);
|
||||
static void FeedDownLoadHandler(void *ptr, int status, char *data, int datasize);
|
||||
static void FeedRequestHandler(void *usrptr, int status, char *data, int datasize);
|
||||
|
||||
|
@ -142,6 +144,8 @@ static BotInfo feed_botinfo =
|
|||
|
||||
ModuleEvent module_events[] =
|
||||
{
|
||||
{ EVENT_QUIT, fs_signoff_user, 0},
|
||||
{ EVENT_KILL, fs_signoff_user, 0},
|
||||
NS_EVENT_END()
|
||||
};
|
||||
|
||||
|
@ -404,6 +408,11 @@ static int feed_cmd_subscribe(const CmdParams *cmdparams)
|
|||
int get = 0;
|
||||
SET_SEGV_LOCATION();
|
||||
|
||||
if (!strcasecmp("list", cmdparams->av[0])) {
|
||||
fs_subscribe_list(cmdparams->source, cmdparams->ac == 2 ? cmdparams->av[1] : NULL);
|
||||
return NS_SUCCESS;
|
||||
}
|
||||
|
||||
get = atoi(cmdparams->av[0]);
|
||||
|
||||
node = list_first(lofeeds);
|
||||
|
@ -451,6 +460,7 @@ static int fs_subscribe(Client *C, feedinfo *fi) {
|
|||
SET_SEGV_LOCATION();
|
||||
hnode_t *hnode;
|
||||
subscribed *sub;
|
||||
hash_t *userhash;
|
||||
hnode = hnode_find(subscribedfeeds, fi->feedurl);
|
||||
if (!hnode) {
|
||||
/* its a new subscription for feeds */
|
||||
|
@ -469,6 +479,13 @@ static int fs_subscribe(Client *C, feedinfo *fi) {
|
|||
}
|
||||
/* subscribe this user */
|
||||
hnode_create_insert(sub->users, C->name, C->name);
|
||||
/* store this feed in the users feed list */
|
||||
userhash = (hash_t *) GetUserModValue(C);
|
||||
if (!userhash) {
|
||||
userhash = hash_create(HASHCOUNT_T_MAX, NULL, NULL);
|
||||
SetUserModValue(C, userhash);
|
||||
}
|
||||
hnode_create_insert(userhash, sub, sub->feed->feedurl);
|
||||
DBAStore("feedsusers", sub->feed->feedurl, (void *)C->name, sizeof(C->name));
|
||||
if (!FindTimer("CheckSubscriptions")) {
|
||||
/* timer is not active */
|
||||
|
@ -478,6 +495,70 @@ static int fs_subscribe(Client *C, feedinfo *fi) {
|
|||
return NS_SUCCESS;
|
||||
}
|
||||
|
||||
/** @brief fs_subscribe_list
|
||||
*
|
||||
* display list of subscribed feeds
|
||||
*
|
||||
* @cmdparams pointer to the client
|
||||
* @cmdparams optional channel name
|
||||
*
|
||||
* @return NS_SUCCESS if suceeds else NS_FAILURE
|
||||
*/
|
||||
|
||||
static int fs_subscribe_list(Client *c, char *what) {
|
||||
|
||||
}
|
||||
|
||||
/** @brief fs_signoff_user
|
||||
*
|
||||
* signoff a user and delete any subscribed feeds he has
|
||||
*
|
||||
* @cmdparams pointer to the client
|
||||
*
|
||||
* @return NS_SUCCESS if suceeds else NS_FAILURE
|
||||
*/
|
||||
|
||||
static int fs_signoff_user(const CmdParams *cmdparams) {
|
||||
hash_t *userhash;
|
||||
hnode_t *hnode, *subfeednode, *usernode;
|
||||
|
||||
hscan_t hscan;
|
||||
subscribed *sub;
|
||||
userhash = (hash_t *) GetUserModValue(cmdparams->source);
|
||||
if (!userhash)
|
||||
return NS_SUCCESS;
|
||||
/* else, cycle through all the feeds and unsub them */
|
||||
hash_scan_begin(&hscan, userhash);
|
||||
while ((hnode = hash_scan_next(&hscan)) != NULL) {
|
||||
sub = hnode_get(hnode);
|
||||
/* find the feed in the subscribed feeds hash */
|
||||
subfeednode = hnode_find(subscribedfeeds, sub->feed->feedurl);
|
||||
if (!subfeednode) {
|
||||
nlog(LOG_WARNING, "Subscribers Feed Inconsistancies");
|
||||
continue;
|
||||
}
|
||||
/* if the count of users is 1 and chans is 0, then we can just remove the subscription */
|
||||
if ((hash_count(sub->users) == 1) && (hash_count(sub->chans) == 0)) {
|
||||
printf("%s\n", sub->feed->feedurl);
|
||||
printf("%s\n", hnode_getkey(subfeednode));
|
||||
hash_delete_destroy_node(subscribedfeeds, subfeednode);
|
||||
} else {
|
||||
/* the feed is more complex */
|
||||
usernode = hnode_find(sub->users, cmdparams->source->name);
|
||||
if (usernode) {
|
||||
hash_delete_destroy_node(sub->users, usernode);
|
||||
} else {
|
||||
nlog(LOG_WARNING, "Subscribers Users Hash is busted");
|
||||
}
|
||||
}
|
||||
}
|
||||
hash_destroy(userhash);
|
||||
ClearUserModValue(cmdparams->source);
|
||||
return NS_SUCCESS;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/** @brief feed_set_exclusions_cb
|
||||
*
|
||||
* Set callback for exclusions
|
||||
|
|
Reference in a new issue