报错如下:
gdate.c:2497:7: error: format not a string literal, format string not checked [-Werror=format-nonliteral]
tmplen = strftime (tmpbuf, tmpbufsize, locale_format, &tm);
解决方法:打开gdate.c文件(在glib目录下),找到调用strftime函数的2497行,在strftime前后加上如下预处理命令:
#pragma GCC diagnostic push
#pragma GCC diagnostic ign