improve debug infomation, add time/file/line info. #34

merged 1 commit into from Feb 27, 2014

2 participants


No description provided.



Alibaba member


@kongjian kongjian merged commit 0cfb0e7 into alibaba:master Feb 27, 2014
Alibaba member



方便提供下出错信息吗? 我的环境如下,没有问题
ubuntu@ubuntu:~/tsar$ uname -a
Linux ubuntu 3.2.0-58-generic-pae #88-Ubuntu SMP Tue Dec 3 18:00:02 UTC 2013 i686 i686 i386 GNU/Linux

ubuntu@ubuntu:~/tsar$ make clean
for i in modules src; do cd $i;make clean;cd ..; done
make[1]: Entering directory /home/ubuntu/tsar/modules'
rm -f *.so;
make[1]: Leaving directory
make[1]: Entering directory /home/ubuntu/tsar/src'
rm -rf *.o tsar
make[1]: Leaving directory

ubuntu@ubuntu:~/tsar$ make
for i in modules src; do make -C $i; done
make[1]: Entering directory /home/ubuntu/tsar/modules'
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swap.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_partition.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_cpu.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_mem.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_lvs.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_haproxy.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_traffic.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_squid.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_load.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_tcp.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_udp.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_tcpx.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_proc.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_apache.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_pcsw.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_io.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_nginx.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_cgblkio.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_cgcpu.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_cgmem.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_ncpu.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_rndc.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_ts_cache.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_ts_client.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_ts_err.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_ts_os.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_ts_storage.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_ts_conn.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_ts_codes.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_code.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_store.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_fwd.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_domain.c -o
mod_swift_domain.c: In function ‘parse_swift_code_info’:
mod_swift_domain.c:171:21: warning: variable ‘len’ set but not used [-Wunused-but-set-variable]
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_swapdir.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_purge.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_tcmalloc.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_sys.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_esi.c -o
mod_swift_esi.c: In function ‘parse_swift_code_info’:
mod_swift_esi.c:186:21: warning: variable ‘len’ set but not used [-Wunused-but-set-variable]
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_balancer.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_swift_blc_fwd.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_tmd.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_percpu.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_rpi.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_tcprt.c -o
mod_tcprt.c: In function ‘prepare_data’:
mod_tcprt.c:47:14: warning: ignoring return value of ‘write’, declared with attribute warn_unused_result [-Wunused-result]
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_shell.c -o
gcc -I../include -Wall -fPIC --shared -g -O2 -Wno-strict-aliasing mod_nginx_domain.c -o
make[1]: Leaving directory
make[1]: Entering directory /home/ubuntu/tsar/src'
gcc -o config.o -c -I../include -g -O2 -Wall config.c
gcc -o debug.o -c -I../include -g -O2 -Wall debug.c
gcc -o framework.o -c -I../include -g -O2 -Wall framework.c
gcc -o tsar.o -c -I../include -g -O2 -Wall tsar.c
gcc -o output_file.o -c -I../include -g -O2 -Wall output_file.c
gcc -o output_print.o -c -I../include -g -O2 -Wall output_print.c
gcc -o output_db.o -c -I../include -g -O2 -Wall output_db.c
gcc -o output_nagios.o -c -I../include -g -O2 -Wall output_nagios.c
gcc -o common.o -c -I../include -g -O2 -Wall common.c
gcc config.o debug.o framework.o tsar.o output_file.o output_print.o output_db.o output_nagios.o common.o -o tsar -I../include -g -Wall -ldl -rdynamic
make[1]: Leaving directory

Alibaba member

debug.c:38: warning: field precision should have type ‘int’, but argument 3 has type ‘size_t’

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment