User loginNavigation | 
   
SWI-Prolog FFI Problem: Getting Prolog and C to work together on MacOS?Hi, It seems that there are some issues with the foreign function interface specifically on MacOS. The Prolog manual has a very nice example of how to use FFI with C (http://gollem.science.uva.nl/SWI-Prolog/Manual/foreignxmp.html)... which this doesn't work for me on MacOS, but worked fine under Linux (Ubuntu 8.04 Hardy). I don't understand what's wrong with 'strlen' initially: $ gcc -I/opt/local/lib/swipl-5.6.15/include -fpic -c lowercase.c ... and even though we do get an object file in the end, we can't create (and register?) a library at the next step (this seems to be the MacOS-specific problem): $ gcc -shared -o lowercase.so lowercase.o Any suggestions? I couldn't find anything online except http://www.phil.uu.nl/~xges/HOWTO/swipldynlib.html which seems quite old? Should I go for it anyway? Thank you, By hWnd at 2008-06-17 18:54 | LtU Forum | previous forum topic | next forum topic | other blogs | 8343 reads 
 | 
   Browse archives
 Active forum topics | 
  
Recent comments
1 hour 37 min ago
1 day 6 hours ago
1 day 6 hours ago
6 days 7 hours ago
6 days 7 hours ago
6 days 7 hours ago
3 weeks 6 days ago
4 weeks 5 days ago
4 weeks 5 days ago
5 weeks 12 min ago