You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to mongodb-user
Hi. I've used the Mongo drivers so far, with PHP and Java. Now it's
time for C. However, I'm experiencing some difficulties. I am on
Windows and use the make from cygwin. Extracted the folder and
executed the command "make" in the folder. What I got is this:
cc -o src/bson.o -c -std=c99 -pedantic -O3 -Wall -ggdb -
D_POSIX_SOURCE -DMONGO_HAVE_STDINT src/bson.c
cc -o src/encoding.o -c -std=c99 -pedantic -O3 -Wall -ggdb -
D_POSIX_SOURCE -DMONGO_HAVE_STDINT src/encoding.c
cc -o src/gridfs.o -c -std=c99 -pedantic -O3 -Wall -ggdb -
D_POSIX_SOURCE -DMONGO_HAVE_STDINT src/gridfs.c
cc -o src/md5.o -c -std=c99 -pedantic -O3 -Wall -ggdb -
D_POSIX_SOURCE -DMONGO_HAVE_STDINT src/md5.c
cc -o src/mongo.o -c -std=c99 -pedantic -O3 -Wall -ggdb -
D_POSIX_SOURCE -DMONGO_HAVE_STDINT src/mongo.c
src/mongo.c: In function `mongo_check_last_error':
src/mongo.c:808: warning: comparison between pointer and integer
src/mongo.c:809: warning: comparison between pointer and integer
src/mongo.c:799: warning: unused variable `success'
cc -o src/numbers.o -c -std=c99 -pedantic -O3 -Wall -ggdb -
D_POSIX_SOURCE -DMONGO_HAVE_STDINT src/numbers.c
cc -o src/env_posix.o -c -std=c99 -pedantic -O3 -Wall -ggdb -
D_POSIX_SOURCE -DMONGO_HAVE_STDINT src/env_posix.c
In file included from src/env_posix.c:29:
/usr/include/netinet/tcp.h:53: error: parse error before "u_short"
/usr/include/netinet/tcp.h:54: error: ISO C forbids data definition
with no type or storage class
/usr/include/netinet/tcp.h:58: error: parse error before "th_x2"
/usr/include/netinet/tcp.h:65: error: ISO C forbids data definition
with no type or storage class
/usr/include/netinet/tcp.h:74: error: parse error before "th_win"
/usr/include/netinet/tcp.h:74: error: ISO C forbids data definition
with no type or storage class
/usr/include/netinet/tcp.h:75: error: parse error before "th_sum"
/usr/include/netinet/tcp.h:75: error: ISO C forbids data definition
with no type or storage class
/usr/include/netinet/tcp.h:76: error: parse error before "th_urp"
/usr/include/netinet/tcp.h:76: error: ISO C forbids data definition
with no type or storage class
Makefile:183: recipe for target `src/env_posix.o' failed
make: *** [src/env_posix.o] Error 1
Any idea? What should I end up with? Thanks
Eric Milkie
unread,
May 14, 2012, 2:11:20 PM5/14/12
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to mongod...@googlegroups.com
Hi Andrew,
The C driver makefile is using -pedantic, which won't work with the headers on Windows unfortunately. Your options are to either change the makefile to not use -pedantic, or use SCons to build the C driver.