project-everest / everest

https://project-everest.github.io/
Apache License 2.0
193 stars 29 forks source link

Building test-perf.exe fails on Cygwin #25

Closed andreasdotorg closed 7 years ago

andreasdotorg commented 7 years ago

test-perf.exe didn't build for me, and the error was that the linker complained about missing symbols related to Winsock. Probably openssl pulls those in. Anyways, after changing FStar/examples/low-level/Makefile, line reading:

-I $(OPENSSL_HOME)/include -ldopts -L,$(OPENSSL_HOME)/lib,-L,$(OPENSSL_HOME),-lcrypto $(CFLAGS)

to

-I $(OPENSSL_HOME)/include -ldopts -L,$(OPENSSL_HOME)/lib,-L,$(OPENSSL_HOME),-lcrypto,-lws2_32 $(CFLAGS)

it built for me.

msprotz commented 7 years ago

I thought x86_64-x64-mingw32-gcc took care of adding -lws2_32 automatically?

Glad someone managed to recompile everything on their own!

andreasdotorg commented 7 years ago

The story is a little bit more complicated. There's the winsock implementation of the sockets API, and there is the cygwin implementation of the same. Someone, somewhere is managing to confuse those two, and I didn't do any deeper digging yet. See http://stackoverflow.com/questions/5719727/cygwin-windows-socket-programming

I'm not even sure I care that much about this particular issue except for it breaking the build, as I figure the only point of having OpenSSL at all is for performance comparisons to their implementation.

Also, there are one or two more things that fail for me, expect more bug reports. :)

andreasdotorg commented 7 years ago

Issue closed by merging FStarLang/FStar#898