-
Notifications
You must be signed in to change notification settings - Fork 147
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
env_posix.c:125: error: storage size of ‘ai_hints’ isn’t known #47
Comments
I also encountered this problem, can you get the answer? |
Yes, I build the mongo-c-driver first then build nginx with the mongo-c-drive lib |
thanks,I will try it... |
Could you please explain your method in detail? I am also encountered this On Mon, Aug 27, 2012 at 11:20 AM, vnart [email protected] wrote:
cheers, |
use make or scons to build the mongo-c-drive lib ( refer to their website for further instruction). Then copy the lib to the right location. Modify config for nginx-gridfs to: CFLAGS="$CFLAGS --std=c99 -I src -I /usr/local/include -L /usr/local/lib -lmongoc " Then build nginx with --add-module=/root/july2012/gridfs/ --with-ld-opt=-lmongoc Should give you no error at all. However, the current version of nginx-grifs does not work well with replica set when the primary went offline. I had to make some change to the nginx-grifs source code to make it force reconnect the connection to detect the primary has change. One more thing, have to use nginx restart for nginx-grifs to work other. If use reload it will cause problem and nginx just quit. |
it was done by your way! it works well! thank you very much! @vnart |
Thank you vnart, it works! The images fetched by nginx-grifs can be cached On Mon, Aug 27, 2012 at 4:07 PM, vnart [email protected] wrote:
cheers, |
-o objs/addon/src/env_posix.o
/root/nginx_mongo/mongo-c-driver/src/env_posix.c
/root/nginx_mongo/mongo-c-driver/src/env_posix.c: In function ‘mongo_socket_connect’:
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:125: error: storage size of ‘ai_hints’ isn’t known
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:142: warning: implicit declaration of function ‘getaddrinfo’
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:144: warning: implicit declaration of function ‘gai_strerror’
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:149: error: dereferencing pointer to incomplete type
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:150: error: dereferencing pointer to incomplete type
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:150: error: dereferencing pointer to incomplete type
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:150: error: dereferencing pointer to incomplete type
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:156: error: dereferencing pointer to incomplete type
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:156: error: dereferencing pointer to incomplete type
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:163: error: dereferencing pointer to incomplete type
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:176: warning: implicit declaration of function ‘freeaddrinfo’
/root/nginx_mongo/mongo-c-driver/src/env_posix.c:125: warning: unused variable ‘ai_hints’
make[1]: *** [objs/addon/src/env_posix.o] Error 1
make[1]: Leaving directory `/root/nginx-1.2.2'
make: *** [build] Error 2
The text was updated successfully, but these errors were encountered: