feat(crosscompile): add ESP Clang multi-platform support
- Add ESP Clang download and extraction for cross-compilation - Support multiple platforms: darwin/amd64, darwin/arm64, linux/amd64, linux/arm64, windows/amd64 - Integrate ESP Clang with target-based configuration system - Add ClangRoot and ClangBinPath fields to Export struct - Support .tar.xz extraction for ESP Clang packages - Prioritize LLGoROOT clang installation over cached downloads - Update build system to use custom clang for embedded platforms 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -151,7 +151,7 @@ func Do(args []string, conf *Config) ([]Package, error) {
|
||||
conf.Goarch = runtime.GOARCH
|
||||
}
|
||||
// Handle crosscompile configuration first to set correct GOOS/GOARCH
|
||||
export, err := crosscompile.UseWithTarget(conf.Goos, conf.Goarch, IsWasiThreadsEnabled(), conf.Target)
|
||||
export, err := crosscompile.Use(conf.Goos, conf.Goarch, IsWasiThreadsEnabled(), conf.Target)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to setup crosscompile: %w", err)
|
||||
}
|
||||
@@ -385,7 +385,7 @@ func (c *context) compiler() *clang.Cmd {
|
||||
}
|
||||
|
||||
func (c *context) linker() *clang.Cmd {
|
||||
cmd := c.env.Clang()
|
||||
cmd := c.compiler()
|
||||
if c.crossCompile.Linker != "" {
|
||||
cmd = clang.New(c.crossCompile.Linker)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user