* sending the startup-problem-message now does work.
authorWilfried Göesgens <willi@citadel.org>
Tue, 4 Sep 2007 20:25:20 +0000 (20:25 +0000)
committerWilfried Göesgens <willi@citadel.org>
Tue, 4 Sep 2007 20:25:20 +0000 (20:25 +0000)
citadel/debian/rules
citadel/mk_module_init.sh
citadel/serv_extensions.c

index 0b4a8020b86259eca4f684a57b18700dec53572b..a3dfde6e9210a7f6d5a363a64f2844aa4cfcc398 100755 (executable)
@@ -10,11 +10,12 @@ DEB_DESTDIR = $(CURDIR)/debian/tmp
 
 CFLAGS = -Wall -g
 
-ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
        CFLAGS += -O0 -ggdb -rdynamic -D_GNU_SOURCE -MD -MP 
        LDFLAGS += -pg 
        SERVER_LDFLAGS += -lm
 #      SERVER_LDFLAGS += -pg
+       EXTRA_ARGS = --with-profiling --with-backtrace
 else
        CFLAGS += -O2
 endif
@@ -39,7 +40,7 @@ configure-stamp:
                --with-ldap \
                --with-libical \
                --with-libsieve \
-               --enable-debug
+               --enable-debug $(EXTRA_ARGS)
 
        touch configure-stamp
 
index fa2782c06a9f6061f2704977fdd356676dc66a64..49112c57ef5b530cb4e995cf9ff00b7f364e1c36 100755 (executable)
@@ -43,7 +43,7 @@ $ECHO $MINUS_e "#include \"modules_init.h\"\n" >> $C_FILE
 $ECHO $MINUS_e "#include \"sysdep_decls.h\"\n" >> $C_FILE
 $ECHO $MINUS_e "\n\n\n" >> $C_FILE
 $ECHO $MINUS_e "void LogPrintMessages(long err);\n" >> $C_FILE
-$ECHO $MINUS_e "static long DetailErrorFlags;\n" >> $C_FILE
+$ECHO $MINUS_e "extern long DetailErrorFlags;\n" >> $C_FILE
 $ECHO $MINUS_e "\n\n\n" >> $C_FILE
 
 $ECHO $MINUS_e "void initialise_modules (void)\n" >> $C_FILE
index 69054c7e5f6b8e8967835612468bd16a4260b421..ced004cc4859c9b8b7074820cae426162bd219dd 100644 (file)
@@ -61,7 +61,7 @@ static char *errormessages = NULL;
 size_t nSizErrmsg = 0;
 
 
-static long   DetailErrorFlags;
+long   DetailErrorFlags;
 
 char *ErrSubject = "Startup Problems";
 char *ErrGeneral = "Citadel had trouble on starting up. %s This means, citadel won't be the service provider for a specific service you configured it to.\n\n"
@@ -107,6 +107,8 @@ void LogPrintMessages(long err)
 
        snprintf(Message, n * SIZ, ErrGeneral, Short, Where, List, Hint, DetailList);
 
+       lprintf(0,Message);
+       lprintf(0,ErrSubject);
        quickie_message("Citadel", NULL, NULL, AIDEROOM, Message, FMT_FIXED, ErrSubject);
        if (errormessages!=NULL) free (errormessages);
        errormessages = NULL;