|
I'm on a windows machine and I've been fighting with minGW to compile something for hours... I'm sure someone with linux can do it in a few minutes. I'm trying to compile this library at https://github.com/sipa/secp256k1 with the instructions: * Run `./configure` and `make libjavasecp256k1.so` * Copy libjavasecp256k1.so to your system library Does anyone think they can compile this for me and host it somewhere? I would be extremely grateful.
|
# ? Sep 16, 2014 03:57 |
|
|
# ? Jun 9, 2024 20:06 |
|
Nevermind, it seems they updated this library without updating the instructions so I don't think it would work anyway. Thanks though.
|
# ? Sep 16, 2014 13:55 |
|
I'm interested to know if you can compile a library in linux to be used on windows. Everything I know about c/c++ screams no, but I know I don't know everything.
|
# ? Sep 18, 2014 01:11 |
|
keyvin posted:I'm interested to know if you can compile a library in linux to be used on windows. Everything I know about c/c++ screams no, but I know I don't know everything. Cross-compiling (i.e. compiling stuff for system type A on system type B) is a thing, so it's technically possible. Since both Linux and Windows usually run on x86-type systems, it should in theory be easier than, for example, compiling ARM stuff for Raspberry Pi on a Linux x86 desktop. In practice, there are quite a few details that need to be set up right, which would make it a fairly major pain in the rear end to set up just for one-time task. First, the compiler must be configured to expect that the code will be run in Windows-style address space layout and called using Windows-style calling conventions. Since gcc in general supports a huge number of systems and processor types, this might be just a matter of picking the right command-line options for the compiler. Second, if the library calls any Windows functions, you would need the Windows include files that describe the call interfaces. Microsoft being Microsoft, I would expect that getting these might require paying some $$ for a development kit and agreeing to some license, with possibly some non-obvious conditions buried into the fine print. FateFree might get off easy here, since the library he's asking about is a cryptographic algorithm, so chances are good that the library simply needs to receive some data from its caller, do quite a bit of integer math on it, and return the results - basically not involving the OS at all. Third, after compiling the code it needs to be packaged into a valid Windows-style library format. Apparently GNU libtool knows how to do that, with some caveats: http://www.gnu.org/software/libtool/manual/libtool.html#Windows-DLLs To sum up: while it might be easy for someone that already has the necessary cross-development tool-chain set up, it might not be so easy for any random Linux guy who hasn't done any cross-compiling before. (Or it might be that in this specific case you only need to get some command-line options right; it's been about 15 years since I did some minor cross-compiling.)
|
# ? Sep 27, 2014 19:29 |