media-gfx/fontforge-20110222-r1 fails to compile on x86-macos. First problem is that pthread related function is used without ifdef macro in gioftp.c. Second problem after fixing the first is undefined symbols.
Created attachment 294559 [details] modified ebuild Here is my attempt to solve the problems.
Created attachment 294561 [details, diff] fontoforge-20110222-gioftp-pthread.patch patch to fix the first problem.
Not sure actually skipping locking is a good fix. Besides, you're on Darwin, pthread_mutex_lock should exist, the code probably forgot a #include <pthread.h>.
(In reply to comment #3) > Not sure actually skipping locking is a good fix. Besides, you're on Darwin, > pthread_mutex_lock should exist, the code probably forgot a #include > <pthread.h>. I understand your worry. But, if I have pthread.h and configure detects it, then my patch has no effect, doen't it? The pthread.h is actually included in gioP.h with #ifdef HAVE_PTHREAD_H, which is included in gioftpP.h, which is included in gioftp.c. Well, OK, I will try to read configure that seems to fail to detect pthread on Darwin.
Ah, yes. If pthread is included conditionally, then they can't rely on its functions, indeed. However, in your case pthread should be there, so you don't need to fix this problem for upstream ;)
I found that the detection failure was caused by my mistakenly set LIBS. So, yes, we can ignore the patch. The only problem for us is the linker errors.
what linker errors?
Created attachment 294705 [details] log (original ebuild) showing the failure at gioftp.c
Created attachment 294707 [details] log (after only patch) I know the patch is unnecessary but, this shows the undefined symbols.
-pthread
Two logs shows how builds fail. On the way to reproduce the log (again), I recognize that the strange LIBS problem is caused in configure. If configure is run without --with-python-lib, it tries to guess what it should be; the code PyLib=`$python_prog -c "import distutils.sysconfig ; print(distutils.sysconfig.get_config_var('LIBPL') + '/' + distutils.sysconfig.get_config_var('LDLIBRARY'))"` is used and detect, at least on my environment, the messing path: $ python -c "import distutils.sysconfig ; print(distutils.sysconfig.get_config_var('LIBPL') + '/' + distutils.sysconfig.get_config_var('LDLIBRARY'))" /Users/tetsushi/Gentoo/usr/lib/python2.7/config/ On time I wrote the last comment, I stopped using the patch on gioftp.c but continued to use other part of the modified ebuild, which pass --with-python-lib, luckily avoiding the configure's misbehavior. It's an upstream bug that can be ignored, if we set --with-python-lib as in the attached ebuild.
Created attachment 313711 [details] modified ebuild
Please re-open this if the issue occurs with current versions of fontforge.