vearutop / faces

Face recognition HTTP microservice
https://dev.to/vearutop/building-a-portable-face-recognition-application-with-go-and-dlib-12p1
Creative Commons Zero v1.0 Universal
4 stars 1 forks source link

Darwin and windows ? #6

Open gedw99 opened 7 months ago

gedw99 commented 7 months ago

Hey @vearutop

I would like to make a static binary for Darwin and Windows for amd64 and arm64.

I just read the way you did on this at:

https://dev.to/vearutop/building-a-portable-face-recognition-application-with-go-and-dlib-12p1

From what I can see this is build with builder to make the static binary by using docker buildx ?

vearutop commented 7 months ago

Hi @gedw99, unfortunately, I'm not knowledgeable enough about building with docker for platforms other than Linux.

But I've tried to build a portable binary for Windows with MinGW-w64 (mostly by following https://github.com/Kagami/go-face?tab=readme-ov-file#windows), it didn't work quite as I expected, I ended up having a few .dll files required to run, you can find archived binary and runtime libraries in release attachment: https://github.com/vearutop/faces/releases/tag/v0.1.4. Maybe this can be automated with GitHub Action running on a windows host, I haven't had time to explore that.

I've seen a gist https://gist.github.com/youhide/121750fc4878801ea8e908080b535beb that might be a good starting point for experimentation.

And as for darwin, I haven't tried building a static binary there. Particular details of building process vary from platform to platform.