From 7ec2ce8fd7d30a536823ef9e08a3dad80ce76d4e Mon Sep 17 00:00:00 2001 From: dequis Date: Wed, 10 Jan 2018 00:05:23 -0300 Subject: Remove MSN. Use the skypeweb purple plugin instead. RIP As per http://ismsndeadyet.com/ all versions up to MSNP22 died a few months ago. We had a MSNP21 implementation, bought us two extra years. Implementing MSNP24 is technically possible but also pointless given skypeweb, and the authentication requires some fairly messed up crypto and legacy old-skype-protocol servers. For a long time I tried to reverse a potentially simpler method, and got fairly close, but never completed that. I haven't done any attempts to continue it in the last year, so I'm fine with giving up at this point. --- configure | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'configure') diff --git a/configure b/configure index e2357815..3f1769df 100755 --- a/configure +++ b/configure @@ -32,7 +32,6 @@ configure_args="$@" # If the user sets one of these to 1, purple won't disable them. # Otherwise, if it's still default-on, it gets included in normal builds, # but not purple ones. -msn="default-on" jabber="default-on" oscar="default-on" @@ -129,7 +128,6 @@ Option Description Default --verbose=0/1 Disable/enable verbose build $verbose ---msn=0/1 Disable/enable MSN part $msn --jabber=0/1 Disable/enable Jabber part $jabber --oscar=0/1 Disable/enable Oscar part (ICQ, AIM) $oscar --twitter=0/1 Disable/enable Twitter part $twitter @@ -845,7 +843,6 @@ EOF protoobjs=$protoobjs'purple_mod.o ' # only disable these if the user didn't enable them explicitly - [ "$msn" = "default-on" ] && msn=0 [ "$jabber" = "default-on" ] && jabber=0 [ "$oscar" = "default-on" ] && oscar=0 @@ -868,14 +865,6 @@ case "$CC" in done esac -if [ "$msn" = 0 ]; then - echo '#undef WITH_MSN' >> config.h -else - echo '#define WITH_MSN' >> config.h - protocols=$protocols'msn ' - protoobjs=$protoobjs'msn_mod.o ' -fi - if [ "$jabber" = 0 ]; then echo '#undef WITH_JABBER' >> config.h else -- cgit v1.2.3 From a949b43ed657154d4ff8492bbdb16202a1a9f22d Mon Sep 17 00:00:00 2001 From: dequis Date: Sun, 11 Mar 2018 16:33:55 -0300 Subject: Remove old skype plugin. Use the skypeweb purple plugin instead. RIP This plugin relied on the skype linux client, which doesn't work anymore. During login it just does exit(0) for mysterious reasons. I guess that's the server trying to say that it's not supported. This is officially dead now after a few years of kinda-almost-working. --- configure | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 3f1769df..643e70f1 100755 --- a/configure +++ b/configure @@ -46,7 +46,6 @@ gcov=0 asan=0 plugins=1 otr=0 -skype=0 events=glib ssl=auto @@ -147,8 +146,6 @@ Option Description Default --plugins=0/1 Disable/enable plugins support $plugins --otr=0/1/auto/plugin Disable/enable OTR encryption support $otr ---skype=0/1/plugin - Disable/enable Skype support $skype --events=... Event handler (glib, libevent) $events --ssl=... SSL library to use (gnutls, nss, openssl, auto) @@ -752,16 +749,6 @@ elif [ "$otr" = "plugin" ]; then echo 'OTR_PI=otr.so' >> Makefile.settings fi -if [ "$skype" = "1" -o "$skype" = "plugin" ]; then - if [ "$arch" = "Darwin" ]; then - echo "SKYPEFLAGS=-dynamiclib -undefined dynamic_lookup" >> Makefile.settings - else - echo "SKYPEFLAGS=-fPIC -shared" >> Makefile.settings - fi - echo 'SKYPE_PI=skype.so' >> Makefile.settings - protocols_mods="$protocol_mods skype(plugin)" -fi - if [ -z "$PYTHON" ]; then PYTHON=python fi -- cgit v1.2.3 From 1de945b2b2ad5506f7909ced21f923ea8a62a09c Mon Sep 17 00:00:00 2001 From: dequis Date: Mon, 19 Mar 2018 12:39:57 -0300 Subject: configure: Add -Wformat -Werror=format-security to default CFLAGS Matches debian build scripts. Also expands the condition to gcc or clang. I'd rather remove this, apparently it exists because some opensolaris compiler didn't have -Wall which seems absurd to me, but whatever. --- configure | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 643e70f1..093fbf3d 100755 --- a/configure +++ b/configure @@ -334,9 +334,9 @@ else fi echo "CC=$CC" >> Makefile.settings; -if echo $CC | grep -qw gcc; then +if echo $CC | grep -qw 'gcc\|clang'; then # Apparently -Wall is gcc-specific? - echo CFLAGS+=-Wall >> Makefile.settings + echo CFLAGS+=-Wall -Wformat -Werror=format-security >> Makefile.settings fi if [ -z "$LD" ]; then -- cgit v1.2.3 From 0d2cd10fba86011a01a1c52c0db2e98660efa1de Mon Sep 17 00:00:00 2001 From: dequis Date: Mon, 26 Mar 2018 13:26:56 -0300 Subject: Write backtrace to /var/lib/bitlbee/crash.log on SIGSEGV Async-signal-safe code is very restricted (nothing that may call malloc indirectly), so this code tries its best to show meaningful stuff, but the output is still fairly raw. The contents of the log file are: - BITLBEE_VERSION, BITLBEE_CONFIGURE_ARGS - Backtrace as generated by backtrace()/backtrace_symbols_fd() - A small help text explaining how to get more useful symbol names - Memory maps (/proc/self/maps), which also mentions loaded plugins The backtrace() function is a GNU extension, /proc/ is a linux thing. Non-glibc platforms (such as musl) won't show anything, non-linux platforms will skip the memory maps when /proc/self/maps fails to open. I'd like to include timestamps, but I can't find a safe way to format them. Even turning raw unix timestamps to strings is hard. Fun stuff. I used the config directory because it's the only place we can be sure we can write to. The filename is hardcoded for the same reason there are no timestamps. --- configure | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) (limited to 'configure') diff --git a/configure b/configure index 093fbf3d..b578164f 100755 --- a/configure +++ b/configure @@ -484,6 +484,16 @@ int main() } ' +BACKTRACE_TESTCODE=' +#include + +int main() +{ + void *trace[16]; + return backtrace(trace, 16); +} +' + detect_resolv_dynamic() { case "$arch" in @@ -581,6 +591,19 @@ detect_nameser_has_ns_types() return $ret } +detect_backtrace() +{ + TMPFILE=$(mktemp /tmp/bitlbee-configure.XXXXXX) + ret=1 + echo "$BACKTRACE_TESTCODE" | $CC -o $TMPFILE -x c - >/dev/null 2>/dev/null + if [ "$?" = "0" ]; then + ret=0 + fi + + rm -f $TMPFILE + return $ret +} + if [ "$ssl" = "auto" ]; then detect_gnutls if [ "$ret" = "0" ]; then @@ -646,6 +669,10 @@ else echo 'Insufficient resolv routines. Jabber server must be set explicitly' fi +if detect_backtrace; then + echo '#define HAVE_BACKTRACE' >> config.h + echo '#define CRASHFILE "'$config'crash.log"' >> config.h +fi STORAGES="xml" -- cgit v1.2.3