Hi dovecot list, On Thu, Nov 13, 2014 at 07:45:54PM +0200, Baruch Siach wrote:
Static build of dovecot fails because src/lib/module-dir.c refers to MODULE_SUFFIX that is undefined when building statically. This least to the following build failure:
module-dir.c: In function 'module_file_get_name': module-dir.c:624:20: error: 'MODULE_SUFFIX' undeclared (first use in this function) p = strstr(fname, MODULE_SUFFIX); ^
Ping? For reference, the problem was observed by the Buildroot autobuilder: http://autobuild.buildroot.net/results/c68/c6844bbffff1cd4f738a5fced011d28f7... baruch
The following somewhat inelegant patch fixes the problem.
diff -Nuar dovecot-2.2.15-orig/src/lib/module-dir.c dovecot-2.2.15/src/lib/module-dir.c --- dovecot-2.2.15-orig/src/lib/module-dir.c 2014-10-18 00:10:15.000000000 +0300 +++ dovecot-2.2.15/src/lib/module-dir.c 2014-11-13 19:27:29.417786313 +0200 @@ -621,7 +621,11 @@ if (*p == '_') fname = p + 1;
+#ifdef MODULE_SUFFIX p = strstr(fname, MODULE_SUFFIX); +#else + p = NULL; +#endif if (p == NULL) return fname;
-- http://baruch.siach.name/blog/ ~. .~ Tk Open Systems =}------------------------------------------------ooO--U--Ooo------------{= - baruch@tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -