herumi / mcl

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

make fail #175

Closed leeweihanwickham closed 1 year ago

leeweihanwickham commented 1 year ago

I'm following the readme on a x-86 ubuntu git clone https://github.com/herumi/mcl cd mcl make -j4

However, there are so many errors including

src/bint_impl.hpp:423:25: error: ‘get_sub’ was not declared in this scope u_ppp sub = get_sub(yn); ^ src/bint_impl.hpp: In function ‘size_t mcl::bint::divFullBit(mcl::Unit, size_t, mcl::Unit, size_t, const Unit*, size_t)’: src/bint_impl.hpp:463:24: error: ‘get_sub’ was not declared in this scope u_ppp sub = get_sub(yn);

src/bint_impl.hpp:464:32: error: ‘get_mulUnit’ was not declared in this scope u_ppu mulUnit = get_mulUnit(yn); ^ In file included from src/fp.cpp:31:0: src/bint_impl.hpp: In function ‘void mcl::bint::mulNM(mcl::Unit, const Unit, size_t, const Unit, size_t)’: src/bint_impl.hpp:572:38: error: ‘get_mulUnitAdd’ was not declared in this scope u_ppu mulUnitAdd = get_mulUnitAdd(xn); ^ src/fp.cpp: In function ‘void mcl::fp::setOp(mcl::fp::Op&)’: src/fp.cpp:269:17: error: ‘get_add’ is not a member of ‘mcl::bint’ op.fp_addPre = bint::get_add(N); ^ src/fp.cpp:270:17: error: ‘get_sub’ is not a member of ‘mcl::bint’ op.fp_subPre = bint::get_sub(N); ^ src/fp.cpp:271:20: error: ‘get_add’ is not a member of ‘mcl::bint’ op.fpDbl_addPre = bint::get_add(N 2); ^ src/fp.cpp:272:20: error: ‘get_sub’ is not a member of ‘mcl::bint’ op.fpDbl_subPre = bint::get_sub(N * 2); ^ src/fp.cpp:273:20: error: ‘get_mul’ is not a member of ‘mcl::bint’ op.fpDbl_mulPre = bint::get_mul(N); ^ src/fp.cpp:274:20: error: ‘get_sqr’ is not a member of ‘mcl::bint’ op.fpDbl_sqrPre = bint::get_sqr(N); ^

herumi commented 1 year ago

What is the version of Ubuntu? What is your CPU? Does x-86 ubuntu mean 32-bit Ubuntu? Have you installed python3?

leeweihanwickham commented 1 year ago

Thx for your comments. Today I found that there are two files empty when I finished the git clone. Then I just used the autocomplete of git then everything goes well. Don't know why although.