herumi / mcl

a portable and fast pairing-based cryptography library
BSD 3-Clause "New" or "Revised" License
450 stars 151 forks source link

What is that mean "make bin/filename.exe && bin/filename.exe" ? #166

Closed NP-h closed 1 year ago

NP-h commented 1 year ago

Hi herumi, It is not a critical question, but really i want to know what is that mean.. In my opinion, when i use Cpp(C++) or C with gcc then normally combine command like "gcc filename.c" or combine object "gcc -o filename.c filename2.c "

what is the different point ?? when i use this library "gcc mysource.cpp" is not compiled with error(can't fine header) but when i use "make bin/filename.exe && bin/filename.exe" is working well.

can you teach me? please let me know if you can.

Thank you

herumi commented 1 year ago

You should use g++ mysource.cpp instead of gcc mysource.cpp, and specify -I <include dir> and linker options. Simply, move mysource.cpp to mcl/sample, and type make bin/mysource.exe && bin/mysource.exe.

But you seem not to be good at C++. What language do you specialize in? If you can use JavaScript, then please try https://github.com/herumi/mcl-wasm .

NP-h commented 1 year ago

Thank you always!