fix: android libs

This commit is contained in:
Richard Ramos 2022-08-10 19:06:50 -04:00
parent e9ce4db29a
commit e6f625d283
No known key found for this signature in database
GPG Key ID: BD36D48BC9FFC88C
8 changed files with 5 additions and 6 deletions

@ -1 +1 @@
Subproject commit 2e10b0a15cc6ac33a2e4ffbc28a4c755f12d8d7b
Subproject commit a7d30f175f903fa21864470e98445bffe32280da

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -6,8 +6,7 @@ package rln
#cgo android,arm7 LDFLAGS:-L${SRCDIR}/../libs/armv7-linux-androideabi
#cgo android,amd64 LDFLAGS:-L${SRCDIR}/../libs/x86_64-linux-android
#cgo android,386 LDFLAGS:-L${SRCDIR}/../libs/i686-linux-android
#cgo linux,arm,!arm7 LDFLAGS:-L${SRCDIR}/../libs/arm-unknown-linux-gnueabi
#cgo linux,arm7 LDFLAGS:-L${SRCDIR}/../libs/arm-unknown-linux-gnueabihf
#cgo linux,arm LDFLAGS:-L${SRCDIR}/../libs/armv7-linux-androideabi
#cgo linux,arm64 LDFLAGS:-L${SRCDIR}/../libs/aarch64-unknown-linux-gnu
#cgo linux,amd64,musl,!android LDFLAGS:-L${SRCDIR}/../libs/x86_64-unknown-linux-musl
#cgo linux,amd64,!musl,!android LDFLAGS:-L${SRCDIR}/../libs/x86_64-unknown-linux-gnu

View File

@ -36,7 +36,7 @@ func NewRLNWithDepth(depth int, params []byte) (*RLN, error) {
in := (*C.Buffer)(C.malloc(C.size_t(size)))
*in = buf
if !bool(C.new_circuit_from_params(C.ulong(depth), in, &r.ptr)) {
if !bool(C.new_circuit_from_params(C.uintptr_t(depth), in, &r.ptr)) {
return nil, errors.New("failed to initialize")
}
@ -80,7 +80,7 @@ func toBuffer(data []byte) C.Buffer {
dataPtr, dataLen := sliceToPtr(data)
return C.Buffer{
ptr: dataPtr,
len: C.ulong(dataLen),
len: C.uintptr_t(dataLen),
}
}
@ -207,7 +207,7 @@ func (r *RLN) InsertMember(idComm IDCommitment) bool {
// parameter is the position of the id commitment key to be deleted from the tree.
// The deleted id commitment key is replaced with a zero leaf
func (r *RLN) DeleteMember(index MembershipIndex) bool {
deletionSuccess := bool(C.delete_member(r.ptr, C.ulong(index)))
deletionSuccess := bool(C.delete_member(r.ptr, C.uintptr_t(index)))
return deletionSuccess
}