diff --git a/ChangeLog b/ChangeLog index d978876a..e5d031f5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,460 @@ // $Id: ChangeLog,v 1.173 2010/04/10 18:56:06 danielaustin Exp $ // +2025-10-17 MrIron + * src/main.cc: + * include/server.h: + * include/gnuworld_config.h: Refactored command-line argument parsing. + Moved parsing from xServer constructor to main() for cleaner design. + Forking into background is now default behavior unless -c (verbose) + flag is specified. Removed DAEMON compile-time define from + gnuworld_config.h. Removed obsolete dupArray/releaseDup functions. + xServer constructor now takes parsed configuration parameters + instead of argc/argv. Moved GNU banner display to after forking + so it's shown by the actual running process. + * src/server_connection.cc: Fixed socket logging to flush after each + write, preventing empty socket.log file when running in daemon mode. + * mod.cservice/cservice.cc: Fixed channel loading query to use + LEFT JOIN with pending table, preventing errors when pending + entries are cleaned up. Added check to skip channels with no + manager assigned during database updates. Updated Prometheus + metric names to remove redundant prefix. Fixed welcome topic + logic to only apply during The Judge registration, not via REGISTER + command. + * libgnuworld/prometheus.cc: + * libgnuworld/prometheus.h: Prometheus metric name improvements. + +2025-10-10 MrIron + * doc/README.logger (new file): Documentation for logger engine. + * libgnuworld/logger.cc (new file): + * libgnuworld/logger.h (new file): + * libgnuworld/notifier.h (new file): + * libgnuworld/pushover.cc (new file): + * libgnuworld/pushover.h (new file): + * libgnuworld/threadworker.cc (new file): + * libgnuworld/threadworker.h (new file): + * libgnuworld/prometheus.cc (new file): + * libgnuworld/prometheus.h (new file): Added comprehensive logging, + monitoring, and notification infrastructure to core. Logger engine + initialised for each xClient with configurable verbosity levels to + post messages to debug channel and elog. JSON logging capability + with support for passing core objects to extract info. Notifier + base class with Pushover implementation - notifiers can be added + to Logger engine with configurable verbosity levels. Threadworker + engine for asynchronous job processing (currently used by pushover). + Prometheus metrics support for monitoring and statistics collection. + Support for external log rotation (SIGHUP). + * include/Channel.h: + * include/client.h: + * src/Channel.cc: + * src/Network.cc: + * src/client.cc: Thread safe access to iClient and Channel objects + for threadworker. + * db/dbHandle.h: + * db/pgsqlDB.cc: + * db/pgsqlDB.h: psql engine tied into Logger to output queries for + debug purposes (enable with logger->setlogSQL(true)). + * libgnuworld/misc.cc: + * libgnuworld/misc.h: JSON helper functions and password redacting + functionality. + * bin/cservice.example.conf: + * mod.cservice/*Command.cc: + * mod.cservice/cservice.cc: + * mod.cservice/cservice.h: + * mod.cservice/cservice_config.h: + * mod.cservice/cservice_confvars.h (new file): Integration with + Logger, Pushover, and Prometheus. Only log and increase stats + for successful commands. Removed unnecessary query logging, + fixed proper query error logging. Redacting sensitive information + from logs. Config variables singled out to cservice_confvars.h. + Clean-up in module header. + * Makefile.in: + * configure: + * configure.ac: Updated build system for new dependencies (libcurl + via pkgconf). Conditional compilation for systems without . + +2025-09-12 MrIron + * mod.cservice/cservice.cc: + * mod.cservice/cservice_config.h: Fix command log. Redact sensitive + information. + +2025-05-27 MrIron + * mod.cloner/cloner.cc: Simplifications to mod.cloner, and use of + new config parser. + +2025-04-30 MrIron + * mod.cloner/cloner.cc: + * mod.cloner/cloner.h: + * src/server.cc: Memory cleanup in core and mod.cloner. + +2025-04-22 MrIron + * libgnuworld/EConfig.cc: + * libgnuworld/EConfig.h: Added TryRequire intended for rehashes to + retain current value and return error. Parse config to correct + type safely. + +2025-04-21 MrIron + * libgnuworld/misc.cc: Make prettyNumber safe when en_US.UTF-8 is + not installed on the system. Thanks to naka for spotting this. + +2025-04-18 MrIron + * mod.cloner/cloner.cc: Added quit command. Fixed iteration bug in + quitClones. + +2025-04-17 MrIron + * mod.cservice/cservice.cc: Trigger sendAccountFlags on indirect + net merge. + +2025-04-11 MrIron + * db/gnuworldDB.h: + * db/pgsqlDB.cc: + * db/pgsqlDB.h: + * mod.cloner/cloner.cc: Added affectedRows() to psql engine. + +2025-04-08 MrIron + * mod.cloner/cloner.cc: + * mod.cloner/cloner.h: Added new cycle feature. Parse correct + base64 for ip hosts. + +2025-01-21 MrIron + * include/gnuworld_config.h: + * libgnuworld/misc.cc: + * libgnuworld/misc.h: + * mod.ccontrol/TOPICCommand.cc: + * mod.cservice/cservice.cc: + * mod.openchanfix/STATUSCommand.cc: + * mod.openchanfix/chanfix.cc: Added rusage to mod.cservice. + Function included in libgnuworld, and removed code repetition. + +2025-01-15 MrIron + * libgnuworld/misc.cc: + * libgnuworld/misc.h: + * mod.cservice/SETCommand.cc: + * mod.cservice/cservice.cc: Don't burst +l when FLOATLIM is ON. + +2025-01-11 MrIron + * mod.cservice/cservice.cc: Make ISUSER case insensitive. + +2025-01-09 MrIron + * include/events.h: + * include/gnuworld_config.h: + * include/iClient.h: + * include/server.h: + * libircu/msg_AC.cc: + * libircu/msg_N.cc: + * mod.ccontrol/TOPICCommand.cc: + * mod.ccontrol/WHOISCommand.cc: + * mod.ccontrol/ccontrol.cc: + * mod.cloner/cloner.cc: + * mod.cservice/MODINFOCommand.cc: + * mod.cservice/SUSPENDCommand.cc: + * mod.cservice/SUSPENDMECommand.cc: + * mod.cservice/TOPICCommand.cc: + * mod.cservice/UNSUSPENDCommand.cc: + * mod.cservice/cservice.cc: + * mod.cservice/cservice.h: + * mod.cservice/cservice_config.h: + * mod.dronescan/FAKECommand.cc: + * mod.gnutest/gnutest.cc: + * mod.nickserv/nickserv.cc: + * mod.snoop/snoop.cc: + * src/iClient.cc: + * src/server.cc: Initial implementation of account flags (AC + message parsing). Misc minor fixes. Disabled USE_AC_XFLAGS + per default. + +2025-01-08 MrIron + * mod.cservice/cservice.h: Added missing header required by + certain compiler versions. + +2025-01-07 MrIron + * libgnuworld/misc.h: + * mod.cservice/cservice.cc: + * mod.cservice/cservice.h: + * mod.cservice/sqlUser.cc: + * mod.cservice/sqlUser.h: Refactored ISUSER XQuery to return + bitflags. Added timepoint functions to libgnuworld. + +2025-01-03 MrIron + * mod.cservice/cservice.cc: Fix to lookup of usernames in ISUSER. + Added TOTP flag to response. + +2024-12-22 MrIron + * include/Network.h: + * src/server.cc: XQuery and XReply do PostEvent instead of sending + to socket if destined to itself (multiple modules). + * mod.cservice/PURGECommand.cc: + * mod.cservice/cservice.cc: + * mod.cservice/cservice.h: New ISUSER and ISCHAN handlers, and + sends REMUSER when expiring usernames. + +2024-12-02 MrIron + * libircu/msg_T.cc: Added support for bursting of topic nick in P10. + +2024-10-23 MrIron + * include/Channel.h: Returning userList container to allow for + range-based loops. + +2024-10-22 MrIron + * doc/cmaster/cservice_langdump.sh (new file): Added language dump + script. + * mod.cservice/CLEARMODECommand.cc: Added mode cC to cservice::CLEARMODE. + +2024-10-10 MrIron + * mod.cservice/UNBANCommand.cc: Don't send bans_removed response if + the nick is not online. + +2024-10-09 MrIron + * mod.cservice/HELPCommand.cc: Shows default HELP message if no + command is specified. + +2024-09-30 MrIron + * libgnuworld/misc.cc: Fix escaping. + +2024-09-26 MrIron + * include/Network.h: + * include/iClient.h: + * src/client.cc: Made available core containers to allow for + range-based for loops. + * mod.cservice/cservice.cc: Fixed checks in cservice::expireBans. + * mod.ccontrol/HELPCommand.cc: + * mod.cservice/SHOWIGNORECommand.cc: + * mod.cservice/cservice.h: Clean-up in derived Notice functions. + +2024-08-31 MrIron + * configure: + * configure.ac: + * include/server.h: + * src/Network.cc: + * src/server.cc: Fixed compiler warnings. + * mod.cservice/STATUSCommand.cc: Improved STATUS output of flags. + * mod.cservice/UNBANCommand.cc: Initialise bancounter. + +2024-08-21 MrIron + * doc/update_help_modes_20240525.sql: Added updates to Werewolf + and GOT translation languages. + * mod.stats/stats.cc: + * mod.stats/stats.h: Fix after adding EVT_BURST caused it to break. + +2024-08-20 MrIron + * mod.cservice/DEOPCommand.cc: + * mod.cservice/DEVOICECommand.cc: + * mod.cservice/OPCommand.cc: + * mod.cservice/VOICECommand.cc: + * mod.cservice/SCANHOSTCommand.cc: + * mod.cservice/cservice.cc: + * src/main.cc: Various fixes. + +2024-08-18 MrIron + * libgnuworld/misc.cc: + * libgnuworld/misc.h: Added function to parse an epoch timestamp + adjusted for a timezone, and a function to validate a suggested + timezone. prettyTime() replaces tsToDateTime() which returned + a string based on gnuworlds localtime. + * mod.ccontrol/LIMITSCommand.cc: + * mod.ccontrol/MODUSERCommand.cc: + * mod.ccontrol/NOMODECommand.cc: + * mod.ccontrol/REMCOMMANDCommand.cc: + * mod.ccontrol/REMGCHANCommand.cc: + * mod.ccontrol/REMSERVERCommand.cc: + * mod.ccontrol/REMUSERCommand.cc: + * mod.ccontrol/SGLINECommand.cc: + * mod.ccontrol/SUSPENDCommand.cc: + * mod.ccontrol/UNSUSPENDCommand.cc: + * mod.ccontrol/ccUser.cc: + * mod.ccontrol/ccontrol.cc: Removed SQL escaping for gnuworld + getters and setters, and added SQL escaping on SQL queries only. + * mod.openchanfix/CANFIXCommand.cc: + * mod.openchanfix/HISTORYCommand.cc: + * mod.openchanfix/INFOCommand.cc: + * mod.openchanfix/OPLISTCommand.cc: + * mod.openchanfix/SIMULATECommand.cc: + * mod.openchanfix/USERSCORESCommand.cc: + * mod.openchanfix/chanfix.cc: Moved to use prettyTime() instead + of tsToDateTime(). + +2024-08-14 MrIron + * libgnuworld/misc.cc: + * libgnuworld/misc.h: Included escapeSQLChars and searchSQL + functions in libgnuworld/misc.cc and removed duplicate functions + in modules. + * mod.cservice/cservice.cc: + * mod.cservice/cservice.h: Fetch Db time prior to loading cache + (which depends on the server time (currentTime())). + * mod.ccontrol/LIMITSCommand.cc: + * mod.ccontrol/MODUSERCommand.cc: + * mod.ccontrol/NOMODECommand.cc: + * mod.ccontrol/REMCOMMANDCommand.cc: + * mod.ccontrol/REMGCHANCommand.cc: + * mod.ccontrol/REMSERVERCommand.cc: + * mod.ccontrol/REMUSERCommand.cc: + * mod.ccontrol/SGLINECommand.cc: + * mod.ccontrol/SUSPENDCommand.cc: + * mod.ccontrol/UNSUSPENDCommand.cc: + * mod.ccontrol/ccBadChannel.cc: + * mod.ccontrol/ccException.cc: + * mod.ccontrol/ccGline.cc: + * mod.ccontrol/ccServer.cc: + * mod.ccontrol/ccUser.cc: + * mod.ccontrol/ccontrol.cc: + * mod.ccontrol/ccontrol.h: + * mod.openchanfix/chanfix.cc: + * mod.openchanfix/chanfix.h: Implemented use of escapeSQLChars(). + * configure: + * configure.ac: Locate liboath in additional include-folder. + * mod.dronescan/dronescan.cc: + * mod.dronescan/sqlFakeClient.cc: + * mod.dronescan/sqlUser.cc: Implemented use of escapeSQLChars() + in mod.dronescan. + +2024-08-14 MrIron + * Makefile.in: + * configure: + * configure.ac: Bumped up to C++-20. Configure checks for liboath + when mod.cservice is built, since TOTP is enabled per default. + * libgnuworld/misc.cc: + * libgnuworld/misc.h: Added to libgnuworld methods for formatting + strings (vformat), calculating elapsed milliseconds and + displaying time. + * m4/ax_cxx_compile_stdcxx.m4: + * m4/ax_cxx_compile_stdcxx_11.m4: Updated C++ standard check macros. + * mod.cservice/cservice.cc: + * mod.cservice/cservice_config.h: + * mod.dronescan/ACCESSCommand.cc: Fixed warnings. + +2024-08-11 MrIron + * include/gnuworld_config.h: Define maximum channel key length. + * mod.cservice/MODECommand.cc: + * mod.cservice/responses.h: + * doc/update_help_modes_20240525.sql: Check for length of channel + key and added translation responses. + +2024-08-10 MrIron + * mod.snoop/snoop.cc: Small fix to mod.snoop after changes to core. + +2024-08-05 MrIron + * doc/cservice.sql: Updated channels schema to include JOINLIM + columns. + +2024-08-04 MrIron + * include/events.h: Added EVT_BURST event. + * libircu/msg_B.cc: + * src/server.cc: gnuworld will use the correct of EVT_JOIN, + EVT_CREATE and EVT_BURST when joining channels. Separate event + handler for channel joins during a net merge. + * mod.ccontrol/ccontrol.cc: + * mod.cservice/cservice.cc: + * mod.dronescan/dronescan.cc: + * mod.gnutest/gnutest.cc: + * mod.nickserv/nickserv.cc: + * mod.openchanfix/chanfix.cc: Updated modules to handle EVT_BURST. + +2024-08-03 MrIron + * bin/cservice.example.conf: + * doc/update.channels_joinlim_202408.sql: + * doc/update_help_modes_20240525.sql: + * include/Channel.h: + * libircu/msg_B.cc: + * libircu/msg_M.cc: + * mod.cservice/MODECommand.cc: + * mod.cservice/SETCommand.cc: + * mod.cservice/STATUSCommand.cc: + * mod.cservice/constants.h: + * mod.cservice/cservice.cc: + * mod.cservice/cservice.h: + * mod.cservice/levels.h: + * mod.cservice/responses.h: + * mod.cservice/sqlChannel.cc: + * mod.cservice/sqlChannel.h: + * src/Channel.cc: + * src/Network.cc: + * src/client.cc: + * src/iClient.cc: + * src/server.cc: JOINLIM feature to mod.cservice written by Telac. + Updated translations to BAN and UNBAN responses. Additional + initialisation warning fixes. Changed chanmode +P to +u as per + ircu (userLeavesDisabled). + +2024-08-01 MrIron + * bin/cloner.example.conf: + * mod.cloner/cloner.cc: + * mod.cloner/cloner.h: + * src/server.cc: Enhancements to mod.cloner. Minor fix to bursting + of clones. + * mod.ccontrol/ccUser.cc: + * mod.ccontrol/ccontrol.cc: + * mod.cservice/cservice.cc: Handle warnings regarding uninitialised + values. + +2024-07-28 MrIron + * include/client.h: + * src/client.cc: Handle bans and unbans by vectors in client.cc to + minimise duplication. + * libgnuworld/misc.cc: + * libgnuworld/misc.h: Added formatting of numbers. + * mod.cservice/BANCommand.cc: + * mod.cservice/UNBANCommand.cc: + * mod.cservice/cservice.cc: + * doc/update_help_modes_20240525.sql: Updated response in UNBAN + command to include internal and channel bans. + +2024-07-27 MrIron + * mod.cservice/BANCommand.cc: + * mod.cservice/cservice.cc: Stacking of expired bans. + +2024-07-24 MrIron + * include/iClient.h: + * src/iClient.cc: + * mod.ccontrol/WHOISCommand.cc: Recording the first NickTS for all + clients. + +2024-07-20 MrIron + * include/server.h: + * src/server.cc: Server notice function. + * include/Network.h: + * include/client.h: + * include/gnuworld_config.h: + * include/iClient.h: + * libircu/msg_N.cc: + * mod.ccontrol/WHOISCommand.cc: + * mod.ccontrol/ccontrol.cc: + * src/Network.cc: + * src/client.cc: + * src/iClient.cc: + * src/server.cc: Fixed syntax for msg_D (kill). Aligned gnuworld's + iClient timestamp with ircu (nickname timestamp). + +2024-07-05 MrIron + * README-NEW-Features.txt: + * doc/update_help_modes_20240525.sql: + * db/pgsqlDB.cc: Fix that caused gnuworld to core if losing + connection with the Db. + * include/Channel.h: + * include/gnuworld_config.h: + * libircu/msg_B.cc: + * libircu/msg_M.cc: + * src/Channel.cc: + * src/Network.cc: + * src/client.cc: + * src/server.cc: Support for chanmodes +M, +P. Parsing of userID + for LoC's (Levels on Channels). + * mod.cservice/Makefile.am: + * mod.cservice/BANCommand.cc: + * mod.cservice/KICKCommand.cc: + * mod.cservice/MODECommand.cc (new file): + * mod.cservice/PURGECommand.cc: + * mod.cservice/SHOWCOMMANDSCommand.cc: + * mod.cservice/STATSCommand.cc: + * mod.cservice/STATUSCommand.cc: + * mod.cservice/UNBANCommand.cc: + * mod.cservice/cservice.cc: + * mod.cservice/cservice.h: + * mod.cservice/cserviceCommands.h: + * mod.cservice/cservice_config.h: + * mod.cservice/levels.h: New MODE command for mod.cservice. Support + for several kicks in mod.cservice's KICK command. Stacking of + bans and unbans in mod.cservice's BAN and UNBAN command. + Properly remove purged channels from cache. + 2010-04-10 Dan-m00 * mod.cservice/ADDUSERCommand.cc: * mod.cservice/MODINFOCommand.cc: diff --git a/Makefile.am b/Makefile.am index f95c8f26..1895c1fc 100644 --- a/Makefile.am +++ b/Makefile.am @@ -128,6 +128,7 @@ EXTRA_DIST = bin/ccontrol.example.conf \ include db/Makefile.am include libgnuworld/Makefile.am +include libnotifier/Makefile.am include libircu/Makefile.am include src/Makefile.am diff --git a/Makefile.in b/Makefile.in index a279d303..ccc09957 100644 --- a/Makefile.in +++ b/Makefile.in @@ -112,10 +112,13 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -@COND_PROMETHEUS_TRUE@am__append_1 = libgnuworld/prometheus.cc +@COND_PROMETHEUS_TRUE@am__append_1 = libnotifier/prometheus.cc +@COND_LIBCURL_TRUE@@COND_PROMETHEUS_TRUE@am__append_2 = -lcurl -lprometheus-cpp-core -lprometheus-cpp-pull +@COND_LIBCURL_TRUE@@COND_PROMETHEUS_FALSE@am__append_3 = -lcurl +@COND_LIBCURL_FALSE@@COND_PROMETHEUS_TRUE@am__append_4 = -lprometheus-cpp-core -lprometheus-cpp-pull bin_PROGRAMS = gnuworld$(EXEEXT) -@COND_MODCCONTROL_TRUE@am__append_2 = libccontrol.la -@COND_MODCCONTROL_TRUE@am__append_3 = \ +@COND_MODCCONTROL_TRUE@am__append_5 = libccontrol.la +@COND_MODCCONTROL_TRUE@am__append_6 = \ @COND_MODCCONTROL_TRUE@ mod.ccontrol/ccBadChannel.h \ @COND_MODCCONTROL_TRUE@ mod.ccontrol/ccException.h \ @COND_MODCCONTROL_TRUE@ mod.ccontrol/ccFloodData.h \ @@ -132,20 +135,20 @@ bin_PROGRAMS = gnuworld$(EXEEXT) @COND_MODCCONTROL_TRUE@ mod.ccontrol/Constants.h \ @COND_MODCCONTROL_TRUE@ mod.ccontrol/README -@COND_MODCHANFIX_TRUE@am__append_4 = libchanfix.la -@COND_MODCHANFIX_TRUE@am__append_5 = \ +@COND_MODCHANFIX_TRUE@am__append_7 = libchanfix.la +@COND_MODCHANFIX_TRUE@am__append_8 = \ @COND_MODCHANFIX_TRUE@ mod.chanfix/chanfix.h \ @COND_MODCHANFIX_TRUE@ mod.chanfix/cfChannel.h \ @COND_MODCHANFIX_TRUE@ mod.chanfix/cfChannelUser.h \ @COND_MODCHANFIX_TRUE@ mod.chanfix/chanfix-commands.h \ @COND_MODCHANFIX_TRUE@ mod.chanfix/logging.h -@COND_MODCLIENTEXAMPLE_TRUE@am__append_6 = libclientExample.la -@COND_MODCLIENTEXAMPLE_TRUE@am__append_7 = mod.clientExample/clientExample.h -@COND_MODCLONER_TRUE@am__append_8 = libcloner.la -@COND_MODCLONER_TRUE@am__append_9 = mod.cloner/cloner.h -@COND_MODCSERVICE_TRUE@am__append_10 = libcservice.la -@COND_MODCSERVICE_TRUE@am__append_11 = \ +@COND_MODCLIENTEXAMPLE_TRUE@am__append_9 = libclientExample.la +@COND_MODCLIENTEXAMPLE_TRUE@am__append_10 = mod.clientExample/clientExample.h +@COND_MODCLONER_TRUE@am__append_11 = libcloner.la +@COND_MODCLONER_TRUE@am__append_12 = mod.cloner/cloner.h +@COND_MODCSERVICE_TRUE@am__append_13 = libcservice.la +@COND_MODCSERVICE_TRUE@am__append_14 = \ @COND_MODCSERVICE_TRUE@ mod.cservice/banMatcher.h \ @COND_MODCSERVICE_TRUE@ mod.cservice/constants.h \ @COND_MODCSERVICE_TRUE@ mod.cservice/cserviceCommands.h \ @@ -164,8 +167,8 @@ bin_PROGRAMS = gnuworld$(EXEEXT) @COND_MODCSERVICE_TRUE@ mod.cservice/README \ @COND_MODCSERVICE_TRUE@ mod.cservice/RELEASE.NOTES -@COND_MODDRONESCAN_TRUE@am__append_12 = libdronescan.la -@COND_MODDRONESCAN_TRUE@am__append_13 = \ +@COND_MODDRONESCAN_TRUE@am__append_15 = libdronescan.la +@COND_MODDRONESCAN_TRUE@am__append_16 = \ @COND_MODDRONESCAN_TRUE@ mod.dronescan/activeChannel.h \ @COND_MODDRONESCAN_TRUE@ mod.dronescan/clientData.h \ @COND_MODDRONESCAN_TRUE@ mod.dronescan/constants.h \ @@ -179,10 +182,10 @@ bin_PROGRAMS = gnuworld$(EXEEXT) @COND_MODDRONESCAN_TRUE@ mod.dronescan/ChangeLog \ @COND_MODDRONESCAN_TRUE@ mod.dronescan/README -@COND_MODGNUTEST_TRUE@am__append_14 = libgnutest.la -@COND_MODGNUTEST_TRUE@am__append_15 = mod.gnutest/gnutest.h -@COND_MODNICKSERV_TRUE@am__append_16 = libnickserv.la -@COND_MODNICKSERV_TRUE@am__append_17 = \ +@COND_MODGNUTEST_TRUE@am__append_17 = libgnutest.la +@COND_MODGNUTEST_TRUE@am__append_18 = mod.gnutest/gnutest.h +@COND_MODNICKSERV_TRUE@am__append_19 = libnickserv.la +@COND_MODNICKSERV_TRUE@am__append_20 = \ @COND_MODNICKSERV_TRUE@ mod.nickserv/levels.h \ @COND_MODNICKSERV_TRUE@ mod.nickserv/Logger.h \ @COND_MODNICKSERV_TRUE@ mod.nickserv/logTarget.h \ @@ -197,8 +200,8 @@ bin_PROGRAMS = gnuworld$(EXEEXT) @COND_MODNICKSERV_TRUE@ mod.nickserv/Updates \ @COND_MODNICKSERV_TRUE@ mod.nickserv/README -@COND_MODOPENCHANFIX_TRUE@am__append_18 = libchanfix.la -@COND_MODOPENCHANFIX_TRUE@am__append_19 = \ +@COND_MODOPENCHANFIX_TRUE@am__append_21 = libchanfix.la +@COND_MODOPENCHANFIX_TRUE@am__append_22 = \ @COND_MODOPENCHANFIX_TRUE@ mod.openchanfix/chanfix.h \ @COND_MODOPENCHANFIX_TRUE@ mod.openchanfix/chanfixCommands.h \ @COND_MODOPENCHANFIX_TRUE@ mod.openchanfix/chanfix_config.h \ @@ -209,16 +212,16 @@ bin_PROGRAMS = gnuworld$(EXEEXT) @COND_MODOPENCHANFIX_TRUE@ mod.openchanfix/sqlManager.h \ @COND_MODOPENCHANFIX_TRUE@ mod.openchanfix/sqlcfUser.h -@COND_MODSCANNER_TRUE@am__append_20 = libscanner.la -@COND_MODSCANNER_TRUE@am__append_21 = \ +@COND_MODSCANNER_TRUE@am__append_23 = libscanner.la +@COND_MODSCANNER_TRUE@am__append_24 = \ @COND_MODSCANNER_TRUE@ mod.scanner/dbThread.h \ @COND_MODSCANNER_TRUE@ mod.scanner/scanner.h \ @COND_MODSCANNER_TRUE@ mod.scanner/ScannerModule.h -@COND_MODSTATS_TRUE@am__append_22 = libstats.la -@COND_MODSTATS_TRUE@am__append_23 = mod.stats/stats.h -@COND_MODSNOOP_TRUE@am__append_24 = libsnoop.la -@COND_MODSNOOP_TRUE@am__append_25 = mod.snoop/snoop.h +@COND_MODSTATS_TRUE@am__append_25 = libstats.la +@COND_MODSTATS_TRUE@am__append_26 = mod.stats/stats.h +@COND_MODSNOOP_TRUE@am__append_27 = libsnoop.la +@COND_MODSNOOP_TRUE@am__append_28 = mod.snoop/snoop.h @COND_TESTDIR_TRUE@noinst_PROGRAMS = test_burst$(EXEEXT) \ @COND_TESTDIR_TRUE@ test_mtrie_load$(EXEEXT) \ @COND_TESTDIR_TRUE@ test_mtrie_perf_summary$(EXEEXT) \ @@ -230,8 +233,8 @@ bin_PROGRAMS = gnuworld$(EXEEXT) @COND_TESTDIR_TRUE@ test_bot$(EXEEXT) \ @COND_TESTDIR_TRUE@ test_kick_transaction$(EXEEXT) \ @COND_TESTDIR_TRUE@ $(am__EXEEXT_1) -@COND_PCRE_TRUE@@COND_TESTDIR_TRUE@am__append_26 = test_regex -@COND_TESTDIR_TRUE@am__append_27 = \ +@COND_PCRE_TRUE@@COND_TESTDIR_TRUE@am__append_29 = test_regex +@COND_TESTDIR_TRUE@am__append_30 = \ @COND_TESTDIR_TRUE@ test/testbot.h \ @COND_TESTDIR_TRUE@ test/README.burst \ @COND_TESTDIR_TRUE@ test/README.econfig \ @@ -726,17 +729,7 @@ libgnutest_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ $(libgnutest_la_CXXFLAGS) $(CXXFLAGS) $(libgnutest_la_LDFLAGS) \ $(LDFLAGS) -o $@ @COND_MODGNUTEST_TRUE@am_libgnutest_la_rpath = -rpath $(libdir) -libgnuworld_la_DEPENDENCIES = -am__libgnuworld_la_SOURCES_DIST = libgnuworld/Buffer.cc \ - libgnuworld/Connection.cc libgnuworld/ConnectionHandler.cc \ - libgnuworld/ConnectionManager.cc libgnuworld/EConfig.cc \ - libgnuworld/ELog.cc libgnuworld/Signal.cc \ - libgnuworld/StringTokenizer.cc libgnuworld/gThread.cc \ - libgnuworld/match.cc libgnuworld/md5hash.cc \ - libgnuworld/logger.cc libgnuworld/threadworker.cc \ - libgnuworld/pushover.cc libgnuworld/misc.cc \ - libgnuworld/prometheus.cc -@COND_PROMETHEUS_TRUE@am__objects_1 = libgnuworld/la-prometheus.lo +libgnuworld_la_LIBADD = am_libgnuworld_la_OBJECTS = libgnuworld/la-Buffer.lo \ libgnuworld/la-Connection.lo \ libgnuworld/la-ConnectionHandler.lo \ @@ -744,9 +737,7 @@ am_libgnuworld_la_OBJECTS = libgnuworld/la-Buffer.lo \ libgnuworld/la-ELog.lo libgnuworld/la-Signal.lo \ libgnuworld/la-StringTokenizer.lo libgnuworld/la-gThread.lo \ libgnuworld/la-match.lo libgnuworld/la-md5hash.lo \ - libgnuworld/la-logger.lo libgnuworld/la-threadworker.lo \ - libgnuworld/la-pushover.lo libgnuworld/la-misc.lo \ - $(am__objects_1) + libgnuworld/la-threadworker.lo libgnuworld/la-misc.lo libgnuworld_la_OBJECTS = $(am_libgnuworld_la_OBJECTS) libgnuworld_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CXXLD) \ @@ -761,7 +752,8 @@ libgnuworldDB_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ $(libgnuworldDB_la_CXXFLAGS) $(CXXFLAGS) \ $(libgnuworldDB_la_LDFLAGS) $(LDFLAGS) -o $@ am__DEPENDENCIES_1 = -libgnuworldcore_la_DEPENDENCIES = libgnuworld.la $(am__DEPENDENCIES_1) +libgnuworldcore_la_DEPENDENCIES = libgnuworld.la libnotifier.la \ + $(am__DEPENDENCIES_1) am_libgnuworldcore_la_OBJECTS = src/libgnuworldcore_la-Channel.lo \ src/libgnuworldcore_la-ChannelUser.lo \ src/libgnuworldcore_la-LoadClientTimerHandler.lo \ @@ -832,6 +824,18 @@ libnickserv_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ $(libnickserv_la_CXXFLAGS) $(CXXFLAGS) \ $(libnickserv_la_LDFLAGS) $(LDFLAGS) -o $@ @COND_MODNICKSERV_TRUE@am_libnickserv_la_rpath = -rpath $(libdir) +libnotifier_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +am__libnotifier_la_SOURCES_DIST = libnotifier/logger.cc \ + libnotifier/pushover.cc libnotifier/prometheus.cc +@COND_PROMETHEUS_TRUE@am__objects_1 = libnotifier/la-prometheus.lo +am_libnotifier_la_OBJECTS = libnotifier/la-logger.lo \ + libnotifier/la-pushover.lo $(am__objects_1) +libnotifier_la_OBJECTS = $(am_libnotifier_la_OBJECTS) +libnotifier_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CXXLD) \ + $(libnotifier_la_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) \ + $(LDFLAGS) -o $@ libscanner_la_LIBADD = am__libscanner_la_SOURCES_DIST = mod.scanner/ScannerModule.cc \ mod.scanner/dbThread.cc mod.scanner/scanner.cc \ @@ -1001,12 +1005,9 @@ am__depfiles_remade = db/$(DEPDIR)/libgnuworldDB_la-gnuworldDB.Plo \ libgnuworld/$(DEPDIR)/la-Signal.Plo \ libgnuworld/$(DEPDIR)/la-StringTokenizer.Plo \ libgnuworld/$(DEPDIR)/la-gThread.Plo \ - libgnuworld/$(DEPDIR)/la-logger.Plo \ libgnuworld/$(DEPDIR)/la-match.Plo \ libgnuworld/$(DEPDIR)/la-md5hash.Plo \ libgnuworld/$(DEPDIR)/la-misc.Plo \ - libgnuworld/$(DEPDIR)/la-prometheus.Plo \ - libgnuworld/$(DEPDIR)/la-pushover.Plo \ libgnuworld/$(DEPDIR)/la-threadworker.Plo \ libircu/$(DEPDIR)/la-msg_AC.Plo \ libircu/$(DEPDIR)/la-msg_AD.Plo libircu/$(DEPDIR)/la-msg_B.Plo \ @@ -1032,6 +1033,9 @@ am__depfiles_remade = db/$(DEPDIR)/libgnuworldDB_la-gnuworldDB.Plo \ libircu/$(DEPDIR)/la-msg_W.Plo libircu/$(DEPDIR)/la-msg_WA.Plo \ libircu/$(DEPDIR)/la-msg_XQ.Plo \ libircu/$(DEPDIR)/la-msg_XR.Plo libircu/$(DEPDIR)/la-msg_Y.Plo \ + libnotifier/$(DEPDIR)/la-logger.Plo \ + libnotifier/$(DEPDIR)/la-prometheus.Plo \ + libnotifier/$(DEPDIR)/la-pushover.Plo \ mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDCOMMANDCommand.Plo \ mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDOPERCHANCommand.Plo \ mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDSERVERCommand.Plo \ @@ -1326,24 +1330,25 @@ SOURCES = $(libccontrol_la_SOURCES) $(libchanfix_la_SOURCES) \ $(libgnutest_la_SOURCES) $(libgnuworld_la_SOURCES) \ $(libgnuworldDB_la_SOURCES) $(libgnuworldcore_la_SOURCES) \ $(libircu_la_SOURCES) $(libnickserv_la_SOURCES) \ - $(libscanner_la_SOURCES) $(libsnoop_la_SOURCES) \ - $(libstats_la_SOURCES) $(gnuworld_SOURCES) $(test_bot_SOURCES) \ - $(test_burst_SOURCES) $(test_econfig_SOURCES) \ - $(test_gThread_SOURCES) $(test_kick_transaction_SOURCES) \ - $(test_match_SOURCES) $(test_mtrie_SOURCES) \ - $(test_mtrie_load_SOURCES) $(test_mtrie_perf_SOURCES) \ - $(test_mtrie_perf_summary_SOURCES) $(test_regex_SOURCES) \ - $(test_signal_SOURCES) $(test_stringtokenizer_SOURCES) + $(libnotifier_la_SOURCES) $(libscanner_la_SOURCES) \ + $(libsnoop_la_SOURCES) $(libstats_la_SOURCES) \ + $(gnuworld_SOURCES) $(test_bot_SOURCES) $(test_burst_SOURCES) \ + $(test_econfig_SOURCES) $(test_gThread_SOURCES) \ + $(test_kick_transaction_SOURCES) $(test_match_SOURCES) \ + $(test_mtrie_SOURCES) $(test_mtrie_load_SOURCES) \ + $(test_mtrie_perf_SOURCES) $(test_mtrie_perf_summary_SOURCES) \ + $(test_regex_SOURCES) $(test_signal_SOURCES) \ + $(test_stringtokenizer_SOURCES) DIST_SOURCES = $(am__libccontrol_la_SOURCES_DIST) \ $(am__libchanfix_la_SOURCES_DIST) \ $(am__libclientExample_la_SOURCES_DIST) \ $(am__libcloner_la_SOURCES_DIST) \ $(am__libcservice_la_SOURCES_DIST) \ $(am__libdronescan_la_SOURCES_DIST) \ - $(am__libgnutest_la_SOURCES_DIST) \ - $(am__libgnuworld_la_SOURCES_DIST) $(libgnuworldDB_la_SOURCES) \ - $(libgnuworldcore_la_SOURCES) $(libircu_la_SOURCES) \ - $(am__libnickserv_la_SOURCES_DIST) \ + $(am__libgnutest_la_SOURCES_DIST) $(libgnuworld_la_SOURCES) \ + $(libgnuworldDB_la_SOURCES) $(libgnuworldcore_la_SOURCES) \ + $(libircu_la_SOURCES) $(am__libnickserv_la_SOURCES_DIST) \ + $(am__libnotifier_la_SOURCES_DIST) \ $(am__libscanner_la_SOURCES_DIST) \ $(am__libsnoop_la_SOURCES_DIST) \ $(am__libstats_la_SOURCES_DIST) $(gnuworld_SOURCES) \ @@ -1400,6 +1405,7 @@ DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/db/Makefile.am \ $(srcdir)/libgnuworld/Makefile.am \ $(srcdir)/libircu/Makefile.am \ + $(srcdir)/libnotifier/Makefile.am \ $(srcdir)/mod.ccontrol/Makefile.am \ $(srcdir)/mod.chanfix/Makefile.am \ $(srcdir)/mod.clientExample/Makefile.am \ @@ -1626,11 +1632,11 @@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ SUBDIRS = libltdl $(NEW_MODS) lib_LTLIBRARIES = libgnuworldDB.la libircu.la libgnuworldcore.la \ - $(am__append_2) $(am__append_4) $(am__append_6) \ - $(am__append_8) $(am__append_10) $(am__append_12) \ - $(am__append_14) $(am__append_16) $(am__append_18) \ - $(am__append_20) $(am__append_22) $(am__append_24) -noinst_LTLIBRARIES = libgnuworld.la + $(am__append_5) $(am__append_7) $(am__append_9) \ + $(am__append_11) $(am__append_13) $(am__append_15) \ + $(am__append_17) $(am__append_19) $(am__append_21) \ + $(am__append_23) $(am__append_25) $(am__append_27) +noinst_LTLIBRARIES = libgnuworld.la libnotifier.la pkgdata_DATA = bin/server_command_map EXTRA_DIST = bin/ccontrol.example.conf bin/chanfix.example.conf \ bin/clientExample.example.conf bin/cloner.example.conf \ @@ -1691,41 +1697,55 @@ EXTRA_DIST = bin/ccontrol.example.conf bin/chanfix.example.conf \ libgnuworld/ELog.h libgnuworld/gThread.h \ libgnuworld/ircd_chattr.h libgnuworld/match.h \ libgnuworld/match_table.h libgnuworld/md5hash.h \ - libgnuworld/logger.h libgnuworld/threadworker.h \ - libgnuworld/notifier.h libgnuworld/prometheus.h \ - libgnuworld/pushover.h libgnuworld/misc.h libgnuworld/MTrie.h \ - libgnuworld/MTrie.cc libgnuworld/Signal.h \ + libgnuworld/threadworker.h libgnuworld/misc.h \ + libgnuworld/MTrie.h libgnuworld/MTrie.cc libgnuworld/Signal.h \ libgnuworld/StringTokenizer.h libgnuworld/xparameters.h \ - $(am__append_3) $(am__append_5) $(am__append_7) \ - $(am__append_9) $(am__append_11) $(am__append_13) \ - $(am__append_15) $(am__append_17) $(am__append_19) \ - $(am__append_21) $(am__append_23) $(am__append_25) \ - $(am__append_27) + libgnuworld/logger.h libgnuworld/notifier.h \ + libgnuworld/prometheus.h libgnuworld/pushover.h \ + $(am__append_6) $(am__append_8) $(am__append_10) \ + $(am__append_12) $(am__append_14) $(am__append_16) \ + $(am__append_18) $(am__append_20) $(am__append_22) \ + $(am__append_24) $(am__append_26) $(am__append_28) \ + $(am__append_30) libgnuworldDB_la_SOURCES = \ db/gnuworldDB.cc \ db/pgsqlDB.cc libgnuworldDB_la_CXXFLAGS = \ -I$(top_srcdir)/libgnuworld \ + -I$(top_srcdir)/libnotifier \ -I$(top_srcdir)/include libgnuworldDB_la_LDFLAGS = -L$(pgsql_libdir) -lpq -libgnuworld_la_SOURCES = libgnuworld/Buffer.cc \ - libgnuworld/Connection.cc libgnuworld/ConnectionHandler.cc \ - libgnuworld/ConnectionManager.cc libgnuworld/EConfig.cc \ - libgnuworld/ELog.cc libgnuworld/Signal.cc \ - libgnuworld/StringTokenizer.cc libgnuworld/gThread.cc \ - libgnuworld/match.cc libgnuworld/md5hash.cc \ - libgnuworld/logger.cc libgnuworld/threadworker.cc \ - libgnuworld/pushover.cc libgnuworld/misc.cc $(am__append_1) +libgnuworld_la_SOURCES = \ + libgnuworld/Buffer.cc \ + libgnuworld/Connection.cc \ + libgnuworld/ConnectionHandler.cc \ + libgnuworld/ConnectionManager.cc \ + libgnuworld/EConfig.cc \ + libgnuworld/ELog.cc \ + libgnuworld/Signal.cc \ + libgnuworld/StringTokenizer.cc \ + libgnuworld/gThread.cc \ + libgnuworld/match.cc \ + libgnuworld/md5hash.cc \ + libgnuworld/threadworker.cc \ + libgnuworld/misc.cc + libgnuworld_la_LDFLAGS = $(threadLib) -@COND_LIBCURL_FALSE@@COND_PROMETHEUS_TRUE@libgnuworld_la_LIBADD = -lprometheus-cpp-core -lprometheus-cpp-pull -@COND_LIBCURL_TRUE@@COND_PROMETHEUS_FALSE@libgnuworld_la_LIBADD = -lcurl -@COND_LIBCURL_TRUE@@COND_PROMETHEUS_TRUE@libgnuworld_la_LIBADD = -lcurl -lprometheus-cpp-core -lprometheus-cpp-pull libgnuworld_la_CXXFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/libgnuworld +libnotifier_la_SOURCES = libnotifier/logger.cc libnotifier/pushover.cc \ + $(am__append_1) +libnotifier_la_CXXFLAGS = \ + -I$(top_srcdir)/include \ + -I$(top_srcdir)/libgnuworld \ + -I$(top_srcdir)/libnotifier + +libnotifier_la_LIBADD = $(am__append_2) $(am__append_3) \ + $(am__append_4) libircu_la_SOURCES = \ libircu/msg_AC.cc \ libircu/msg_AD.cc \ @@ -1766,7 +1786,7 @@ libircu_la_SOURCES = \ libircu/msg_XR.cc \ libircu/msg_Y.cc -libircu_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +libircu_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld -I${top_srcdir}/libnotifier libircu_la_LDFLAGS = -module -export-dynamic libgnuworldcore_la_SOURCES = \ src/Channel.cc \ @@ -1786,10 +1806,11 @@ libgnuworldcore_la_SOURCES = \ src/server_timers.cc libgnuworldcore_la_CXXFLAGS = -I${top_srcdir}/include \ - -I${top_srcdir}/libgnuworld + -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libgnuworldcore_la_LDFLAGS = -export-dynamic -libgnuworldcore_la_LIBADD = libgnuworld.la $(LIBLTDL) +libgnuworldcore_la_LIBADD = libgnuworld.la libnotifier.la $(LIBLTDL) gnuworld_SOURCES = src/main.cc gnuworld_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld gnuworld_LDFLAGS = -export-dynamic $(threadLib) @@ -1867,16 +1888,19 @@ gnuworld_LDADD = libgnuworld.la libgnuworldcore.la $(LIBLTDL) @COND_MODCCONTROL_TRUE@ mod.ccontrol/LIMITSCommand.cc @COND_MODCCONTROL_TRUE@libccontrol_la_CXXFLAGS = -I$(top_srcdir)/db -I${top_srcdir}/include \ -@COND_MODCCONTROL_TRUE@ -I${top_srcdir}/libgnuworld +@COND_MODCCONTROL_TRUE@ -I${top_srcdir}/libgnuworld \ +@COND_MODCCONTROL_TRUE@ -I${top_srcdir}/libnotifier @COND_MODCCONTROL_TRUE@libccontrol_la_LDFLAGS = -module -export-dynamic @COND_MODCCONTROL_TRUE@libccontrol_la_LIBADD = libgnuworldDB.la @COND_MODCHANFIX_TRUE@libchanfix_la_CXXFLAGS = -I${top_srcdir}/include \ @COND_MODCHANFIX_TRUE@ -I${top_srcdir}/libgnuworld \ +@COND_MODCHANFIX_TRUE@ -I${top_srcdir}/libnotifier \ @COND_MODCHANFIX_TRUE@ -Werror @COND_MODOPENCHANFIX_TRUE@libchanfix_la_CXXFLAGS = -I$(top_srcdir)db -I${top_srcdir}/include \ @COND_MODOPENCHANFIX_TRUE@ -I${top_srcdir}/libgnuworld \ +@COND_MODOPENCHANFIX_TRUE@ -I${top_srcdir}/libnotifier \ @COND_MODOPENCHANFIX_TRUE@ $(threadLib) @COND_MODCHANFIX_TRUE@libchanfix_la_LDFLAGS = -module -export-dynamic @@ -1943,16 +1967,20 @@ gnuworld_LDADD = libgnuworld.la libgnuworldcore.la $(LIBLTDL) @COND_MODCLIENTEXAMPLE_TRUE@libclientExample_la_SOURCES = mod.clientExample/clientExample.cc @COND_MODCLIENTEXAMPLE_TRUE@libclientExample_la_CXXFLAGS = -I${top_srcdir}/include \ -@COND_MODCLIENTEXAMPLE_TRUE@ -I${top_srcdir}/libgnuworld +@COND_MODCLIENTEXAMPLE_TRUE@ -I${top_srcdir}/libgnuworld \ +@COND_MODCLIENTEXAMPLE_TRUE@ -I${top_srcdir}/libnotifier @COND_MODCLIENTEXAMPLE_TRUE@libclientExample_la_LDFLAGS = -module -export-dynamic @COND_MODCLONER_TRUE@libcloner_la_SOURCES = mod.cloner/cloner.cc -@COND_MODCLONER_TRUE@libcloner_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +@COND_MODCLONER_TRUE@libcloner_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld \ +@COND_MODCLONER_TRUE@ -I${top_srcdir}/libnotifier + @COND_MODCLONER_TRUE@libcloner_la_LDFLAGS = -module -export-dynamic @COND_MODCSERVICE_TRUE@libcservice_la_LDFLAGS = -module -export-dynamic @COND_MODCSERVICE_TRUE@libcservice_la_LIBADD = libgnuworldDB.la @COND_MODCSERVICE_TRUE@libcservice_la_CXXFLAGS = -I$(top_srcdir)/db -I${top_srcdir}/include \ -@COND_MODCSERVICE_TRUE@ -I${top_srcdir}/libgnuworld +@COND_MODCSERVICE_TRUE@ -I${top_srcdir}/libgnuworld \ +@COND_MODCSERVICE_TRUE@ -I${top_srcdir}/libnotifier @COND_MODCSERVICE_TRUE@libcservice_la_SOURCES = \ @COND_MODCSERVICE_TRUE@ mod.cservice/banMatcher.cc \ @@ -2027,6 +2055,7 @@ gnuworld_LDADD = libgnuworld.la libgnuworldcore.la $(LIBLTDL) @COND_MODDRONESCAN_TRUE@libdronescan_la_LIBADD = libgnuworldDB.la @COND_MODDRONESCAN_TRUE@libdronescan_la_CXXFLAGS = -I$(top_srcdir)/db \ @COND_MODDRONESCAN_TRUE@ -I${top_srcdir}/libgnuworld \ +@COND_MODDRONESCAN_TRUE@ -I${top_srcdir}/libnotifier \ @COND_MODDRONESCAN_TRUE@ -I${top_srcdir}/include @COND_MODDRONESCAN_TRUE@libdronescan_la_SOURCES = \ @@ -2056,7 +2085,9 @@ gnuworld_LDADD = libgnuworld.la libgnuworldcore.la $(LIBLTDL) @COND_MODDRONESCAN_TRUE@ mod.dronescan/jfChannel.cc @COND_MODGNUTEST_TRUE@libgnutest_la_SOURCES = mod.gnutest/gnutest.cc -@COND_MODGNUTEST_TRUE@libgnutest_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +@COND_MODGNUTEST_TRUE@libgnutest_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld \ +@COND_MODGNUTEST_TRUE@ -I${top_srcdir}/libnotifier + @COND_MODGNUTEST_TRUE@libgnutest_la_LDFLAGS = -module -export-dynamic @COND_MODNICKSERV_TRUE@libnickserv_la_LDFLAGS = -module -export-dynamic @COND_MODNICKSERV_TRUE@libnickserv_la_LIBADD = libgnuworldDB.la @@ -2079,7 +2110,8 @@ gnuworld_LDADD = libgnuworld.la libgnuworldcore.la $(LIBLTDL) @COND_MODNICKSERV_TRUE@ mod.nickserv/sqlUser.cc @COND_MODNICKSERV_TRUE@libnickserv_la_CXXFLAGS = -I$(top_srcdir)/db \ -@COND_MODNICKSERV_TRUE@ -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +@COND_MODNICKSERV_TRUE@ -I${top_srcdir}/include -I${top_srcdir}/libgnuworld \ +@COND_MODNICKSERV_TRUE@ -I${top_srcdir}/libnotifier @COND_MODOPENCHANFIX_TRUE@libchanfix_la_LIBADD = libgnuworldDB.la @COND_MODSCANNER_TRUE@libscanner_la_SOURCES = \ @@ -2090,14 +2122,18 @@ gnuworld_LDADD = libgnuworld.la libgnuworldcore.la $(LIBLTDL) @COND_MODSCANNER_TRUE@libscanner_la_LDFLAGS = -module -export-dynamic @COND_MODSCANNER_TRUE@libscanner_la_CXXFLAGS = -I$(top_srcdir)/include \ -@COND_MODSCANNER_TRUE@ -I$(top_srcdir)/libgnuworld +@COND_MODSCANNER_TRUE@ -I$(top_srcdir)/libgnuworld \ +@COND_MODSCANNER_TRUE@ -I$(top_srcdir)/libnotifier @COND_MODSTATS_TRUE@libstats_la_SOURCES = mod.stats/stats.cc -@COND_MODSTATS_TRUE@libstats_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +@COND_MODSTATS_TRUE@libstats_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld \ +@COND_MODSTATS_TRUE@ -I${top_srcdir}/libnotifier + @COND_MODSTATS_TRUE@libstats_la_LDFLAGS = -module -export-dynamic @COND_MODSNOOP_TRUE@libsnoop_la_SOURCES = mod.snoop/snoop.cc @COND_MODSNOOP_TRUE@libsnoop_la_CXXFLAGS = -I${top_srcdir}/include \ -@COND_MODSNOOP_TRUE@ -I${top_srcdir}/libgnuworld +@COND_MODSNOOP_TRUE@ -I${top_srcdir}/libgnuworld \ +@COND_MODSNOOP_TRUE@ -I${top_srcdir}/libnotifier @COND_MODSNOOP_TRUE@libsnoop_la_LDFLAGS = -module -export-dynamic @COND_TESTDIR_TRUE@test_burst_SOURCES = test/burst.cc @@ -2150,7 +2186,7 @@ all: all-recursive .SUFFIXES: .cc .lo .o .obj am--refresh: Makefile @: -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/db/Makefile.am $(srcdir)/libgnuworld/Makefile.am $(srcdir)/libircu/Makefile.am $(srcdir)/src/Makefile.am $(srcdir)/mod.ccontrol/Makefile.am $(srcdir)/mod.chanfix/Makefile.am $(srcdir)/mod.clientExample/Makefile.am $(srcdir)/mod.cloner/Makefile.am $(srcdir)/mod.cservice/Makefile.am $(srcdir)/mod.dronescan/Makefile.am $(srcdir)/mod.gnutest/Makefile.am $(srcdir)/mod.nickserv/Makefile.am $(srcdir)/mod.openchanfix/Makefile.am $(srcdir)/mod.scanner/Makefile.am $(srcdir)/mod.stats/Makefile.am $(srcdir)/mod.snoop/Makefile.am $(srcdir)/test/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/db/Makefile.am $(srcdir)/libgnuworld/Makefile.am $(srcdir)/libnotifier/Makefile.am $(srcdir)/libircu/Makefile.am $(srcdir)/src/Makefile.am $(srcdir)/mod.ccontrol/Makefile.am $(srcdir)/mod.chanfix/Makefile.am $(srcdir)/mod.clientExample/Makefile.am $(srcdir)/mod.cloner/Makefile.am $(srcdir)/mod.cservice/Makefile.am $(srcdir)/mod.dronescan/Makefile.am $(srcdir)/mod.gnutest/Makefile.am $(srcdir)/mod.nickserv/Makefile.am $(srcdir)/mod.openchanfix/Makefile.am $(srcdir)/mod.scanner/Makefile.am $(srcdir)/mod.stats/Makefile.am $(srcdir)/mod.snoop/Makefile.am $(srcdir)/test/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -2172,7 +2208,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \ esac; -$(srcdir)/db/Makefile.am $(srcdir)/libgnuworld/Makefile.am $(srcdir)/libircu/Makefile.am $(srcdir)/src/Makefile.am $(srcdir)/mod.ccontrol/Makefile.am $(srcdir)/mod.chanfix/Makefile.am $(srcdir)/mod.clientExample/Makefile.am $(srcdir)/mod.cloner/Makefile.am $(srcdir)/mod.cservice/Makefile.am $(srcdir)/mod.dronescan/Makefile.am $(srcdir)/mod.gnutest/Makefile.am $(srcdir)/mod.nickserv/Makefile.am $(srcdir)/mod.openchanfix/Makefile.am $(srcdir)/mod.scanner/Makefile.am $(srcdir)/mod.stats/Makefile.am $(srcdir)/mod.snoop/Makefile.am $(srcdir)/test/Makefile.am $(am__empty): +$(srcdir)/db/Makefile.am $(srcdir)/libgnuworld/Makefile.am $(srcdir)/libnotifier/Makefile.am $(srcdir)/libircu/Makefile.am $(srcdir)/src/Makefile.am $(srcdir)/mod.ccontrol/Makefile.am $(srcdir)/mod.chanfix/Makefile.am $(srcdir)/mod.clientExample/Makefile.am $(srcdir)/mod.cloner/Makefile.am $(srcdir)/mod.cservice/Makefile.am $(srcdir)/mod.dronescan/Makefile.am $(srcdir)/mod.gnutest/Makefile.am $(srcdir)/mod.nickserv/Makefile.am $(srcdir)/mod.openchanfix/Makefile.am $(srcdir)/mod.scanner/Makefile.am $(srcdir)/mod.stats/Makefile.am $(srcdir)/mod.snoop/Makefile.am $(srcdir)/test/Makefile.am $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck @@ -3031,16 +3067,10 @@ libgnuworld/la-match.lo: libgnuworld/$(am__dirstamp) \ libgnuworld/$(DEPDIR)/$(am__dirstamp) libgnuworld/la-md5hash.lo: libgnuworld/$(am__dirstamp) \ libgnuworld/$(DEPDIR)/$(am__dirstamp) -libgnuworld/la-logger.lo: libgnuworld/$(am__dirstamp) \ - libgnuworld/$(DEPDIR)/$(am__dirstamp) libgnuworld/la-threadworker.lo: libgnuworld/$(am__dirstamp) \ libgnuworld/$(DEPDIR)/$(am__dirstamp) -libgnuworld/la-pushover.lo: libgnuworld/$(am__dirstamp) \ - libgnuworld/$(DEPDIR)/$(am__dirstamp) libgnuworld/la-misc.lo: libgnuworld/$(am__dirstamp) \ libgnuworld/$(DEPDIR)/$(am__dirstamp) -libgnuworld/la-prometheus.lo: libgnuworld/$(am__dirstamp) \ - libgnuworld/$(DEPDIR)/$(am__dirstamp) libgnuworld.la: $(libgnuworld_la_OBJECTS) $(libgnuworld_la_DEPENDENCIES) $(EXTRA_libgnuworld_la_DEPENDENCIES) $(AM_V_CXXLD)$(libgnuworld_la_LINK) $(libgnuworld_la_OBJECTS) $(libgnuworld_la_LIBADD) $(LIBS) @@ -3233,6 +3263,21 @@ mod.nickserv/libnickserv_la-sqlUser.lo: mod.nickserv/$(am__dirstamp) \ libnickserv.la: $(libnickserv_la_OBJECTS) $(libnickserv_la_DEPENDENCIES) $(EXTRA_libnickserv_la_DEPENDENCIES) $(AM_V_CXXLD)$(libnickserv_la_LINK) $(am_libnickserv_la_rpath) $(libnickserv_la_OBJECTS) $(libnickserv_la_LIBADD) $(LIBS) +libnotifier/$(am__dirstamp): + @$(MKDIR_P) libnotifier + @: >>libnotifier/$(am__dirstamp) +libnotifier/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) libnotifier/$(DEPDIR) + @: >>libnotifier/$(DEPDIR)/$(am__dirstamp) +libnotifier/la-logger.lo: libnotifier/$(am__dirstamp) \ + libnotifier/$(DEPDIR)/$(am__dirstamp) +libnotifier/la-pushover.lo: libnotifier/$(am__dirstamp) \ + libnotifier/$(DEPDIR)/$(am__dirstamp) +libnotifier/la-prometheus.lo: libnotifier/$(am__dirstamp) \ + libnotifier/$(DEPDIR)/$(am__dirstamp) + +libnotifier.la: $(libnotifier_la_OBJECTS) $(libnotifier_la_DEPENDENCIES) $(EXTRA_libnotifier_la_DEPENDENCIES) + $(AM_V_CXXLD)$(libnotifier_la_LINK) $(libnotifier_la_OBJECTS) $(libnotifier_la_LIBADD) $(LIBS) mod.scanner/$(am__dirstamp): @$(MKDIR_P) mod.scanner @: >>mod.scanner/$(am__dirstamp) @@ -3373,6 +3418,8 @@ mostlyclean-compile: -rm -f libgnuworld/*.lo -rm -f libircu/*.$(OBJEXT) -rm -f libircu/*.lo + -rm -f libnotifier/*.$(OBJEXT) + -rm -f libnotifier/*.lo -rm -f mod.ccontrol/*.$(OBJEXT) -rm -f mod.ccontrol/*.lo -rm -f mod.chanfix/*.$(OBJEXT) @@ -3415,12 +3462,9 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-Signal.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-StringTokenizer.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-gThread.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-logger.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-match.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-md5hash.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-misc.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-prometheus.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-pushover.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libgnuworld/$(DEPDIR)/la-threadworker.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libircu/$(DEPDIR)/la-msg_AC.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libircu/$(DEPDIR)/la-msg_AD.Plo@am__quote@ # am--include-marker @@ -3460,6 +3504,9 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@libircu/$(DEPDIR)/la-msg_XQ.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libircu/$(DEPDIR)/la-msg_XR.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@libircu/$(DEPDIR)/la-msg_Y.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@libnotifier/$(DEPDIR)/la-logger.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@libnotifier/$(DEPDIR)/la-prometheus.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@libnotifier/$(DEPDIR)/la-pushover.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDCOMMANDCommand.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDOPERCHANCommand.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDSERVERCommand.Plo@am__quote@ # am--include-marker @@ -5379,13 +5426,6 @@ libgnuworld/la-md5hash.lo: libgnuworld/md5hash.cc @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -c -o libgnuworld/la-md5hash.lo `test -f 'libgnuworld/md5hash.cc' || echo '$(srcdir)/'`libgnuworld/md5hash.cc -libgnuworld/la-logger.lo: libgnuworld/logger.cc -@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -MT libgnuworld/la-logger.lo -MD -MP -MF libgnuworld/$(DEPDIR)/la-logger.Tpo -c -o libgnuworld/la-logger.lo `test -f 'libgnuworld/logger.cc' || echo '$(srcdir)/'`libgnuworld/logger.cc -@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) libgnuworld/$(DEPDIR)/la-logger.Tpo libgnuworld/$(DEPDIR)/la-logger.Plo -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='libgnuworld/logger.cc' object='libgnuworld/la-logger.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -c -o libgnuworld/la-logger.lo `test -f 'libgnuworld/logger.cc' || echo '$(srcdir)/'`libgnuworld/logger.cc - libgnuworld/la-threadworker.lo: libgnuworld/threadworker.cc @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -MT libgnuworld/la-threadworker.lo -MD -MP -MF libgnuworld/$(DEPDIR)/la-threadworker.Tpo -c -o libgnuworld/la-threadworker.lo `test -f 'libgnuworld/threadworker.cc' || echo '$(srcdir)/'`libgnuworld/threadworker.cc @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) libgnuworld/$(DEPDIR)/la-threadworker.Tpo libgnuworld/$(DEPDIR)/la-threadworker.Plo @@ -5393,13 +5433,6 @@ libgnuworld/la-threadworker.lo: libgnuworld/threadworker.cc @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -c -o libgnuworld/la-threadworker.lo `test -f 'libgnuworld/threadworker.cc' || echo '$(srcdir)/'`libgnuworld/threadworker.cc -libgnuworld/la-pushover.lo: libgnuworld/pushover.cc -@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -MT libgnuworld/la-pushover.lo -MD -MP -MF libgnuworld/$(DEPDIR)/la-pushover.Tpo -c -o libgnuworld/la-pushover.lo `test -f 'libgnuworld/pushover.cc' || echo '$(srcdir)/'`libgnuworld/pushover.cc -@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) libgnuworld/$(DEPDIR)/la-pushover.Tpo libgnuworld/$(DEPDIR)/la-pushover.Plo -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='libgnuworld/pushover.cc' object='libgnuworld/la-pushover.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -c -o libgnuworld/la-pushover.lo `test -f 'libgnuworld/pushover.cc' || echo '$(srcdir)/'`libgnuworld/pushover.cc - libgnuworld/la-misc.lo: libgnuworld/misc.cc @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -MT libgnuworld/la-misc.lo -MD -MP -MF libgnuworld/$(DEPDIR)/la-misc.Tpo -c -o libgnuworld/la-misc.lo `test -f 'libgnuworld/misc.cc' || echo '$(srcdir)/'`libgnuworld/misc.cc @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) libgnuworld/$(DEPDIR)/la-misc.Tpo libgnuworld/$(DEPDIR)/la-misc.Plo @@ -5407,13 +5440,6 @@ libgnuworld/la-misc.lo: libgnuworld/misc.cc @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -c -o libgnuworld/la-misc.lo `test -f 'libgnuworld/misc.cc' || echo '$(srcdir)/'`libgnuworld/misc.cc -libgnuworld/la-prometheus.lo: libgnuworld/prometheus.cc -@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -MT libgnuworld/la-prometheus.lo -MD -MP -MF libgnuworld/$(DEPDIR)/la-prometheus.Tpo -c -o libgnuworld/la-prometheus.lo `test -f 'libgnuworld/prometheus.cc' || echo '$(srcdir)/'`libgnuworld/prometheus.cc -@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) libgnuworld/$(DEPDIR)/la-prometheus.Tpo libgnuworld/$(DEPDIR)/la-prometheus.Plo -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='libgnuworld/prometheus.cc' object='libgnuworld/la-prometheus.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworld_la_CXXFLAGS) $(CXXFLAGS) -c -o libgnuworld/la-prometheus.lo `test -f 'libgnuworld/prometheus.cc' || echo '$(srcdir)/'`libgnuworld/prometheus.cc - db/libgnuworldDB_la-gnuworldDB.lo: db/gnuworldDB.cc @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgnuworldDB_la_CXXFLAGS) $(CXXFLAGS) -MT db/libgnuworldDB_la-gnuworldDB.lo -MD -MP -MF db/$(DEPDIR)/libgnuworldDB_la-gnuworldDB.Tpo -c -o db/libgnuworldDB_la-gnuworldDB.lo `test -f 'db/gnuworldDB.cc' || echo '$(srcdir)/'`db/gnuworldDB.cc @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) db/$(DEPDIR)/libgnuworldDB_la-gnuworldDB.Tpo db/$(DEPDIR)/libgnuworldDB_la-gnuworldDB.Plo @@ -5911,6 +5937,27 @@ mod.nickserv/libnickserv_la-sqlUser.lo: mod.nickserv/sqlUser.cc @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libnickserv_la_CXXFLAGS) $(CXXFLAGS) -c -o mod.nickserv/libnickserv_la-sqlUser.lo `test -f 'mod.nickserv/sqlUser.cc' || echo '$(srcdir)/'`mod.nickserv/sqlUser.cc +libnotifier/la-logger.lo: libnotifier/logger.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libnotifier_la_CXXFLAGS) $(CXXFLAGS) -MT libnotifier/la-logger.lo -MD -MP -MF libnotifier/$(DEPDIR)/la-logger.Tpo -c -o libnotifier/la-logger.lo `test -f 'libnotifier/logger.cc' || echo '$(srcdir)/'`libnotifier/logger.cc +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) libnotifier/$(DEPDIR)/la-logger.Tpo libnotifier/$(DEPDIR)/la-logger.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='libnotifier/logger.cc' object='libnotifier/la-logger.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libnotifier_la_CXXFLAGS) $(CXXFLAGS) -c -o libnotifier/la-logger.lo `test -f 'libnotifier/logger.cc' || echo '$(srcdir)/'`libnotifier/logger.cc + +libnotifier/la-pushover.lo: libnotifier/pushover.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libnotifier_la_CXXFLAGS) $(CXXFLAGS) -MT libnotifier/la-pushover.lo -MD -MP -MF libnotifier/$(DEPDIR)/la-pushover.Tpo -c -o libnotifier/la-pushover.lo `test -f 'libnotifier/pushover.cc' || echo '$(srcdir)/'`libnotifier/pushover.cc +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) libnotifier/$(DEPDIR)/la-pushover.Tpo libnotifier/$(DEPDIR)/la-pushover.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='libnotifier/pushover.cc' object='libnotifier/la-pushover.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libnotifier_la_CXXFLAGS) $(CXXFLAGS) -c -o libnotifier/la-pushover.lo `test -f 'libnotifier/pushover.cc' || echo '$(srcdir)/'`libnotifier/pushover.cc + +libnotifier/la-prometheus.lo: libnotifier/prometheus.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libnotifier_la_CXXFLAGS) $(CXXFLAGS) -MT libnotifier/la-prometheus.lo -MD -MP -MF libnotifier/$(DEPDIR)/la-prometheus.Tpo -c -o libnotifier/la-prometheus.lo `test -f 'libnotifier/prometheus.cc' || echo '$(srcdir)/'`libnotifier/prometheus.cc +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) libnotifier/$(DEPDIR)/la-prometheus.Tpo libnotifier/$(DEPDIR)/la-prometheus.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='libnotifier/prometheus.cc' object='libnotifier/la-prometheus.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libnotifier_la_CXXFLAGS) $(CXXFLAGS) -c -o libnotifier/la-prometheus.lo `test -f 'libnotifier/prometheus.cc' || echo '$(srcdir)/'`libnotifier/prometheus.cc + mod.scanner/libscanner_la-ScannerModule.lo: mod.scanner/ScannerModule.cc @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libscanner_la_CXXFLAGS) $(CXXFLAGS) -MT mod.scanner/libscanner_la-ScannerModule.lo -MD -MP -MF mod.scanner/$(DEPDIR)/libscanner_la-ScannerModule.Tpo -c -o mod.scanner/libscanner_la-ScannerModule.lo `test -f 'mod.scanner/ScannerModule.cc' || echo '$(srcdir)/'`mod.scanner/ScannerModule.cc @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) mod.scanner/$(DEPDIR)/libscanner_la-ScannerModule.Tpo mod.scanner/$(DEPDIR)/libscanner_la-ScannerModule.Plo @@ -6143,6 +6190,7 @@ clean-libtool: -rm -rf db/.libs db/_libs -rm -rf libgnuworld/.libs libgnuworld/_libs -rm -rf libircu/.libs libircu/_libs + -rm -rf libnotifier/.libs libnotifier/_libs -rm -rf mod.ccontrol/.libs mod.ccontrol/_libs -rm -rf mod.chanfix/.libs mod.chanfix/_libs -rm -rf mod.clientExample/.libs mod.clientExample/_libs @@ -6525,6 +6573,8 @@ distclean-generic: -$(am__rm_f) libgnuworld/$(am__dirstamp) -$(am__rm_f) libircu/$(DEPDIR)/$(am__dirstamp) -$(am__rm_f) libircu/$(am__dirstamp) + -$(am__rm_f) libnotifier/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) libnotifier/$(am__dirstamp) -$(am__rm_f) mod.ccontrol/$(DEPDIR)/$(am__dirstamp) -$(am__rm_f) mod.ccontrol/$(am__dirstamp) -$(am__rm_f) mod.chanfix/$(DEPDIR)/$(am__dirstamp) @@ -6576,12 +6626,9 @@ distclean: distclean-recursive -rm -f libgnuworld/$(DEPDIR)/la-Signal.Plo -rm -f libgnuworld/$(DEPDIR)/la-StringTokenizer.Plo -rm -f libgnuworld/$(DEPDIR)/la-gThread.Plo - -rm -f libgnuworld/$(DEPDIR)/la-logger.Plo -rm -f libgnuworld/$(DEPDIR)/la-match.Plo -rm -f libgnuworld/$(DEPDIR)/la-md5hash.Plo -rm -f libgnuworld/$(DEPDIR)/la-misc.Plo - -rm -f libgnuworld/$(DEPDIR)/la-prometheus.Plo - -rm -f libgnuworld/$(DEPDIR)/la-pushover.Plo -rm -f libgnuworld/$(DEPDIR)/la-threadworker.Plo -rm -f libircu/$(DEPDIR)/la-msg_AC.Plo -rm -f libircu/$(DEPDIR)/la-msg_AD.Plo @@ -6621,6 +6668,9 @@ distclean: distclean-recursive -rm -f libircu/$(DEPDIR)/la-msg_XQ.Plo -rm -f libircu/$(DEPDIR)/la-msg_XR.Plo -rm -f libircu/$(DEPDIR)/la-msg_Y.Plo + -rm -f libnotifier/$(DEPDIR)/la-logger.Plo + -rm -f libnotifier/$(DEPDIR)/la-prometheus.Plo + -rm -f libnotifier/$(DEPDIR)/la-pushover.Plo -rm -f mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDCOMMANDCommand.Plo -rm -f mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDOPERCHANCommand.Plo -rm -f mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDSERVERCommand.Plo @@ -6950,12 +7000,9 @@ maintainer-clean: maintainer-clean-recursive -rm -f libgnuworld/$(DEPDIR)/la-Signal.Plo -rm -f libgnuworld/$(DEPDIR)/la-StringTokenizer.Plo -rm -f libgnuworld/$(DEPDIR)/la-gThread.Plo - -rm -f libgnuworld/$(DEPDIR)/la-logger.Plo -rm -f libgnuworld/$(DEPDIR)/la-match.Plo -rm -f libgnuworld/$(DEPDIR)/la-md5hash.Plo -rm -f libgnuworld/$(DEPDIR)/la-misc.Plo - -rm -f libgnuworld/$(DEPDIR)/la-prometheus.Plo - -rm -f libgnuworld/$(DEPDIR)/la-pushover.Plo -rm -f libgnuworld/$(DEPDIR)/la-threadworker.Plo -rm -f libircu/$(DEPDIR)/la-msg_AC.Plo -rm -f libircu/$(DEPDIR)/la-msg_AD.Plo @@ -6995,6 +7042,9 @@ maintainer-clean: maintainer-clean-recursive -rm -f libircu/$(DEPDIR)/la-msg_XQ.Plo -rm -f libircu/$(DEPDIR)/la-msg_XR.Plo -rm -f libircu/$(DEPDIR)/la-msg_Y.Plo + -rm -f libnotifier/$(DEPDIR)/la-logger.Plo + -rm -f libnotifier/$(DEPDIR)/la-prometheus.Plo + -rm -f libnotifier/$(DEPDIR)/la-pushover.Plo -rm -f mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDCOMMANDCommand.Plo -rm -f mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDOPERCHANCommand.Plo -rm -f mod.ccontrol/$(DEPDIR)/libccontrol_la-ADDSERVERCommand.Plo diff --git a/db/Makefile.am b/db/Makefile.am index cd3bcb93..e44d4c19 100644 --- a/db/Makefile.am +++ b/db/Makefile.am @@ -7,10 +7,11 @@ libgnuworldDB_la_SOURCES = \ db/pgsqlDB.cc libgnuworldDB_la_CXXFLAGS = \ -I$(top_srcdir)/libgnuworld \ + -I$(top_srcdir)/libnotifier \ -I$(top_srcdir)/include libgnuworldDB_la_LDFLAGS = -L$(pgsql_libdir) -lpq EXTRA_DIST += \ db/gnuworldDB.h \ db/pgsqlDB.h \ - db/dbHandle.h \ No newline at end of file + db/dbHandle.h diff --git a/include/gnuworld_config.h b/include/gnuworld_config.h index feceaad1..9c86bda3 100755 --- a/include/gnuworld_config.h +++ b/include/gnuworld_config.h @@ -81,13 +81,6 @@ */ #define TOPIC_TRACK -/** - * DAEMON - * Set this to make GNUWorld fork into the background when run. - * default is OFF to maintain original operation - */ -#undef DAEMON - /** * USE_THREAD * Set this to enable mutexes on shared objects. Relevant for running diff --git a/include/server.h b/include/server.h index eaa43a49..19d99b7d 100644 --- a/include/server.h +++ b/include/server.h @@ -78,10 +78,14 @@ class xServer : public ConnectionManager, public: /** - * The xServer constructor. It takes the arguments - * from the command line. + * The xServer constructor. It takes parsed configuration + * parameters from the command line. */ - xServer( int, char** ) ; + xServer( bool verbose, bool doDebug, bool logSocket, + const std::string& elogFileName, + const std::string& socketFileName, + const std::string& configFileName, + const std::string& simFileName ) ; /** * Destroy the server and its clients, disconnect @@ -1464,28 +1468,6 @@ class xServer : public ConnectionManager, */ std::ofstream socketFile ; - /** - * The name of the file for which elog to write all - * debugging information. - */ - std::string elogFileName ; - - /** - * The name of the file to write socket info - */ - std::string socketFileName ; - - /** - * The name of the server config file. - */ - std::string configFileName ; - - /** - * The name of the simulation file from which to read all - * simulation data, empty if in real mode. - */ - std::string simFileName ; - /** * The reason used to shutdown the server, displayed in * the SQ message. @@ -1502,20 +1484,43 @@ class xServer : public ConnectionManager, */ char inputCharBuffer[ 1024 ] ; + /** + * True if all elog data should be output to clog. + */ + bool verbose ; + + /** + * True if debug is enabled. + */ + bool doDebug ; + /** * True if logging of raw input data to file is enabled. */ bool logSocket ; + /** - * True if all elog data should be output to clog. + * The name of the file for which elog to write all + * debugging information. */ - bool verbose ; + std::string elogFileName ; /** - * True if debug is enabled. + * The name of the file to write socket info */ - bool doDebug ; + std::string socketFileName ; + + /** + * The name of the server config file. + */ + std::string configFileName ; + + /** + * The name of the simulation file from which to read all + * simulation data, empty if in real mode. + */ + std::string simFileName ; /** * True if autoreconnect is enabled, false otherwise. @@ -1537,6 +1542,7 @@ class xServer : public ConnectionManager, */ bool loadCommandHandlers() ; + /** * Load an individual command handler from a file (fileName), * and associate that handler with the network message diff --git a/libgnuworld/Makefile.am b/libgnuworld/Makefile.am index f3dabd22..4ea97c70 100644 --- a/libgnuworld/Makefile.am +++ b/libgnuworld/Makefile.am @@ -14,26 +14,11 @@ libgnuworld_la_SOURCES = \ libgnuworld/gThread.cc \ libgnuworld/match.cc \ libgnuworld/md5hash.cc \ - libgnuworld/logger.cc \ libgnuworld/threadworker.cc \ - libgnuworld/pushover.cc \ libgnuworld/misc.cc -if COND_PROMETHEUS -libgnuworld_la_SOURCES += libgnuworld/prometheus.cc -endif libgnuworld_la_LDFLAGS = $(threadLib) -if COND_LIBCURL -if COND_PROMETHEUS -libgnuworld_la_LIBADD = -lcurl -lprometheus-cpp-core -lprometheus-cpp-pull -else -libgnuworld_la_LIBADD = -lcurl -endif -else -if COND_PROMETHEUS -libgnuworld_la_LIBADD = -lprometheus-cpp-core -lprometheus-cpp-pull -endif -endif + libgnuworld_la_CXXFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/libgnuworld @@ -50,11 +35,7 @@ EXTRA_DIST += \ libgnuworld/match.h \ libgnuworld/match_table.h \ libgnuworld/md5hash.h \ - libgnuworld/logger.h \ libgnuworld/threadworker.h \ - libgnuworld/notifier.h \ - libgnuworld/prometheus.h \ - libgnuworld/pushover.h \ libgnuworld/misc.h \ libgnuworld/MTrie.h \ libgnuworld/MTrie.cc \ diff --git a/libgnuworld/threadworker.cc b/libgnuworld/threadworker.cc index 6f5a5fc1..5d3fb373 100644 --- a/libgnuworld/threadworker.cc +++ b/libgnuworld/threadworker.cc @@ -26,7 +26,7 @@ namespace gnuworld { -ThreadWorker::ThreadWorker( xClient* _bot ) : stop( false ), bot( _bot ), logger( _bot->getLogger() ) +ThreadWorker::ThreadWorker( ) : stop( false ) { worker = std::thread( &ThreadWorker::run, this ) ; } @@ -55,21 +55,21 @@ while( true ) job = std::move( jobs.front() ) ; jobs.pop() ; } - + try { - LOG( TRACE, "Starting job execution" ) ; + // elog << "Starting job execution" << endl ; job() ; } catch( const std::exception& e ) { - LOG( ERROR, "Exception in job execution: {}", e.what() ) ; + elog << "Exception in job execution: " << e.what() << std::endl ; } catch( ... ) { - LOG( ERROR, "Unknown exception in job execution" ) ; + elog << "Unknown exception in job execution" << std::endl ; } } } -} // namespace gnuworld \ No newline at end of file +} // namespace gnuworld diff --git a/libgnuworld/threadworker.h b/libgnuworld/threadworker.h index d296742e..740d5fd5 100644 --- a/libgnuworld/threadworker.h +++ b/libgnuworld/threadworker.h @@ -28,9 +28,6 @@ #include #include -#include "client.h" -#include "logger.h" - namespace gnuworld { @@ -42,16 +39,10 @@ class ThreadWorker { std::thread worker ; bool stop ; - /* The bot. */ - xClient* bot ; - - /* Pointer to the xClient's logger. */ - Logger* logger ; - void run() ; public: - ThreadWorker( xClient* ) ; + ThreadWorker() ; ~ThreadWorker() ; template< typename Callable > @@ -76,4 +67,4 @@ class ThreadWorker { } } ; -} // namespace gnuworld \ No newline at end of file +} // namespace gnuworld diff --git a/libircu/Makefile.am b/libircu/Makefile.am index 3deac84c..091fe040 100644 --- a/libircu/Makefile.am +++ b/libircu/Makefile.am @@ -42,5 +42,5 @@ libircu_la_SOURCES = \ libircu/msg_XR.cc \ libircu/msg_Y.cc -libircu_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +libircu_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld -I${top_srcdir}/libnotifier libircu_la_LDFLAGS = -module -export-dynamic diff --git a/libltdl/Makefile.in b/libltdl/Makefile.in index 5f74cef3..5b34f616 100644 --- a/libltdl/Makefile.in +++ b/libltdl/Makefile.in @@ -112,7 +112,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ $(am__ltdlinclude_HEADERS_DIST) $(am__DIST_COMMON) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno -mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs +mkinstalldirs = $(install_sh) -d CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = @@ -296,15 +296,18 @@ am__define_uniq_tagged_files = \ done | $(am__uniquify_input)` AM_RECURSIVE_TARGETS = cscope am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config-h.in \ - $(top_srcdir)/../compile $(top_srcdir)/../config.guess \ - $(top_srcdir)/../config.sub $(top_srcdir)/../depcomp \ - $(top_srcdir)/../install-sh $(top_srcdir)/../ltmain.sh \ - $(top_srcdir)/../missing $(top_srcdir)/../mkinstalldirs \ - ../AUTHORS ../COPYING ../ChangeLog ../INSTALL ../NEWS \ - ../README ../TODO ../ar-lib ../compile ../config.guess \ - ../config.sub ../depcomp ../install-sh ../ltconfig \ - ../ltmain.sh ../missing ../mkinstalldirs COPYING.LIB README \ - lt__argz.c lt__dirent.c lt__strl.c + $(top_srcdir)/../compile \ + $(top_srcdir)/../config.guess \ + $(top_srcdir)/../config.sub \ + $(top_srcdir)/../depcomp \ + $(top_srcdir)/../install-sh \ + $(top_srcdir)/../ltmain.sh \ + $(top_srcdir)/../missing ../compile \ + ../config.guess ../config.sub \ + ../depcomp ../install-sh \ + ../ltmain.sh \ + ../missing COPYING.LIB \ + README lt__argz.c lt__dirent.c lt__strl.c DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) diff --git a/libnotifier/Makefile.am b/libnotifier/Makefile.am new file mode 100644 index 00000000..6f39a33b --- /dev/null +++ b/libnotifier/Makefile.am @@ -0,0 +1,36 @@ +## Process this file with automake to produce Makefile.in +## $Id: Makefile.am,v 1.9 2004/01/07 20:23:20 dan_karrels Exp $ + +noinst_LTLIBRARIES += libnotifier.la +libnotifier_la_SOURCES = \ + libnotifier/logger.cc \ + libnotifier/pushover.cc + +if COND_PROMETHEUS +libnotifier_la_SOURCES += libnotifier/prometheus.cc +endif + +libnotifier_la_CXXFLAGS = \ + -I$(top_srcdir)/include \ + -I$(top_srcdir)/libgnuworld \ + -I$(top_srcdir)/libnotifier + +libnotifier_la_LIBADD = + +if COND_LIBCURL +if COND_PROMETHEUS +libnotifier_la_LIBADD += -lcurl -lprometheus-cpp-core -lprometheus-cpp-pull +else +libnotifier_la_LIBADD += -lcurl +endif +else +if COND_PROMETHEUS +libnotifier_la_LIBADD += -lprometheus-cpp-core -lprometheus-cpp-pull +endif +endif + +EXTRA_DIST += \ + libnotifier/logger.h \ + libnotifier/notifier.h \ + libnotifier/prometheus.h \ + libnotifier/pushover.h diff --git a/libgnuworld/logger.cc b/libnotifier/logger.cc similarity index 100% rename from libgnuworld/logger.cc rename to libnotifier/logger.cc diff --git a/libgnuworld/logger.h b/libnotifier/logger.h similarity index 100% rename from libgnuworld/logger.h rename to libnotifier/logger.h diff --git a/libgnuworld/notifier.h b/libnotifier/notifier.h similarity index 100% rename from libgnuworld/notifier.h rename to libnotifier/notifier.h diff --git a/libgnuworld/prometheus.cc b/libnotifier/prometheus.cc similarity index 100% rename from libgnuworld/prometheus.cc rename to libnotifier/prometheus.cc diff --git a/libgnuworld/prometheus.h b/libnotifier/prometheus.h similarity index 100% rename from libgnuworld/prometheus.h rename to libnotifier/prometheus.h diff --git a/libgnuworld/pushover.cc b/libnotifier/pushover.cc similarity index 100% rename from libgnuworld/pushover.cc rename to libnotifier/pushover.cc diff --git a/libgnuworld/pushover.h b/libnotifier/pushover.h similarity index 100% rename from libgnuworld/pushover.h rename to libnotifier/pushover.h diff --git a/m4/ltargz.m4 b/m4/ltargz.m4 deleted file mode 100644 index b93c2824..00000000 --- a/m4/ltargz.m4 +++ /dev/null @@ -1,77 +0,0 @@ -# Portability macros for glibc argz. -*- Autoconf -*- -# -# Copyright (C) 2004-2007, 2011-2019, 2021-2024 Free Software -# Foundation, Inc. -# Written by Gary V. Vaughan -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 2 ltargz.m4 - -AC_DEFUN([LT_FUNC_ARGZ], [ -dnl Required for use of '$SED' in Cygwin configuration. -AC_REQUIRE([AC_PROG_SED])dnl -AC_CHECK_HEADERS([argz.h], [], [], [AC_INCLUDES_DEFAULT]) - -AC_CHECK_TYPES([error_t], - [], - [AC_DEFINE([error_t], [int], - [Define to a type to use for 'error_t' if it is not otherwise available.]) - AC_DEFINE([__error_t_defined], [1], [Define so that glibc/gnulib argp.h - does not typedef error_t.])], - [#if defined(HAVE_ARGZ_H) -# include -#endif]) - -LT_ARGZ_H= -AC_CHECK_FUNCS([argz_add argz_append argz_count argz_create_sep argz_insert \ - argz_next argz_stringify], [], [LT_ARGZ_H=lt__argz.h; AC_LIBOBJ([lt__argz])]) - -dnl if have system argz functions, allow forced use of -dnl libltdl-supplied implementation (and default to do so -dnl on "known bad" systems). Could use a runtime check, but -dnl (a) detecting malloc issues is notoriously unreliable -dnl (b) only known system that declares argz functions, -dnl provides them, yet they are broken, is cygwin -dnl releases prior to 16-Mar-2007 (1.5.24 and earlier) -dnl So, it's more straightforward simply to special case -dnl this for known bad systems. -AS_IF([test -z "$LT_ARGZ_H"], - [AC_CACHE_CHECK( - [if argz actually works], - [lt_cv_sys_argz_works], - [[case $host_os in #( - *cygwin*) - lt_cv_sys_argz_works=no - if test no != "$cross_compiling"; then - lt_cv_sys_argz_works="guessing no" - else - lt_sed_extract_leading_digits='s/^\([0-9\.]*\).*/\1/' - save_IFS=$IFS - IFS=-. - set x `uname -r | $SED -e "$lt_sed_extract_leading_digits"` - IFS=$save_IFS - lt_os_major=${2-0} - lt_os_minor=${3-0} - lt_os_micro=${4-0} - if test 1 -lt "$lt_os_major" \ - || { test 1 -eq "$lt_os_major" \ - && { test 5 -lt "$lt_os_minor" \ - || { test 5 -eq "$lt_os_minor" \ - && test 24 -lt "$lt_os_micro"; }; }; }; then - lt_cv_sys_argz_works=yes - fi - fi - ;; #( - *) lt_cv_sys_argz_works=yes ;; - esac]]) - AS_IF([test yes = "$lt_cv_sys_argz_works"], - [AC_DEFINE([HAVE_WORKING_ARGZ], 1, - [This value is set to 1 to indicate that the system argz facility works])], - [LT_ARGZ_H=lt__argz.h - AC_LIBOBJ([lt__argz])])]) - -AC_SUBST([LT_ARGZ_H]) -]) diff --git a/m4/ltdl.m4 b/m4/ltdl.m4 deleted file mode 100644 index c7790ffd..00000000 --- a/m4/ltdl.m4 +++ /dev/null @@ -1,911 +0,0 @@ -# ltdl.m4 - Configure ltdl for the target system. -*-Autoconf-*- -# -# Copyright (C) 1999-2008, 2011-2019, 2021-2024 Free Software -# Foundation, Inc. -# Written by Thomas Tanner, 1999 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 24 LTDL_INIT - -# LT_CONFIG_LTDL_DIR(DIRECTORY, [LTDL-MODE]) -# ------------------------------------------ -# DIRECTORY contains the libltdl sources. It is okay to call this -# function multiple times, as long as the same DIRECTORY is always given. -AC_DEFUN([LT_CONFIG_LTDL_DIR], -[AC_BEFORE([$0], [LTDL_INIT]) -_$0($*) -])# LT_CONFIG_LTDL_DIR - -# We break this out into a separate macro, so that we can call it safely -# internally without being caught accidentally by the sed scan in libtoolize. -m4_defun([_LT_CONFIG_LTDL_DIR], -[dnl remove trailing slashes -m4_pushdef([_ARG_DIR], m4_bpatsubst([$1], [/*$])) -m4_case(_LTDL_DIR, - [], [dnl only set lt_ltdl_dir if _ARG_DIR is not simply '.' - m4_if(_ARG_DIR, [.], - [], - [m4_define([_LTDL_DIR], _ARG_DIR) - _LT_SHELL_INIT([lt_ltdl_dir=']_ARG_DIR['])])], - [m4_if(_ARG_DIR, _LTDL_DIR, - [], - [m4_fatal([multiple libltdl directories: ']_LTDL_DIR[', ']_ARG_DIR['])])]) -m4_popdef([_ARG_DIR]) -])# _LT_CONFIG_LTDL_DIR - -# Initialise: -m4_define([_LTDL_DIR], []) - - -# _LT_BUILD_PREFIX -# ---------------- -# If Autoconf is new enough, expand to '$(top_build_prefix)', otherwise -# to '$(top_builddir)/'. -m4_define([_LT_BUILD_PREFIX], -[m4_ifdef([AC_AUTOCONF_VERSION], - [m4_if(m4_version_compare(m4_defn([AC_AUTOCONF_VERSION]), [2.62]), - [-1], [m4_ifdef([_AC_HAVE_TOP_BUILD_PREFIX], - [$(top_build_prefix)], - [$(top_builddir)/])], - [$(top_build_prefix)])], - [$(top_builddir)/])[]dnl -]) - - -# LTDL_CONVENIENCE -# ---------------- -# sets LIBLTDL to the link flags for the libltdl convenience library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-convenience to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called here. LIBLTDL will be prefixed with -# '$(top_build_prefix)' if available, otherwise with '$(top_builddir)/', -# and LTDLINCL will be prefixed with '$(top_srcdir)/' (note the single -# quotes!). If your package is not flat and you're not using automake, -# define top_build_prefix, top_builddir, and top_srcdir appropriately -# in your Makefiles. -AC_DEFUN([LTDL_CONVENIENCE], -[AC_BEFORE([$0], [LTDL_INIT])dnl -dnl Although the argument is deprecated and no longer documented, -dnl LTDL_CONVENIENCE used to take a DIRECTORY orgument, if we have one -dnl here make sure it is the same as any other declaration of libltdl's -dnl location! This also ensures lt_ltdl_dir is set when configure.ac is -dnl not yet using an explicit LT_CONFIG_LTDL_DIR. -m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl -_$0() -])# LTDL_CONVENIENCE - -# AC_LIBLTDL_CONVENIENCE accepted a directory argument in older libtools, -# now we have LT_CONFIG_LTDL_DIR: -AU_DEFUN([AC_LIBLTDL_CONVENIENCE], -[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) -_LTDL_CONVENIENCE]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBLTDL_CONVENIENCE], []) - - -# _LTDL_CONVENIENCE -# ----------------- -# Code shared by LTDL_CONVENIENCE and LTDL_INIT([convenience]). -m4_defun([_LTDL_CONVENIENCE], -[case $enable_ltdl_convenience in - no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; - "") enable_ltdl_convenience=yes - ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; -esac -LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdlc.la" -LTDLDEPS=$LIBLTDL -LTDLINCL='-I$(top_srcdir)'"${lt_ltdl_dir+/$lt_ltdl_dir}" - -AC_SUBST([LIBLTDL]) -AC_SUBST([LTDLDEPS]) -AC_SUBST([LTDLINCL]) - -# For backwards non-gettext consistent compatibility... -INCLTDL=$LTDLINCL -AC_SUBST([INCLTDL]) -])# _LTDL_CONVENIENCE - - -# LTDL_INSTALLABLE -# ---------------- -# sets LIBLTDL to the link flags for the libltdl installable library -# and LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-install to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called from here. If an installed libltdl -# is not found, LIBLTDL will be prefixed with '$(top_build_prefix)' if -# available, otherwise with '$(top_builddir)/', and LTDLINCL will be -# prefixed with '$(top_srcdir)/' (note the single quotes!). If your -# package is not flat and you're not using automake, define top_build_prefix, -# top_builddir, and top_srcdir appropriately in your Makefiles. -# In the future, this macro may have to be called after LT_INIT. -AC_DEFUN([LTDL_INSTALLABLE], -[AC_BEFORE([$0], [LTDL_INIT])dnl -dnl Although the argument is deprecated and no longer documented, -dnl LTDL_INSTALLABLE used to take a DIRECTORY orgument, if we have one -dnl here make sure it is the same as any other declaration of libltdl's -dnl location! This also ensures lt_ltdl_dir is set when configure.ac is -dnl not yet using an explicit LT_CONFIG_LTDL_DIR. -m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl -_$0() -])# LTDL_INSTALLABLE - -# AC_LIBLTDL_INSTALLABLE accepted a directory argument in older libtools, -# now we have LT_CONFIG_LTDL_DIR: -AU_DEFUN([AC_LIBLTDL_INSTALLABLE], -[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) -_LTDL_INSTALLABLE]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBLTDL_INSTALLABLE], []) - - -# _LTDL_INSTALLABLE -# ----------------- -# Code shared by LTDL_INSTALLABLE and LTDL_INIT([installable]). -m4_defun([_LTDL_INSTALLABLE], -[if test -f "$prefix/lib/libltdl.la"; then - lt_save_LDFLAGS=$LDFLAGS - LDFLAGS="-L$prefix/lib $LDFLAGS" - AC_CHECK_LIB([ltdl], [lt_dlinit], [lt_lib_ltdl=yes]) - LDFLAGS=$lt_save_LDFLAGS - if test yes = "${lt_lib_ltdl-no}"; then - if test yes != "$enable_ltdl_install"; then - # Don't overwrite $prefix/lib/libltdl.la without --enable-ltdl-install - AC_MSG_WARN([not overwriting libltdl at $prefix, force with '--enable-ltdl-install']) - enable_ltdl_install=no - fi - elif test no = "$enable_ltdl_install"; then - AC_MSG_WARN([libltdl not installed, but installation disabled]) - fi -fi - -# If configure.ac declared an installable ltdl, and the user didn't override -# with --disable-ltdl-install, we will install the shipped libltdl. -case $enable_ltdl_install in - no) ac_configure_args="$ac_configure_args --enable-ltdl-install=no" - LIBLTDL=-lltdl - LTDLDEPS= - LTDLINCL= - ;; - *) enable_ltdl_install=yes - ac_configure_args="$ac_configure_args --enable-ltdl-install" - LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdl.la" - LTDLDEPS=$LIBLTDL - LTDLINCL='-I$(top_srcdir)'"${lt_ltdl_dir+/$lt_ltdl_dir}" - ;; -esac - -AC_SUBST([LIBLTDL]) -AC_SUBST([LTDLDEPS]) -AC_SUBST([LTDLINCL]) - -# For backwards non-gettext consistent compatibility... -INCLTDL=$LTDLINCL -AC_SUBST([INCLTDL]) -])# LTDL_INSTALLABLE - - -# _LTDL_MODE_DISPATCH -# ------------------- -m4_define([_LTDL_MODE_DISPATCH], -[dnl If _LTDL_DIR is '.', then we are configuring libltdl itself: -m4_if(_LTDL_DIR, [], - [], - dnl if _LTDL_MODE was not set already, the default value is 'subproject': - [m4_case(m4_default(_LTDL_MODE, [subproject]), - [subproject], [AC_CONFIG_SUBDIRS(_LTDL_DIR) - _LT_SHELL_INIT([lt_dlopen_dir=$lt_ltdl_dir])], - [nonrecursive], [_LT_SHELL_INIT([lt_dlopen_dir=$lt_ltdl_dir; lt_libobj_prefix=$lt_ltdl_dir/])], - [recursive], [], - [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])])dnl -dnl Be careful not to expand twice: -m4_define([$0], []) -])# _LTDL_MODE_DISPATCH - - -# _LT_LIBOBJ(MODULE_NAME) -# ----------------------- -# Like AC_LIBOBJ, except that MODULE_NAME goes into _LT_LIBOBJS instead -# of into LIBOBJS. -AC_DEFUN([_LT_LIBOBJ], [ - m4_pattern_allow([^_LT_LIBOBJS$]) - _LT_LIBOBJS="$_LT_LIBOBJS $1.$ac_objext" -])# _LT_LIBOBJS - - -# LTDL_INIT([OPTIONS]) -# -------------------- -# Clients of libltdl can use this macro to allow the installer to -# choose between a shipped copy of the ltdl sources or a preinstalled -# version of the library. If the shipped ltdl sources are not in a -# subdirectory named libltdl, the directory name must be given by -# LT_CONFIG_LTDL_DIR. -AC_DEFUN([LTDL_INIT], -[dnl Parse OPTIONS -_LT_SET_OPTIONS([$0], [$1]) - -dnl We need to keep our own list of libobjs separate from our parent project, -dnl and the easiest way to do that is redefine the AC_LIBOBJs macro while -dnl we look for our own LIBOBJs. -m4_pushdef([AC_LIBOBJ], m4_defn([_LT_LIBOBJ])) -m4_pushdef([AC_LIBSOURCES]) - -dnl If not otherwise defined, default to the 1.5.x compatible subproject mode: -m4_if(_LTDL_MODE, [], - [m4_define([_LTDL_MODE], m4_default([$2], [subproject])) - m4_if([-1], [m4_bregexp(_LTDL_MODE, [\(subproject\|\(non\)?recursive\)])], - [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])]) - -AC_ARG_WITH([included_ltdl], - [AS_HELP_STRING([--with-included-ltdl], - [use the GNU ltdl sources included here])]) - -if test yes != "$with_included_ltdl"; then - # We are not being forced to use the included libltdl sources, so - # decide whether there is a useful installed version we can use. - AC_CHECK_HEADER([ltdl.h], - [AC_CHECK_DECL([lt_dlinterface_register], - [AC_CHECK_LIB([ltdl], [lt_dladvise_preload], - [with_included_ltdl=no], - [with_included_ltdl=yes])], - [with_included_ltdl=yes], - [AC_INCLUDES_DEFAULT - #include ])], - [with_included_ltdl=yes], - [AC_INCLUDES_DEFAULT] - ) -fi - -dnl If neither LT_CONFIG_LTDL_DIR, LTDL_CONVENIENCE nor LTDL_INSTALLABLE -dnl was called yet, then for old times' sake, we assume libltdl is in an -dnl eponymous directory: -AC_PROVIDE_IFELSE([LT_CONFIG_LTDL_DIR], [], [_LT_CONFIG_LTDL_DIR([libltdl])]) - -AC_ARG_WITH([ltdl_include], - [AS_HELP_STRING([--with-ltdl-include=DIR], - [use the ltdl headers installed in DIR])]) - -if test -n "$with_ltdl_include"; then - if test -f "$with_ltdl_include/ltdl.h"; then : - else - AC_MSG_ERROR([invalid ltdl include directory: '$with_ltdl_include']) - fi -else - with_ltdl_include=no -fi - -AC_ARG_WITH([ltdl_lib], - [AS_HELP_STRING([--with-ltdl-lib=DIR], - [use the libltdl.la installed in DIR])]) - -if test -n "$with_ltdl_lib"; then - if test -f "$with_ltdl_lib/libltdl.la"; then : - else - AC_MSG_ERROR([invalid ltdl library directory: '$with_ltdl_lib']) - fi -else - with_ltdl_lib=no -fi - -case ,$with_included_ltdl,$with_ltdl_include,$with_ltdl_lib, in - ,yes,no,no,) - m4_case(m4_default(_LTDL_TYPE, [convenience]), - [convenience], [_LTDL_CONVENIENCE], - [installable], [_LTDL_INSTALLABLE], - [m4_fatal([unknown libltdl build type: ]_LTDL_TYPE)]) - ;; - ,no,no,no,) - # If the included ltdl is not to be used, then use the - # preinstalled libltdl we found. - AC_DEFINE([HAVE_LTDL], [1], - [Define this if a modern libltdl is already installed]) - LIBLTDL=-lltdl - LTDLDEPS= - LTDLINCL= - ;; - ,no*,no,*) - AC_MSG_ERROR(['--with-ltdl-include' and '--with-ltdl-lib' options must be used together]) - ;; - *) with_included_ltdl=no - LIBLTDL="-L$with_ltdl_lib -lltdl" - LTDLDEPS= - LTDLINCL=-I$with_ltdl_include - ;; -esac -INCLTDL=$LTDLINCL - -# Report our decision... -AC_MSG_CHECKING([where to find libltdl headers]) -AC_MSG_RESULT([$LTDLINCL]) -AC_MSG_CHECKING([where to find libltdl library]) -AC_MSG_RESULT([$LIBLTDL]) - -_LTDL_SETUP - -dnl restore autoconf definition. -m4_popdef([AC_LIBOBJ]) -m4_popdef([AC_LIBSOURCES]) - -AC_CONFIG_COMMANDS_PRE([ - _ltdl_libobjs= - _ltdl_ltlibobjs= - if test -n "$_LT_LIBOBJS"; then - # Remove the extension. - _lt_sed_drop_objext='s/\.o$//;s/\.obj$//' - for i in `for i in $_LT_LIBOBJS; do echo "$i"; done | $SED "$_lt_sed_drop_objext" | sort -u`; do - _ltdl_libobjs="$_ltdl_libobjs $lt_libobj_prefix$i.$ac_objext" - _ltdl_ltlibobjs="$_ltdl_ltlibobjs $lt_libobj_prefix$i.lo" - done - fi - AC_SUBST([ltdl_LIBOBJS], [$_ltdl_libobjs]) - AC_SUBST([ltdl_LTLIBOBJS], [$_ltdl_ltlibobjs]) -]) - -# Only expand once: -m4_define([LTDL_INIT]) -])# LTDL_INIT - -# Old names: -AU_DEFUN([AC_LIB_LTDL], [LTDL_INIT($@)]) -AU_DEFUN([AC_WITH_LTDL], [LTDL_INIT($@)]) -AU_DEFUN([LT_WITH_LTDL], [LTDL_INIT($@)]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIB_LTDL], []) -dnl AC_DEFUN([AC_WITH_LTDL], []) -dnl AC_DEFUN([LT_WITH_LTDL], []) - - -# _LTDL_SETUP -# ----------- -# Perform all the checks necessary for compilation of the ltdl objects -# -- including compiler checks and header checks. This is a public -# interface mainly for the benefit of libltdl's own configure.ac, most -# other users should call LTDL_INIT instead. -AC_DEFUN([_LTDL_SETUP], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([LT_SYS_MODULE_EXT])dnl -AC_REQUIRE([LT_SYS_MODULE_PATH])dnl -AC_REQUIRE([LT_SYS_DLSEARCH_PATH])dnl -AC_REQUIRE([LT_LIB_DLLOAD])dnl -AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl -AC_REQUIRE([LT_FUNC_DLSYM_USCORE])dnl -AC_REQUIRE([LT_SYS_DLOPEN_DEPLIBS])dnl -AC_REQUIRE([LT_FUNC_ARGZ])dnl - -m4_require([_LT_CHECK_OBJDIR])dnl -m4_require([_LT_HEADER_DLFCN])dnl -m4_require([_LT_CHECK_DLPREOPEN])dnl -m4_require([_LT_DECL_SED])dnl - -dnl Don't require this, or it will be expanded earlier than the code -dnl that sets the variables it relies on: -_LT_ENABLE_INSTALL - -dnl _LTDL_MODE specific code must be called at least once: -_LTDL_MODE_DISPATCH - -# In order that ltdl.c can compile, find out the first AC_CONFIG_HEADERS -# the user used. This is so that ltdl.h can pick up the parent projects -# config.h file, The first file in AC_CONFIG_HEADERS must contain the -# definitions required by ltdl.c. -# FIXME: Remove use of undocumented AC_LIST_HEADERS (2.59 compatibility). -AC_CONFIG_COMMANDS_PRE([dnl -m4_pattern_allow([^LT_CONFIG_H$])dnl -m4_ifset([AH_HEADER], - [LT_CONFIG_H=AH_HEADER], - [m4_ifset([AC_LIST_HEADERS], - [LT_CONFIG_H=`echo "AC_LIST_HEADERS" | $SED 's|^[[ ]]*||;s|[[ :]].*$||'`], - [])])]) -AC_SUBST([LT_CONFIG_H]) - -AC_CHECK_HEADERS([unistd.h dl.h sys/dl.h dld.h mach-o/dyld.h dirent.h], - [], [], [AC_INCLUDES_DEFAULT]) - -AC_CHECK_FUNCS([closedir opendir readdir], [], [AC_LIBOBJ([lt__dirent])]) -AC_CHECK_FUNCS([strlcat strlcpy], [], [AC_LIBOBJ([lt__strl])]) - -m4_pattern_allow([LT_LIBEXT])dnl -AC_DEFINE_UNQUOTED([LT_LIBEXT],["$libext"],[The archive extension]) - -name= -eval "lt_libprefix=\"$libname_spec\"" -m4_pattern_allow([LT_LIBPREFIX])dnl -AC_DEFINE_UNQUOTED([LT_LIBPREFIX],["$lt_libprefix"],[The archive prefix]) - -name=ltdl -eval "LTDLOPEN=\"$libname_spec\"" -AC_SUBST([LTDLOPEN]) -])# _LTDL_SETUP - - -# _LT_ENABLE_INSTALL -# ------------------ -m4_define([_LT_ENABLE_INSTALL], -[AC_ARG_ENABLE([ltdl-install], - [AS_HELP_STRING([--enable-ltdl-install], [install libltdl])]) - -case ,$enable_ltdl_install,$enable_ltdl_convenience in - *yes*) ;; - *) enable_ltdl_convenience=yes ;; -esac - -m4_ifdef([AM_CONDITIONAL], -[AM_CONDITIONAL(INSTALL_LTDL, test no != "${enable_ltdl_install-no}") - AM_CONDITIONAL(CONVENIENCE_LTDL, test no != "${enable_ltdl_convenience-no}") - AM_CONDITIONAL(LTARGZH_EXISTS, test -n "$LT_ARGZ_H")]) -])# _LT_ENABLE_INSTALL - - -# LT_SYS_DLOPEN_DEPLIBS -# --------------------- -AC_DEFUN([LT_SYS_DLOPEN_DEPLIBS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_CACHE_CHECK([whether deplibs are loaded by dlopen], - [lt_cv_sys_dlopen_deplibs], - [# PORTME does your system automatically load deplibs for dlopen? - # or its logical equivalent (e.g. shl_load for HP-UX < 11) - # For now, we just catch OSes we know something about -- in the - # future, we'll try test this programmatically. - lt_cv_sys_dlopen_deplibs=unknown - case $host_os in - aix3*|aix4.1.*|aix4.2.*) - # Unknown whether this is true for these versions of AIX, but - # we want this 'case' here to explicitly catch those versions. - lt_cv_sys_dlopen_deplibs=unknown - ;; - aix[[4-9]]*) - lt_cv_sys_dlopen_deplibs=yes - ;; - amigaos*) - case $host_cpu in - powerpc) - lt_cv_sys_dlopen_deplibs=no - ;; - esac - ;; - darwin*) - # Assuming the user has installed a libdl from somewhere, this is true - # If you are looking for one http://www.opendarwin.org/projects/dlcompat - lt_cv_sys_dlopen_deplibs=yes - ;; - freebsd* | dragonfly* | midnightbsd*) - lt_cv_sys_dlopen_deplibs=yes - ;; - gnu* | linux* | k*bsd*-gnu | kopensolaris*-gnu) - # GNU and its variants, using gnu ld.so (Glibc) - lt_cv_sys_dlopen_deplibs=yes - ;; - hpux10*|hpux11*) - lt_cv_sys_dlopen_deplibs=yes - ;; - interix*) - lt_cv_sys_dlopen_deplibs=yes - ;; - irix[[12345]]*|irix6.[[01]]*) - # Catch all versions of IRIX before 6.2, and indicate that we don't - # know how it worked for any of those versions. - lt_cv_sys_dlopen_deplibs=unknown - ;; - irix*) - # The case above catches anything before 6.2, and it's known that - # at 6.2 and later dlopen does load deplibs. - lt_cv_sys_dlopen_deplibs=yes - ;; - *-mlibc) - lt_cv_sys_dlopen_deplibs=yes - ;; - netbsd* | netbsdelf*-gnu) - lt_cv_sys_dlopen_deplibs=yes - ;; - openbsd*) - lt_cv_sys_dlopen_deplibs=yes - ;; - osf[[1234]]*) - # dlopen did load deplibs (at least at 4.x), but until the 5.x series, - # it did *not* use an RPATH in a shared library to find objects the - # library depends on, so we explicitly say 'no'. - lt_cv_sys_dlopen_deplibs=no - ;; - osf5.0|osf5.0a|osf5.1) - # dlopen *does* load deplibs and with the right loader patch applied - # it even uses RPATH in a shared library to search for shared objects - # that the library depends on, but there's no easy way to know if that - # patch is installed. Since this is the case, all we can really - # say is unknown -- it depends on the patch being installed. If - # it is, this changes to 'yes'. Without it, it would be 'no'. - lt_cv_sys_dlopen_deplibs=unknown - ;; - osf*) - # the two cases above should catch all versions of osf <= 5.1. Read - # the comments above for what we know about them. - # At > 5.1, deplibs are loaded *and* any RPATH in a shared library - # is used to find them so we can finally say 'yes'. - lt_cv_sys_dlopen_deplibs=yes - ;; - qnx*) - lt_cv_sys_dlopen_deplibs=yes - ;; - solaris*) - lt_cv_sys_dlopen_deplibs=yes - ;; - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - libltdl_cv_sys_dlopen_deplibs=yes - ;; - esac - ]) -if test yes != "$lt_cv_sys_dlopen_deplibs"; then - AC_DEFINE([LTDL_DLOPEN_DEPLIBS], [1], - [Define if the OS needs help to load dependent libraries for dlopen().]) -fi -])# LT_SYS_DLOPEN_DEPLIBS - -# Old name: -AU_ALIAS([AC_LTDL_SYS_DLOPEN_DEPLIBS], [LT_SYS_DLOPEN_DEPLIBS]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SYS_DLOPEN_DEPLIBS], []) - - -# LT_SYS_MODULE_EXT -# ----------------- -AC_DEFUN([LT_SYS_MODULE_EXT], -[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -AC_CACHE_CHECK([what extension is used for runtime loadable modules], - [libltdl_cv_shlibext], -[ -module=yes -eval libltdl_cv_shlibext=$shrext_cmds -module=no -eval libltdl_cv_shrext=$shrext_cmds - ]) -if test -n "$libltdl_cv_shlibext"; then - m4_pattern_allow([LT_MODULE_EXT])dnl - AC_DEFINE_UNQUOTED([LT_MODULE_EXT], ["$libltdl_cv_shlibext"], - [Define to the extension used for runtime loadable modules, say, ".so".]) -fi -if test "$libltdl_cv_shrext" != "$libltdl_cv_shlibext"; then - m4_pattern_allow([LT_SHARED_EXT])dnl - AC_DEFINE_UNQUOTED([LT_SHARED_EXT], ["$libltdl_cv_shrext"], - [Define to the shared library suffix, say, ".dylib".]) -fi -if test -n "$shared_archive_member_spec"; then - m4_pattern_allow([LT_SHARED_LIB_MEMBER])dnl - AC_DEFINE_UNQUOTED([LT_SHARED_LIB_MEMBER], ["($shared_archive_member_spec.o)"], - [Define to the shared archive member specification, say "(shr.o)".]) -fi -])# LT_SYS_MODULE_EXT - -# Old name: -AU_ALIAS([AC_LTDL_SHLIBEXT], [LT_SYS_MODULE_EXT]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SHLIBEXT], []) - - -# LT_SYS_MODULE_PATH -# ------------------ -AC_DEFUN([LT_SYS_MODULE_PATH], -[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -AC_CACHE_CHECK([what variable specifies run-time module search path], - [lt_cv_module_path_var], [lt_cv_module_path_var=$shlibpath_var]) -if test -n "$lt_cv_module_path_var"; then - m4_pattern_allow([LT_MODULE_PATH_VAR])dnl - AC_DEFINE_UNQUOTED([LT_MODULE_PATH_VAR], ["$lt_cv_module_path_var"], - [Define to the name of the environment variable that determines the run-time module search path.]) -fi -])# LT_SYS_MODULE_PATH - -# Old name: -AU_ALIAS([AC_LTDL_SHLIBPATH], [LT_SYS_MODULE_PATH]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SHLIBPATH], []) - - -# LT_SYS_DLSEARCH_PATH -# -------------------- -AC_DEFUN([LT_SYS_DLSEARCH_PATH], -[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -AC_CACHE_CHECK([for the default library search path], - [lt_cv_sys_dlsearch_path], - [lt_cv_sys_dlsearch_path=$sys_lib_dlsearch_path_spec]) -if test -n "$lt_cv_sys_dlsearch_path"; then - sys_dlsearch_path= - for dir in $lt_cv_sys_dlsearch_path; do - if test -z "$sys_dlsearch_path"; then - sys_dlsearch_path=$dir - else - sys_dlsearch_path=$sys_dlsearch_path$PATH_SEPARATOR$dir - fi - done - m4_pattern_allow([LT_DLSEARCH_PATH])dnl - AC_DEFINE_UNQUOTED([LT_DLSEARCH_PATH], ["$sys_dlsearch_path"], - [Define to the system default library search path.]) -fi -])# LT_SYS_DLSEARCH_PATH - -# Old name: -AU_ALIAS([AC_LTDL_SYSSEARCHPATH], [LT_SYS_DLSEARCH_PATH]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SYSSEARCHPATH], []) - - -# _LT_CHECK_DLPREOPEN -# ------------------- -m4_defun([_LT_CHECK_DLPREOPEN], -[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -AC_CACHE_CHECK([whether libtool supports -dlopen/-dlpreopen], - [libltdl_cv_preloaded_symbols], - [if test -n "$lt_cv_sys_global_symbol_pipe"; then - libltdl_cv_preloaded_symbols=yes - else - libltdl_cv_preloaded_symbols=no - fi - ]) -if test yes = "$libltdl_cv_preloaded_symbols"; then - AC_DEFINE([HAVE_PRELOADED_SYMBOLS], [1], - [Define if libtool can extract symbol lists from object files.]) -fi -])# _LT_CHECK_DLPREOPEN - - -# LT_LIB_DLLOAD -# ------------- -AC_DEFUN([LT_LIB_DLLOAD], -[m4_pattern_allow([^LT_DLLOADERS$]) -LT_DLLOADERS= -AC_SUBST([LT_DLLOADERS]) - -AC_LANG_PUSH([C]) -lt_dlload_save_LIBS=$LIBS - -LIBADD_DLOPEN= -AC_SEARCH_LIBS([dlopen], [dl], - [AC_DEFINE([HAVE_LIBDL], [1], - [Define if you have the libdl library or equivalent.]) - if test "$ac_cv_search_dlopen" != "none required"; then - LIBADD_DLOPEN=-ldl - fi - libltdl_cv_lib_dl_dlopen=yes - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], - [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#if HAVE_DLFCN_H -# include -#endif - ]], [[dlopen(0, 0);]])], - [AC_DEFINE([HAVE_LIBDL], [1], - [Define if you have the libdl library or equivalent.]) - libltdl_cv_func_dlopen=yes - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], - [AC_CHECK_LIB([svld], [dlopen], - [AC_DEFINE([HAVE_LIBDL], [1], - [Define if you have the libdl library or equivalent.]) - LIBADD_DLOPEN=-lsvld libltdl_cv_func_dlopen=yes - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"])])]) -if test yes = "$libltdl_cv_func_dlopen" || test yes = "$libltdl_cv_lib_dl_dlopen" -then - lt_save_LIBS=$LIBS - LIBS="$LIBS $LIBADD_DLOPEN" - AC_CHECK_FUNCS([dlerror]) - LIBS=$lt_save_LIBS -fi -AC_SUBST([LIBADD_DLOPEN]) - -LIBADD_SHL_LOAD= -AC_CHECK_FUNC([shl_load], - [AC_DEFINE([HAVE_SHL_LOAD], [1], - [Define if you have the shl_load function.]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la"], - [AC_CHECK_LIB([dld], [shl_load], - [AC_DEFINE([HAVE_SHL_LOAD], [1], - [Define if you have the shl_load function.]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la" - LIBADD_SHL_LOAD=-ldld])]) -AC_SUBST([LIBADD_SHL_LOAD]) - -case $host_os in -darwin[[1567]].*) -# We only want this for pre-Mac OS X 10.4. - AC_CHECK_FUNC([_dyld_func_lookup], - [AC_DEFINE([HAVE_DYLD], [1], - [Define if you have the _dyld_func_lookup function.]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dyld.la"]) - ;; -beos*) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}load_add_on.la" - ;; -cygwin* | mingw* | windows* | pw32*) - AC_CHECK_DECLS([cygwin_conv_path], [], [], [[#include ]]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}loadlibrary.la" - ;; -esac - -AC_CHECK_LIB([dld], [dld_link], - [AC_DEFINE([HAVE_DLD], [1], - [Define if you have the GNU dld library.]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dld_link.la"]) -AC_SUBST([LIBADD_DLD_LINK]) - -m4_pattern_allow([^LT_DLPREOPEN$]) -LT_DLPREOPEN= -if test -n "$LT_DLLOADERS" -then - for lt_loader in $LT_DLLOADERS; do - LT_DLPREOPEN="$LT_DLPREOPEN-dlpreopen $lt_loader " - done - AC_DEFINE([HAVE_LIBDLLOADER], [1], - [Define if libdlloader will be built on this platform]) -fi -AC_SUBST([LT_DLPREOPEN]) - -dnl This isn't used anymore, but set it for backwards compatibility -LIBADD_DL="$LIBADD_DLOPEN $LIBADD_SHL_LOAD" -AC_SUBST([LIBADD_DL]) - -LIBS=$lt_dlload_save_LIBS -AC_LANG_POP -])# LT_LIB_DLLOAD - -# Old name: -AU_ALIAS([AC_LTDL_DLLIB], [LT_LIB_DLLOAD]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_DLLIB], []) - - -# LT_SYS_SYMBOL_USCORE -# -------------------- -# does the compiler prefix global symbols with an underscore? -AC_DEFUN([LT_SYS_SYMBOL_USCORE], -[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -AC_CACHE_CHECK([for _ prefix in compiled symbols], - [lt_cv_sys_symbol_underscore], - [lt_cv_sys_symbol_underscore=no - cat > conftest.$ac_ext <<_LT_EOF -void nm_test_func(){} -int main(void){nm_test_func;return 0;} -_LT_EOF - if AC_TRY_EVAL(ac_compile); then - # Now try to grab the symbols. - ac_nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) && test -s "$ac_nlist"; then - # See whether the symbols have a leading underscore. - if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then - lt_cv_sys_symbol_underscore=yes - else - if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then - : - else - echo "configure: cannot find nm_test_func in $ac_nlist" >&AS_MESSAGE_LOG_FD - fi - fi - else - echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD - fi - else - echo "configure: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.c >&AS_MESSAGE_LOG_FD - fi - rm -rf conftest* - ]) - sys_symbol_underscore=$lt_cv_sys_symbol_underscore - AC_SUBST([sys_symbol_underscore]) -])# LT_SYS_SYMBOL_USCORE - -# Old name: -AU_ALIAS([AC_LTDL_SYMBOL_USCORE], [LT_SYS_SYMBOL_USCORE]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SYMBOL_USCORE], []) - - -# LT_FUNC_DLSYM_USCORE -# -------------------- -AC_DEFUN([LT_FUNC_DLSYM_USCORE], -[AC_REQUIRE([_LT_COMPILER_PIC])dnl for lt_prog_compiler_wl -AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl for lt_cv_sys_symbol_underscore -AC_REQUIRE([LT_SYS_MODULE_EXT])dnl for libltdl_cv_shlibext -if test yes = "$lt_cv_sys_symbol_underscore"; then - if test yes = "$libltdl_cv_func_dlopen" || test yes = "$libltdl_cv_lib_dl_dlopen"; then - AC_CACHE_CHECK([whether we have to add an underscore for dlsym], - [libltdl_cv_need_uscore], - [libltdl_cv_need_uscore=unknown - dlsym_uscore_save_LIBS=$LIBS - LIBS="$LIBS $LIBADD_DLOPEN" - libname=conftmod # stay within 8.3 filename limits! - cat >$libname.$ac_ext <<_LT_EOF -[#line $LINENO "configure" -#include "confdefs.h" -/* When -fvisibility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif -int fnord () { return 42; }] -_LT_EOF - - # ltfn_module_cmds module_cmds - # Execute tilde-delimited MODULE_CMDS with environment primed for - # $module_cmds or $archive_cmds type content. - ltfn_module_cmds () - {( # subshell avoids polluting parent global environment - module_cmds_save_ifs=$IFS; IFS='~' - for cmd in @S|@1; do - IFS=$module_cmds_save_ifs - libobjs=$libname.$ac_objext; lib=$libname$libltdl_cv_shlibext - rpath=/not-exists; soname=$libname$libltdl_cv_shlibext; output_objdir=. - major=; versuffix=; verstring=; deplibs= - ECHO=echo; wl=$lt_prog_compiler_wl; allow_undefined_flag= - eval $cmd - done - IFS=$module_cmds_save_ifs - )} - - # Compile a loadable module using libtool macro expansion results. - $CC $pic_flag -c $libname.$ac_ext - ltfn_module_cmds "${module_cmds:-$archive_cmds}" - - # Try to fetch fnord with dlsym(). - libltdl_dlunknown=0; libltdl_dlnouscore=1; libltdl_dluscore=2 - cat >conftest.$ac_ext <<_LT_EOF -[#line $LINENO "configure" -#include "confdefs.h" -#if HAVE_DLFCN_H -#include -#endif -#include -#ifndef RTLD_GLOBAL -# ifdef DL_GLOBAL -# define RTLD_GLOBAL DL_GLOBAL -# else -# define RTLD_GLOBAL 0 -# endif -#endif -#ifndef RTLD_NOW -# ifdef DL_NOW -# define RTLD_NOW DL_NOW -# else -# define RTLD_NOW 0 -# endif -#endif -int main (void) { - void *handle = dlopen ("`pwd`/$libname$libltdl_cv_shlibext", RTLD_GLOBAL|RTLD_NOW); - int status = $libltdl_dlunknown; - if (handle) { - if (dlsym (handle, "fnord")) - status = $libltdl_dlnouscore; - else { - if (dlsym (handle, "_fnord")) - status = $libltdl_dluscore; - else - puts (dlerror ()); - } - dlclose (handle); - } else - puts (dlerror ()); - return status; -}] -_LT_EOF - if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then - (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null - libltdl_status=$? - case x$libltdl_status in - x$libltdl_dlnouscore) libltdl_cv_need_uscore=no ;; - x$libltdl_dluscore) libltdl_cv_need_uscore=yes ;; - x*) libltdl_cv_need_uscore=unknown ;; - esac - fi - rm -rf conftest* $libname* - LIBS=$dlsym_uscore_save_LIBS - ]) - fi -fi - -if test yes = "$libltdl_cv_need_uscore"; then - AC_DEFINE([NEED_USCORE], [1], - [Define if dlsym() requires a leading underscore in symbol names.]) -fi -])# LT_FUNC_DLSYM_USCORE - -# Old name: -AU_ALIAS([AC_LTDL_DLSYM_USCORE], [LT_FUNC_DLSYM_USCORE]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_DLSYM_USCORE], []) diff --git a/mod.ccontrol/Makefile.am b/mod.ccontrol/Makefile.am index 4bf08f1b..0daf2999 100644 --- a/mod.ccontrol/Makefile.am +++ b/mod.ccontrol/Makefile.am @@ -75,7 +75,8 @@ libccontrol_la_SOURCES = \ mod.ccontrol/LIMITSCommand.cc libccontrol_la_CXXFLAGS = -I$(top_srcdir)/db -I${top_srcdir}/include \ - -I${top_srcdir}/libgnuworld + -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libccontrol_la_LDFLAGS = -module -export-dynamic libccontrol_la_LIBADD = libgnuworldDB.la diff --git a/mod.chanfix/Makefile.am b/mod.chanfix/Makefile.am index ae20578d..ba58441b 100644 --- a/mod.chanfix/Makefile.am +++ b/mod.chanfix/Makefile.am @@ -4,6 +4,7 @@ lib_LTLIBRARIES += libchanfix.la libchanfix_la_CXXFLAGS = -I${top_srcdir}/include \ -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier \ -Werror libchanfix_la_LDFLAGS = -module -export-dynamic diff --git a/mod.clientExample/Makefile.am b/mod.clientExample/Makefile.am index fbf8d0c7..cf1aa915 100644 --- a/mod.clientExample/Makefile.am +++ b/mod.clientExample/Makefile.am @@ -4,7 +4,8 @@ lib_LTLIBRARIES += libclientExample.la libclientExample_la_SOURCES = mod.clientExample/clientExample.cc libclientExample_la_CXXFLAGS = -I${top_srcdir}/include \ - -I${top_srcdir}/libgnuworld + -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libclientExample_la_LDFLAGS = -module -export-dynamic EXTRA_DIST += mod.clientExample/clientExample.h diff --git a/mod.cloner/Makefile.am b/mod.cloner/Makefile.am index 11e7518a..fefa55f7 100644 --- a/mod.cloner/Makefile.am +++ b/mod.cloner/Makefile.am @@ -3,7 +3,8 @@ lib_LTLIBRARIES += libcloner.la libcloner_la_SOURCES = mod.cloner/cloner.cc -libcloner_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +libcloner_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libcloner_la_LDFLAGS = -module -export-dynamic EXTRA_DIST += mod.cloner/cloner.h diff --git a/mod.cloner/cloner.cc b/mod.cloner/cloner.cc index d4d37a95..f895b972 100644 --- a/mod.cloner/cloner.cc +++ b/mod.cloner/cloner.cc @@ -181,7 +181,7 @@ void cloner::OnDetach( const string& reason ) MyUplink->UnRegisterChannelEvent( xServer::CHANNEL_ALL, this ) ; MyUplink->UnRegisterTimer( cycleCloneTimer, nullptr ) ; -if( MyUplink->DetachServer( fakeServer ) ) +if( fakeServer && MyUplink->DetachServer( fakeServer ) ) { delete fakeServer ; fakeServer = nullptr ; diff --git a/mod.cloner/cloner.h b/mod.cloner/cloner.h index 2f000142..d4f97106 100644 --- a/mod.cloner/cloner.h +++ b/mod.cloner/cloner.h @@ -106,7 +106,7 @@ typedef std::list< std::string > channelListType ; < iClient* > cloneVectorType ; cloneVectorType clones ; - iServer* fakeServer ; + iServer* fakeServer = nullptr ; bool allowOpers ; diff --git a/mod.cservice/Makefile.am b/mod.cservice/Makefile.am index 381f64d8..54782798 100755 --- a/mod.cservice/Makefile.am +++ b/mod.cservice/Makefile.am @@ -5,7 +5,8 @@ lib_LTLIBRARIES += libcservice.la libcservice_la_LDFLAGS = -module -export-dynamic libcservice_la_LIBADD = libgnuworldDB.la libcservice_la_CXXFLAGS = -I$(top_srcdir)/db -I${top_srcdir}/include \ - -I${top_srcdir}/libgnuworld + -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libcservice_la_SOURCES = \ mod.cservice/banMatcher.cc \ diff --git a/mod.cservice/cservice.cc b/mod.cservice/cservice.cc index 2a8ab367..14bb738d 100644 --- a/mod.cservice/cservice.cc +++ b/mod.cservice/cservice.cc @@ -193,7 +193,7 @@ void cservice::OnShutdown(const std::string& reason) cservice::cservice(const string& args) : xClient( args ) #ifdef USE_THREAD - , threadWorker( this ) + , threadWorker() #endif { @@ -3015,38 +3015,18 @@ stringstream theQuery ; theQuery << "SELECT " << sql::channel_fields - << ",pending.manager_id,date_part('epoch', CURRENT_TIMESTAMP)::int as db_unixtime FROM " - << "channels,pending WHERE channels.last_updated >= " + << ",pending.manager_id as mngr_id,date_part('epoch', CURRENT_TIMESTAMP)::int as db_unixtime FROM " + << "channels LEFT JOIN pending ON channels.id = pending.channel_id " + << "WHERE channels.last_updated >= " << lastChannelRefresh - << " AND registered_ts <> 0" - << " AND id = channel_id" - << ends; + << " AND channels.registered_ts <> 0" ; -if( !SQLDb->Exec(theQuery, true ) ) +if( !SQLDb->Exec( theQuery, true ) ) { LOGSQL_ERROR( SQLDb ) ; return; } -// Query updates for channels which has no corresponding data in pending table (it has been cleaned up) -if (SQLDb->Tuples() <= 0) -{ - theQuery.str(""); - theQuery << "SELECT " - << sql::channel_fields - << ",date_part('epoch', CURRENT_TIMESTAMP)::int as db_unixtime FROM " - << "channels WHERE channels.last_updated >= " - << lastChannelRefresh - << " AND registered_ts <> 0" - << ends; - - if( !SQLDb->Exec(theQuery, true ) ) - { - LOGSQL_ERROR( SQLDb ) ; - return; - } -} - if (SQLDb->Tuples() <= 0) { /* Nothing to see here.. */ @@ -3078,14 +3058,22 @@ for (unsigned int i = 0 ; i < SQLDb->Tuples(); i++) /* * Not in the cache.. must be a new channel. */ + unsigned int mngr_id = (unsigned int)atoi(SQLDb->GetValue(i, "mngr_id")); + if( mngr_id == 0 ) + { + LOG_MSG( ERROR, "Channel {chan_name} has no manager assigned, skipping for now." ) + .with( "chan_name", SQLDb->GetValue(i, 1) ) + .logStructured() ; + continue; + } newChanData* newChan = new (std::nothrow) newChanData; newChan->chanName = SQLDb->GetValue(i, 1); - newChan->mngr_userId = (unsigned int)atoi(SQLDb->GetValue(i, 25).c_str()); + newChan->mngr_userId = mngr_id; newChanList.push_back(newChan); - LOG_MSG( INFO, "[DB-UPDATE]: Found new channel: {chan}" ) - .with( "chan", newChan->chanName ) + LOG_MSG( INFO, "[DB-UPDATE]: Found new channel: {chan_name}" ) + .with( "chan_name", newChan->chanName ) .logStructured() ; newchans++; } @@ -3095,8 +3083,10 @@ if (!newChanList.empty()) for (vector::iterator itr = newChanList.begin(); itr != newChanList.end(); itr++) { sqlUser* mngrUser = getUserRecord((*itr)->mngr_userId); - if (!sqlRegisterChannel(getInstance(), mngrUser, (*itr)->chanName.c_str())) - LOG( ERROR, "FAILED to sqlRegisterChannel" ) ; + if (!sqlRegisterChannel(getInstance(), mngrUser, (*itr)->chanName)) + LOG_MSG( ERROR, "FAILED to sqlRegisterChannel for {chan_name} with manager {}", (*itr)->mngr_userId ) + .with( "chan_name", (*itr)->chanName ) + .logStructured() ; } newChanList.clear(); } @@ -3535,8 +3525,8 @@ void cservice::updatePrometheusMetrics() if( !prometheus) return ; /* Update the prometheus metrics */ - prometheus->setGauge( "gnuworld_memory_usage_bytes", getMemoryUsage() ) ; - prometheus->setGauge( "gnuworld_cpu_usage_seconds", getCPUTime() ) ; + prometheus->setGauge( "memory_usage", getMemoryUsage() ) ; + prometheus->setGauge( "cpu_usage", getCPUTime() ) ; prometheus->setGauge( "irc_clients", Network->clientList_size() ) ; prometheus->setGauge( "irc_channels", Network->channelList_size() ) ; prometheus->setGauge( "irc_servers", Network->serverList_size() ) ; @@ -4090,10 +4080,9 @@ bool cservice::sqlRegisterChannel(iClient* theClient, sqlUser* mngrUsr, const st if (!welcomeNewChanMessage.empty()) Notice(newChan->getName(), TokenStringsParams(welcomeNewChanMessage.c_str(), newChan->getName().c_str()).c_str()); - //Set a welcome topic of the new channel, only if the actual topic is empty + //Set a welcome topic of the new channel, only if the actual topic is empty and the channel has not been registered with the register command #ifdef TOPIC_TRACK - if (!welcomeNewChanTopic.empty()) - if (tmpChan && tmpChan->getTopic().empty()) + if (tmpChan && tmpChan->getTopic().empty() && !welcomeNewChanTopic.empty() && theClient == getInstance()) Topic(tmpChan, welcomeNewChanTopic); #endif diff --git a/mod.dronescan/Makefile.am b/mod.dronescan/Makefile.am index f3d9f2d6..564071ff 100644 --- a/mod.dronescan/Makefile.am +++ b/mod.dronescan/Makefile.am @@ -4,6 +4,7 @@ libdronescan_la_LDFLAGS = -module -export-dynamic libdronescan_la_LIBADD = libgnuworldDB.la libdronescan_la_CXXFLAGS = -I$(top_srcdir)/db \ -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier \ -I${top_srcdir}/include libdronescan_la_SOURCES = \ diff --git a/mod.gnutest/Makefile.am b/mod.gnutest/Makefile.am index d8ec37f6..7f01cd40 100644 --- a/mod.gnutest/Makefile.am +++ b/mod.gnutest/Makefile.am @@ -3,7 +3,8 @@ lib_LTLIBRARIES += libgnutest.la libgnutest_la_SOURCES = mod.gnutest/gnutest.cc -libgnutest_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +libgnutest_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libgnutest_la_LDFLAGS = -module -export-dynamic EXTRA_DIST += mod.gnutest/gnutest.h diff --git a/mod.nickserv/Makefile.am b/mod.nickserv/Makefile.am index 4a776cbb..e9c9c446 100644 --- a/mod.nickserv/Makefile.am +++ b/mod.nickserv/Makefile.am @@ -24,7 +24,8 @@ libnickserv_la_SOURCES = \ mod.nickserv/sqlUser.cc libnickserv_la_CXXFLAGS = -I$(top_srcdir)/db \ - -I${top_srcdir}/include -I${top_srcdir}/libgnuworld + -I${top_srcdir}/include -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier EXTRA_DIST += \ mod.nickserv/levels.h \ diff --git a/mod.openchanfix/Makefile.am b/mod.openchanfix/Makefile.am index c0ab977d..34ecf0e5 100644 --- a/mod.openchanfix/Makefile.am +++ b/mod.openchanfix/Makefile.am @@ -55,6 +55,7 @@ libchanfix_la_SOURCES = \ libchanfix_la_CXXFLAGS = -I$(top_srcdir)db -I${top_srcdir}/include \ -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier \ $(threadLib) libchanfix_la_LDFLAGS = -module -export-dynamic @BOOST_THREAD_LIB@ libchanfix_la_LIBADD = libgnuworldDB.la diff --git a/mod.scanner/Makefile.am b/mod.scanner/Makefile.am index d3ab1bb3..3c4441f1 100644 --- a/mod.scanner/Makefile.am +++ b/mod.scanner/Makefile.am @@ -9,7 +9,8 @@ libscanner_la_SOURCES = \ mod.scanner/wingateModule.cc libscanner_la_LDFLAGS = -module -export-dynamic libscanner_la_CXXFLAGS = -I$(top_srcdir)/include \ - -I$(top_srcdir)/libgnuworld + -I$(top_srcdir)/libgnuworld \ + -I$(top_srcdir)/libnotifier EXTRA_DIST += \ mod.scanner/dbThread.h \ diff --git a/mod.snoop/Makefile.am b/mod.snoop/Makefile.am index f4afce77..6a3c0755 100644 --- a/mod.snoop/Makefile.am +++ b/mod.snoop/Makefile.am @@ -4,7 +4,8 @@ lib_LTLIBRARIES += libsnoop.la libsnoop_la_SOURCES = mod.snoop/snoop.cc libsnoop_la_CXXFLAGS = -I${top_srcdir}/include \ - -I${top_srcdir}/libgnuworld + -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libsnoop_la_LDFLAGS = -module -export-dynamic EXTRA_DIST += mod.snoop/snoop.h diff --git a/mod.stats/Makefile.am b/mod.stats/Makefile.am index 8d9f570f..67ee61c8 100644 --- a/mod.stats/Makefile.am +++ b/mod.stats/Makefile.am @@ -3,7 +3,8 @@ lib_LTLIBRARIES += libstats.la libstats_la_SOURCES = mod.stats/stats.cc -libstats_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld +libstats_la_CXXFLAGS = -I${top_srcdir}/include -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libstats_la_LDFLAGS = -module -export-dynamic EXTRA_DIST += mod.stats/stats.h diff --git a/src/Makefile.am b/src/Makefile.am index 46dcbc65..02fa43de 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -18,10 +18,11 @@ libgnuworldcore_la_SOURCES = \ src/server_events.cc \ src/server_glines.cc \ src/server_timers.cc -libgnuworldcore_la_CXXFLAGS = -I${top_srcdir}/include \ - -I${top_srcdir}/libgnuworld +libgnuworldcore_la_CXXFLAGS = -I${top_srcdir}/include \ + -I${top_srcdir}/libgnuworld \ + -I${top_srcdir}/libnotifier libgnuworldcore_la_LDFLAGS = -export-dynamic -libgnuworldcore_la_LIBADD = libgnuworld.la $(LIBLTDL) +libgnuworldcore_la_LIBADD = libgnuworld.la libnotifier.la $(LIBLTDL) bin_PROGRAMS = gnuworld gnuworld_SOURCES = src/main.cc diff --git a/src/main.cc b/src/main.cc index f80998f2..3a42ebca 100644 --- a/src/main.cc +++ b/src/main.cc @@ -105,42 +105,8 @@ clog << "see the files named COPYING." << endl ; clog << endl ; } -// These functions are used to duplicate/free -// argv for reconnection of the server. -// For some reason gcc 3.3 won't let me declare -// argv as const char** -char** dupArray( int argc, char** argv ) -{ -assert( argc >= 1 ) ; - -// Put a trailing NULL as the last element of the array -char** retMe = new char*[ argc + 1 ] ; -for( int i = 0 ; i < argc ; ++i ) - { - retMe[ i ] = new char[ strlen( argv[ i ] ) + 1 ] ; - strcpy( retMe[ i ], argv[ i ] ) ; - } -retMe[ argc ] = 0 ; -return retMe ; -} - -void releaseDup( int argc, char** releaseMe ) -{ -assert( argc >= 1 ) ; -assert( releaseMe != 0 ) ; - -for( int i = 0 ; i < argc ; ++i ) - { - delete[] releaseMe[ i ] ; - } -delete[] releaseMe ; -} - int main( int argc, char** argv ) { -// output gnu information -gnu() ; - // This is done to intialize the hasher md5 dummy ; @@ -156,54 +122,112 @@ if( 0 == Signal::getInstance() ) // Seed the random number generator ::srand( ::time( 0 ) ) ; -#ifdef DAEMON - /* fork into background here */ - if (fork()) +/* Parse command line arguments */ +bool verbose = false ; +bool doDebug = true ; +bool logSocket = true ; +std::string elogFileName = "debug.log" ; +std::string socketFileName = "socket.log" ; +std::string configFileName = CONFFILE ; +std::string simFileName ; + +int c ; +while( ( c = getopt( argc, argv, "cd:Df:l:Lhs:" ) ) != -1 ) { - fprintf(stdout, "%s: forked into background\n", argv[0]); - exit(0); + switch( c ) + { + case 'c': + verbose = true ; + break ; + case 'd': + doDebug = true ; + elogFileName = optarg ; + break ; + case 'D': + doDebug = false ; + break ; + case 'f': + configFileName = optarg ; + break ; + case 'h': + usage( argv[ 0 ] ) ; + ::exit( 0 ) ; + case 'l': + logSocket = true ; + socketFileName = optarg ; + break ; + case 'L': + logSocket = false ; + break ; + case 's': + simFileName = optarg ; + clog << "*** Running in simulation mode..." << endl ; + break ; + case ':': + clog << "*** Missing parameter\n" ; + usage( argv[ 0 ] ) ; + ::exit( 0 ) ; + case '?': + // Unrecognized option + usage( argv[ 0 ] ) ; + ::exit( 0 ) ; + default: + clog << "Unknown option " << static_cast(c) << endl ; + usage( argv[ 0 ] ) ; + ::exit( 0 ) ; + } } - setsid(); - if (fork()) - exit(0); - /* redirect stdin, stdout, stderr to null */ - freopen("/dev/null", "r", stdin); - freopen("/dev/null", "w", stdout); - freopen("/dev/null", "w", stderr); -#endif -bool autoConnect = true ; -while( autoConnect ) +/* fork into background only if not in verbose mode */ +if( !verbose ) { - // getopt() mutates argv, so only pass a copy so - // we can call getopt() again with the same option set - char** dupArgv = dupArray( argc, argv ) ; - - // Allocate a new instance of the xServer - gnuworld::xServer* theServer = - new (std::nothrow) gnuworld::xServer( argc, dupArgv ) ; - assert( theServer != 0 ) ; + if( fork() ) + { + clog << argv[0] << ": forked into background" ; + ::exit( 0 ) ; + } + setsid() ; + if( fork() ) + ::exit( 0 ) ; + } - // Write out the pid - // TODO: This will have to be updated when running - // in background. +{ +std::ofstream pidFile( "gnuworld.pid", std::ios::trunc | std::ios::out ) ; +if( !pidFile ) { - std::ofstream pidFile( "gnuworld.pid", std::ios::trunc | - std::ios::out ) ; - if( !pidFile ) - { - clog << "Unable to open pid file: gnuworld.pid" + clog << "Unable to open pid file: gnuworld.pid" << endl ; + return -1 ; + } - delete theServer ; theServer = 0 ; - return -1 ; - } - - pidFile << getpid() +pidFile << getpid() << endl ; - pidFile.close() ; - } // pidFile +pidFile.close() ; +} // pidFile + +/* Redirect stdin, stdout, stderr to null when running in background */ +if( !verbose ) + { + clog << " with PID: " << getpid() << endl ; + freopen( "/dev/null", "r", stdin ) ; + freopen( "/dev/null", "w", stdout ) ; + freopen( "/dev/null", "w", stderr ) ; + } + +// Output gnu information +gnu() ; + +bool autoConnect = true ; +while( autoConnect ) + { + // Allocate a new instance of the xServer + gnuworld::xServer* theServer = + new (std::nothrow) gnuworld::xServer( + verbose, doDebug, logSocket, + elogFileName, socketFileName, + configFileName, simFileName ) ; + assert( theServer != 0 ) ; theServer->run() ; @@ -213,75 +237,30 @@ while( autoConnect ) delete theServer ; theServer = 0 ; - releaseDup( argc, dupArgv ) ; - dupArgv = 0 ; - ::sleep( 10 ) ; } // while( autoConnect ) return 0 ; } -xServer::xServer( int argc, char** argv ) +xServer::xServer( bool verbose_arg, bool doDebug_arg, bool logSocket_arg, + const std::string& elogFileName_arg, + const std::string& socketFileName_arg, + const std::string& configFileName_arg, + const std::string& simFileName_arg ) : eventList( EVT_NOOP ), - elogFileName( "debug.log" ), - socketFileName( "socket.log" ), - configFileName( CONFFILE ) + verbose( verbose_arg ), + doDebug( doDebug_arg ), + logSocket( logSocket_arg ), + elogFileName( elogFileName_arg ), + socketFileName( socketFileName_arg ), + configFileName( configFileName_arg ), + simFileName( simFileName_arg ) { -logSocket = true ; -verbose = false ; -doDebug = true ; - -std::cout << "Before configuration" << endl; #ifdef ENABLE_LOG4CPLUS log4cplus::PropertyConfigurator::doConfigure("logging.properties"); #endif -int c; -while ((c = getopt(argc, argv, "cd:Df:l:Lhs:")) != -1) { - switch (c) { - case 'c': - verbose = true; - break; - case 'd': - doDebug = true; - elogFileName = optarg; - break; - case 'D': - doDebug = false; - break; - case 'f': - configFileName = optarg; - break; - case 'h': - usage(argv[0]); - ::exit(0); - case 'l': - logSocket = true; - socketFileName = optarg; - break; - case 'L': - logSocket = false; - break; - case 's': - simFileName = optarg; - clog << "*** Running in simulation mode..." << endl; - break; - case ':': - clog << "*** Missing parameter\n"; - usage(argv[0]); - ::exit(0); - case '?': - // Unrecognized option - usage(argv[0]); - ::exit(0); - default: - clog << "Unknown option " << static_cast(c) << endl; - usage(argv[0]); - ::exit(0); - } -} - startLogging(false) ; // Sets up the server internals initializeSystem() ; diff --git a/src/server_connection.cc b/src/server_connection.cc index 5bf84697..0f3a0c0c 100644 --- a/src/server_connection.cc +++ b/src/server_connection.cc @@ -272,6 +272,7 @@ if( verbose ) if( logSocket ) { socketFile << ::time(0) << " " << logLine ; + socketFile.flush() ; } Process( inputCharBuffer ) ;