Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

el capitan ots issues #5

Closed
ashabbir opened this issue Oct 12, 2015 · 6 comments
Closed

el capitan ots issues #5

ashabbir opened this issue Oct 12, 2015 · 6 comments

Comments

@ashabbir
Copy link

OTS worked in previous versions of osx but stopped working in ElCapitan

below is the error msg

➜ ~ gem install ots
Building native extensions. This could take a while...
ERROR: Error installing ots:
ERROR: Failed to build gem native extension.

/Users/amd/.rbenv/versions/2.2.1/bin/ruby -r ./siteconf20151011-28077-1bhpu1y.rb extconf.rb

checking for main() in -lglib-2.0... yes
checking for main() in -lxml2... yes
creating Makefile

make "DESTDIR=" clean

make "DESTDIR="
compiling libots/article.c
libots/article.c:107:37: warning: passing 'const unsigned char ' to parameter of type 'const char *' converts between pointers to integer types with different sign [-Wpointer-sign]
if ((aWord == NULL) || (0==strlen(aWord)) ||(NULL==aLine)) return;
^~~~~
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/include/string.h:82:28: note: passing argument to parameter here
size_t strlen(const char *);
^
libots/article.c:109:68: warning: passing 'const unsigned char *' to parameter of type 'const gchar *' (aka 'const char *') converts between pointers to integer types with different sign [-Wpointer-sign]
aLine->words = g_list_append (aLine->words, (gpointer) g_strdup (aWord));
^~~~~
/usr/local/Cellar/glib/2.46.0/include/glib-2.0/glib/gstrfuncs.h:216:52: note: passing argument to parameter 'str' here
gchar
g_strdup (const gchar *str) G_GNUC_MALLOC;
^
2 warnings generated.
compiling libots/dictionary.c
libots/dictionary.c:28:10: fatal error: 'libxml/xmlmemory.h' file not found

include <libxml/xmlmemory.h>

     ^

1 error generated.
make: *** [libots/dictionary.o] Error 1

make failed, exit code 2

Gem files will remain installed in /Users/amd/.rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/ots-0.5.4 for inspection.
Results logged to /Users/amd/.rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/extensions/x86_64-darwin-14/2.2.0-static/ots-0.5.4/gem_make.out

@deepfryed
Copy link
Owner

Sorry, I don't have an Apple Mac to test this on. Would you be able to look at it and send me a pull request ?

@sandeep45
Copy link

+1@ashabbir were you able to resolve this?

@sandeep45
Copy link

I was able to resolve the issue by doing
export C_INCLUDE_PATH=$C_INCLUDE_PATH:/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/include/libxml2
and then building the gem
gem install ots

@keithrowell
Copy link

Thanks sandeep45, that problem could have gone on for days!

@Qubaish
Copy link

Qubaish commented Apr 19, 2018

@sandeep45, I tried the solution which you mentioned but it not helps me. Any other suggestions or any other steps which is required because I follow all the steps which was mentioned in gem doc.

Thanks

@ashabbir
Copy link
Author

moved to docker :) ubuntu

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants