On Sun, Dec 25, 2016 at 9:22 AM James Pettyjohn <japettyj...@gmail.com>
wrote:

> I've been looking at a number of articles on statically linking go files
> by disabling CGO, sounds great except I've got a libsass dependency until
> the native libsass is ready.
>
> Can this be in a straightforward manner with go 1.6/1.7 on linux (centos)?
>

Are you asking about statically linking libsass?

In addition to other flags to statically link your Go binary, you can tell
cgo to statically link libsass:

$ export CGO_LDFLAGS="\
-Wl,-Bstatic \
    `pkg-config --libs libsass` \
    -lotherDep -lotherDep2
-Wl,-Bdynamic"

​

- Justin

> --
> You received this message because you are subscribed to the Google Groups
> "golang-nuts" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to golang-nuts+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to