fix linking error

This commit is contained in:
Gabriel mermelstein 2024-11-27 18:29:18 +02:00
parent 2fc438055a
commit 311f397b3a
No known key found for this signature in database
GPG Key ID: 82B8134785FEAE0D

View File

@ -4,8 +4,8 @@
package wakuv2
/*
#cgo LDFLAGS: -L../third_party/nwaku/build/ -lnegentropy -lwaku
#cgo LDFLAGS: -L../third_party/nwaku -Wl,-rpath,../third_party/nwaku/build/
#cgo LDFLAGS: -L./third_party/nwaku/build/ -lnegentropy -lwaku
#cgo LDFLAGS: -L./third_party/nwaku -Wl,-rpath,../third_party/nwaku/build/
#include "./third_party/nwaku/library/libwaku.h"
#include <stdio.h>
@ -543,6 +543,14 @@ func (n *WakuNode) postTask(reqType requestType, input any) (any, error) {
return response.value, nil
}
//export globalEventCallback
func globalEventCallback(callerRet C.int, msg *C.char, len C.size_t, userData unsafe.Pointer) {
// This is shared among all Golang instances
// TODO-nwaku
// self := Waku{wakuCtx: userData}
// self.MyEventCallback(callerRet, msg, len)
}
func (n *WakuNode) processLoop(ctx context.Context) {
for req := range n.requestCh {
switch req.reqType {