Hello, Compilation fails under FreeBSD 9.3 (however, under 10.3 build completes without problems). gmake[4]: Entering directory '/mnt/tdata/miniserver/ports/usr/ports/lang/mono/work/mono-4.4.2/eglib/test' CC test_eglib-test.o CC test_eglib-driver.o CC test_eglib-hashtable.o CC test_eglib-string-util.o CC test_eglib-string.o CC test_eglib-slist.o CC test_eglib-sizes.o CC test_eglib-ptrarray.o CC test_eglib-list.o CC test_eglib-array.o CC test_eglib-fake.o CC test_eglib-path.o CC test_eglib-queue.o CC test_eglib-shell.o CC test_eglib-spawn.o CC test_eglib-timer.o CC test_eglib-file.o CC test_eglib-pattern.o CC test_eglib-dir.o CC test_eglib-markup.o CC test_eglib-unicode.o CC test_eglib-utf8.o CC test_eglib-endian.o CC test_eglib-module.o CC test_eglib-memory.o CCLD test-eglib ../src/.libs/libeglib.a(libeglib_la-gunicode.o): In function `monoeg_g_get_charset': /mnt/tdata/miniserver/ports/usr/ports/lang/mono/work/mono-4.4.2/eglib/src/gunicode.c:220: undefined reference to `locale_charset' /mnt/tdata/miniserver/ports/usr/ports/lang/mono/work/mono-4.4.2/eglib/src/gunicode.c:220: undefined reference to `locale_charset' /mnt/tdata/miniserver/ports/usr/ports/lang/mono/work/mono-4.4.2/eglib/src/gunicode.c:220: undefined reference to `locale_charset' clang: error: linker command failed with exit code 1 (use -v to see invocation) gmake[4]: *** [Makefile:407: test-eglib] Error 1 gmake[4]: Leaving directory '/mnt/tdata/miniserver/ports/usr/ports/lang/mono/work/mono-4.4.2/eglib/test' gmake[3]: *** [Makefile:428: all-recursive] Error 1 gmake[3]: Leaving directory '/mnt/tdata/miniserver/ports/usr/ports/lang/mono/work/mono-4.4.2/eglib' gmake[2]: *** [Makefile:359: all] Error 2 gmake[2]: Leaving directory '/mnt/tdata/miniserver/ports/usr/ports/lang/mono/work/mono-4.4.2/eglib' gmake[1]: *** [Makefile:513: all-recursive] Error 1 gmake[1]: Leaving directory '/mnt/tdata/miniserver/ports/usr/ports/lang/mono/work/mono-4.4.2' gmake: *** [Makefile:442: all] Error 2 ===> Compilation failed unexpectedly. Try to set MAKE_JOBS_UNSAFE=yes and rebuild before reporting the failure to the maintainer. *** [do-build] Error code 1 Stop in /usr/ports/lang/mono.
This affects more than just you. I need this to work to include mono 4.4 in the Emby plugin for FreeNAS 9.10
The fix listed in the following stackexchange page seems to work: http://serverfault.com/questions/249411/mono-undefined-reference-to-locale-charset Changing the "#define HAVE_LOCALCHARSET_H 1" line under eglib/config.h after configure to "#undef HAVE_LOCALCHARSET_H" and resuming the build completes successfully under FreeBSD 9.
(In reply to yani from comment #2) The fix you linked worked for me. As a workaround I added.. "@${REINPLACE_CMD} 's/^#define HAVE_LOCALCHARSET_H 1/#undef HAVE_LOCALCHARSET_H/' ${WRKSRC}/eglib/config.h" to the 'post-configure' task
Created attachment 173743 [details] Diff to fix the build problem on FreeBSD 9.
just a suggestion, maybe you can check the OS version and only do this on freebsd 9.X
Problem reproduced, working on it.
A commit references this bug: Author: romain Date: Wed Aug 17 08:23:38 UTC 2016 New revision: 420322 URL: https://svnweb.freebsd.org/changeset/ports/420322 Log: Fix build on FreeBSD 9.3 PR: 211696 Submitted by: yani@pi-greece.eu Reported by: pkg-fallout Changes: head/lang/mono/Makefile
Committed, with version check.