hillu / go-yara

Go bindings for YARA
BSD 2-Clause "Simplified" License
350 stars 112 forks source link

Building static binary #136

Closed cyrus-mc closed 3 months ago

cyrus-mc commented 7 months ago

According to the documentation there are two steps required to build statically:

I have set the build tag at the top of the main package as such:

//go:build yara_static
// +build yara_static

package main

import (
   ...
)

func main() {
   ...
)

I then invoke go build with -tags=yara_static and -ldflags '-s -w -extldflags "-static"'.

Building results in multiple errors relating to yara.Scanner, yara.NewCompiler, etc undefined.

hillu commented 7 months ago

Please tell me the environment you are trying to build go-yara in. Also, provide a complete minimal reproducer program and the exact error messages you are getting.

hillu commented 5 months ago

@cyrus-mc ping?

hillu commented 3 months ago

@cyrus-mc Since you haven't provided any more information, I'm closing this issue.