detached 1600172

Document supported platforms and status of project (#168)

Closes #149
commit
1600172341f646ce7d94540886a87e52e5fe6f94
author
TotallyGamerJet · · 2023-09-23 15:38 UTC
committer
GitHub · · 2023-09-23 15:38 UTC
parent
6aa09b6
signature
GPG Unverified4AEE18F83AFDEB23 The key is unknown
refs
tag: v0.6.0-alpha.1
1 file · +20 -1
M README.md +20 -1
@@ -3,6 +3,10 @@
33
44 A library for calling C functions from Go without Cgo.
55
6+> This is beta software so expect bugs and potentially API breaking changes
7+> but each release will be tagged to avoid breaking people's code.
8+> Bug reports are encouraged.
9+
610 ## Motivation
711
812 The [Ebitengine](https://github.com/hajimehoshi/ebiten) game engine was ported to use only Go on Windows. This enabled
@@ -17,6 +21,15 @@ born to bring that same vision to the other platforms supported by Ebitengine.
1721 - **Dynamic Linking**: Load symbols at runtime and use it as a plugin system.
1822 - **Foreign Function Interface**: Call into other languages that are compiled into shared objects.
1923
24+## Supported Platforms
25+
26+- **FreeBSD**: amd64, arm64
27+- **Linux**: amd64, arm64
28+- **macOS / iOS**: amd64, arm64
29+- **Windows**: 386*, amd64, arm*, arm64
30+
31+`*` These architectures only support SyscallN and NewCallback
32+
2033 ## Example
2134
2235 This example only works on macOS and Linux. For a complete example look at [libc](https://github.com/ebitengine/purego/tree/main/examples/libc) which supports Windows and FreeBSD.
@@ -55,6 +68,11 @@ func main() {
5568
5669 Then to run: `CGO_ENABLED=0 go run main.go`
5770
71+## Questions
72+
73+If you have questions about how to incorporate purego in your project or want to discuss
74+how it works join the [Discord](https://discord.com/channels/842049801528016967/1123106378731487345)!
75+
5876 ### External Code
5977
6078 Purego uses code that originates from the Go runtime. These files are under the BSD-3
@@ -71,4 +89,5 @@ This is a list of the copied files:
7189 * `internal/fakecgo/setenv.go` from package `runtime/cgo`
7290 * `internal/fakecgo/freebsd.go` from package `runtime/cgo`
7391
74-The files `abi_*.h` and `internal/fakecgo/abi_*.h` are the same because Bazel does not support cross-package use of `#include` so we need each one once per package. (cf. [issue](https://github.com/bazelbuild/rules_go/issues/3636))
92+The files `abi_*.h` and `internal/fakecgo/abi_*.h` are the same because Bazel does not support cross-package use of
93+`#include` so we need each one once per package. (cf. [issue](https://github.com/bazelbuild/rules_go/issues/3636))
@@ -3,6 +3,10 @@
3 3
4 A library for calling C functions from Go without Cgo.4 A library for calling C functions from Go without Cgo.
5 5
6+> This is beta software so expect bugs and potentially API breaking changes
7+> but each release will be tagged to avoid breaking people's code.
8+> Bug reports are encouraged.
9+
6 ## Motivation10 ## Motivation
7 11
8 The [Ebitengine](https://github.com/hajimehoshi/ebiten) game engine was ported to use only Go on Windows. This enabled12 The [Ebitengine](https://github.com/hajimehoshi/ebiten) game engine was ported to use only Go on Windows. This enabled
@@ -17,6 +21,15 @@ born to bring that same vision to the other platforms supported by Ebitengine.
17 - **Dynamic Linking**: Load symbols at runtime and use it as a plugin system.21 - **Dynamic Linking**: Load symbols at runtime and use it as a plugin system.
18 - **Foreign Function Interface**: Call into other languages that are compiled into shared objects.22 - **Foreign Function Interface**: Call into other languages that are compiled into shared objects.
19 23
24+## Supported Platforms
25+
26+- **FreeBSD**: amd64, arm64
27+- **Linux**: amd64, arm64
28+- **macOS / iOS**: amd64, arm64
29+- **Windows**: 386*, amd64, arm*, arm64
30+
31+`*` These architectures only support SyscallN and NewCallback
32+
20 ## Example33 ## Example
21 34
22 This example only works on macOS and Linux. For a complete example look at [libc](https://github.com/ebitengine/purego/tree/main/examples/libc) which supports Windows and FreeBSD.35 This example only works on macOS and Linux. For a complete example look at [libc](https://github.com/ebitengine/purego/tree/main/examples/libc) which supports Windows and FreeBSD.
@@ -55,6 +68,11 @@ func main() {
55 68
56 Then to run: `CGO_ENABLED=0 go run main.go`69 Then to run: `CGO_ENABLED=0 go run main.go`
57 70
71+## Questions
72+
73+If you have questions about how to incorporate purego in your project or want to discuss
74+how it works join the [Discord](https://discord.com/channels/842049801528016967/1123106378731487345)!
75+
58 ### External Code76 ### External Code
59 77
60 Purego uses code that originates from the Go runtime. These files are under the BSD-378 Purego uses code that originates from the Go runtime. These files are under the BSD-3
@@ -71,4 +89,5 @@ This is a list of the copied files:
71 * `internal/fakecgo/setenv.go` from package `runtime/cgo`89 * `internal/fakecgo/setenv.go` from package `runtime/cgo`
72 * `internal/fakecgo/freebsd.go` from package `runtime/cgo`90 * `internal/fakecgo/freebsd.go` from package `runtime/cgo`
73 91
74-The files `abi_*.h` and `internal/fakecgo/abi_*.h` are the same because Bazel does not support cross-package use of `#include` so we need each one once per package. (cf. [issue](https://github.com/bazelbuild/rules_go/issues/3636))92+The files `abi_*.h` and `internal/fakecgo/abi_*.h` are the same because Bazel does not support cross-package use of
93+`#include` so we need each one once per package. (cf. [issue](https://github.com/bazelbuild/rules_go/issues/3636))

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 1

Tags 102

↑↓ moveenter openesc close