On Thu, Dec 20, 2018 at 1:07 AM Peter Kleiweg <pklei...@xs4all.nl> wrote:
>
> 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 imagining that this rearrangement would be done at the package
source, not each time it was downloaded.


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

Sure, that could work too.

I don't understand why pkg-config would need to be correct on a
specific system.  Why would pkg-config be incorrect?

Ian

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