cryptosense / pkcs11

OCaml bindings for the PKCS#11 cryptographic API
BSD 2-Clause "Simplified" License
23 stars 6 forks source link

Fix OSX build #9

Open emillon opened 7 years ago

emillon commented 7 years ago

At the moment the build fails on osx.

Make it possible to either:

The current solution (disable the whole package on osx) also works. To anyone interested: patches welcome :)

vbgl commented 7 years ago

The dlfcn.h header is available on osx. It seems enough (at least, it fixes the build) to generalize the #if defined(__linux__) || (defined(__sun) && defined(__SVR4)) conditional to include defined(__APPLE__).

emillon commented 7 years ago

Hi,

Great, I don't have an OSX system so I did not know what was the macro to use.

If you submit a pull request making sure that it builds and the tests pass, I'll include that in the next release.

Thanks!

yallop commented 7 years ago

It could be useful to add an OS X entry to the Travis configuration to ensure that the build keeps working.

emillon commented 7 years ago

@yallop IIRC OSX support for Travis makes really long builds, I don't think it's worth having it permanently enabled.