Ian Lance Taylor <i...@golang.org> schreef op 20 december 2018 00:06:58 CET:

> How about this:
> 
> Move the C files to a subdirectory.  Write a script or Makefile that
> compiles the C files into a .syso file in the main package directory,
> using flags that you specify.  Fetch the package using `go get -d`.
> Run the script with the appropriate flags to generate the .syso file.
> At that point `go build` should work.

The C files are part of the package. This would mean, downloading the package 
and reorganize it.

I was thinking there might be a better way. Add a file with local 
configuration, a file that imports '"C" and sets CFLAGS and LDFLAGS, without 
modifying the official package files. This works, except for packages that rely 
on pkg-config. I don't see how I can modify the contents of PKG_CONFIG_PATH in 
a Go file.


-- 
Peter Kleiweg
http://pkleiweg.home.xs4all.nl

-- 
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