From fcc0e1776be42b59bce9688cf2bef4c3e83631e0 Mon Sep 17 00:00:00 2001 From: xushiwei Date: Thu, 16 May 2024 18:40:49 +0800 Subject: [PATCH] build fix: -L dir --- README.md | 2 +- internal/build/build.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 1d891bea..e22c3bc0 100644 --- a/README.md +++ b/README.md @@ -46,7 +46,7 @@ See [github.com/goplus/llgo/c](https://pkg.go.dev/github.com/goplus/llgo/c) for You can import a Python library in LLGo! -And you can import any Python library into `llgo` through a program called `llpyg` (See [Development tools](#development-tools)). The currently imported libraries include: +And you can import any Python library into `llgo` through a program called `llpyg` (see [Development tools](#development-tools)). The currently imported libraries include: * [sys](https://pkg.go.dev/github.com/goplus/llgo/py/sys) * [os](https://pkg.go.dev/github.com/goplus/llgo/py/os) diff --git a/internal/build/build.go b/internal/build/build.go index eceb0597..37bfa7ac 100644 --- a/internal/build/build.go +++ b/internal/build/build.go @@ -209,7 +209,7 @@ func buildAllPkgs(prog llssa.Program, initial []*packages.Package, mode Mode, ve dir, lib := filepath.Split(linkFile) command := " -l " + lib if dir != "" { - command += " -L " + dir + command += " -L " + dir[:len(dir)-1] } if isSingleLinkFile(pkg.ExportFile) { pkg.ExportFile = command + " " + pkg.ExportFile