Skip to content

Commit

Permalink
add more supported platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
Alesfatalis committed Apr 13, 2024
1 parent 8a03b3e commit 7abd8b4
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-13]
os: [ubuntu-latest, macos-latest, windows-latest]

steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ The libraries under `lib` where compiled from `sigma-rust` with the following co
```
cross build -p ergo-lib-c --release --target x86_64-apple-darwin
cross build -p ergo-lib-c --release --target x86_64-unknown-linux-gnu
cross build -p ergo-lib-c --release --target aarch64-unknown-linux-gnu
cross build -p ergo-lib-c --release --target x86_64-pc-windows-gnu
```

### Credits
Expand Down
3 changes: 2 additions & 1 deletion cgo.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ package ergo
// #cgo LDFLAGS: -lergo
//
// #cgo linux,amd64 LDFLAGS: -Wl,-rpath,${SRCDIR}/packaged/lib/linux-amd64 -L${SRCDIR}/packaged/lib/linux-amd64 -lm
// //#cgo linux,arm64 LDFLAGS: -Wl,-rpath,${SRCDIR}/packaged/lib/linux-aarch64 -L${SRCDIR}/packaged/lib/linux-aarch64
// #cgo linux,arm64 LDFLAGS: -Wl,-rpath,${SRCDIR}/packaged/lib/linux-aarch64 -L${SRCDIR}/packaged/lib/linux-aarch64
// #cgo windows,amd64 LDFLAGS: -Wl,-rpath,${SRCDIR}/packaged/lib/windows-amd64 -L${SRCDIR}/packaged/lib/windows-amd64
// #cgo darwin,amd64 LDFLAGS: -Wl,-rpath,${SRCDIR}/packaged/lib/darwin-amd64 -L${SRCDIR}/packaged/lib/darwin-amd64
// //#cgo darwin,arm64 LDFLAGS: -Wl,-rpath,${SRCDIR}/packaged/lib/darwin-aarch64 -L${SRCDIR}/packaged/lib/darwin-aarch64
//
Expand Down
2 changes: 2 additions & 0 deletions packaged/lib/dummy.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@ package lib

import (
_ "github.com/sigmaspace-io/ergo-lib-go/packaged/lib/darwin-amd64"
_ "github.com/sigmaspace-io/ergo-lib-go/packaged/lib/linux-aarch64"
_ "github.com/sigmaspace-io/ergo-lib-go/packaged/lib/linux-amd64"
_ "github.com/sigmaspace-io/ergo-lib-go/packaged/lib/windows-amd64"
)
2 changes: 2 additions & 0 deletions packaged/lib/linux-aarch64/dummy.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
// See https://github.com/golang/go/issues/26366.
package linux_aarch64
Binary file added packaged/lib/linux-aarch64/libergo.a
Binary file not shown.
2 changes: 2 additions & 0 deletions packaged/lib/windows-amd64/dummy.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
// See https://github.com/golang/go/issues/26366.
package windows_amd64
Binary file added packaged/lib/windows-amd64/libergo.a
Binary file not shown.

0 comments on commit 7abd8b4

Please sign in to comment.