Skip to content

Commit

Permalink
mach-basisu is no longer an official project
Browse files Browse the repository at this point in the history
See hexops/mach#965

Signed-off-by: Stephen Gutekanst <[email protected]>
  • Loading branch information
slimsag committed Jun 2, 2024
1 parent 7e9778c commit e6c9bc3
Show file tree
Hide file tree
Showing 11 changed files with 3 additions and 501 deletions.
6 changes: 0 additions & 6 deletions config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -221,12 +221,6 @@ unsafe = true
name = 'gpu-dawn'
url = '/pkg/mach-gpu-dawn'
weight = 3100
[[menu.pkg]]
identifier = 'pkg-bind-basisu'
parent = 'pkg-bind'
name = 'basisu'
url = '/pkg/mach-basisu'
weight = 3200
[[menu.pkg]]
identifier = 'pkg-bind-freetype'
parent = 'pkg-bind'
Expand Down
6 changes: 0 additions & 6 deletions content/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -448,12 +448,6 @@ $ zig build -Dtarget=aarch64-macos
<img alt="mach-gamemode" src="/assets/mach/gamemode-light.svg" style="height: 3rem; margin-right: 1rem; margin-top: 0.5rem;">
</picture>
</a>
<a href="/pkg/mach-basisu" class="img-link">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="/assets/mach/basisu-dark.svg">
<img alt="mach-basisu" src="/assets/mach/basisu-light.svg" style="height: 3rem; margin-right: 1rem; margin-top: 0.5rem;">
</picture>
</a>
<a href="/pkg/mach-sysgpu" class="img-link">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="/assets/mach/sysgpu-dark.svg">
Expand Down
6 changes: 0 additions & 6 deletions content/pkg/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,6 @@ Mach provides an ecosystem of 100% standalone, high-quality Zig gamedev packages
<img alt="mach-gamemode" src="/assets/mach/gamemode-light.svg" style="height: 3rem; margin-right: 1rem; margin-top: 0.5rem;">
</picture>
</a>
<a href="/pkg/mach-basisu" class="img-link">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="/assets/mach/basisu-dark.svg">
<img alt="mach-basisu" src="/assets/mach/basisu-light.svg" style="height: 3rem; margin-right: 1rem; margin-top: 0.5rem;">
</picture>
</a>
<a href="/pkg/mach-sysgpu" class="img-link">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="/assets/mach/sysgpu-dark.svg">
Expand Down
1 change: 0 additions & 1 deletion content/pkg/c.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ Pure forks with build.zig:
* [harfbuzz](https://github.com/hexops/harfbuzz)
* [freetype](https://github.com/hexops/freetype)
* [glfw](https://github.com/hexops/glfw)
* [basisu](https://github.com/hexops/basisu)
* [opus](https://github.com/hexops/opus)
* [opusfile](https://github.com/hexops/opusfile)
* [opusenc](https://github.com/hexops/opusenc)
Expand Down
68 changes: 3 additions & 65 deletions content/pkg/mach-basisu.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,70 +7,8 @@ docs_type: "pkg"
rss_ignore: true
---

<div class="centered">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="/assets/mach/basisu-full-dark.svg">
<img alt="mach-basisu" src="/assets/mach/basisu-full-light.svg" style="height: 7rem; margin-top: 1rem;">
</picture>
<span>
<a href="https://github.com/hexops/mach-basisu">GitHub repository</a> | <a href="https://github.com/hexops/mach/issues?q=is%3Aissue+is%3Aopen+label%3Abasisu">Issue tracker</a>
</span>
</div>
No longer supported as an official Mach project. The code has moved to [github.com/slimsag/mach-basisu](https://github.com/slimsag/mach-basisu) and may not be maintained to the same standard as official Mach projects.

basis universal (supercompressed textures) for Zig
**Additional details:** https://github.com/hexops/mach/issues/965

## Experimental

This is an **experimental** project according to [our stability guarantees](../../about/stability):

> When a project has an experimental warning, it means all bets are off. You should carefully read the warning to understand why the project is experimental, and assume the worst.
**Tracking issue:** https://github.com/hexops/mach/issues/965

## Getting started

Create a `build.zig.zon` in your project (replace `LATEST_COMMIT` with the latest commit hash):

```zig
.{
.name = "mypkg",
.version = "0.1.0",
.dependencies = .{
.mach_basisu = .{
.url = "https://pkg.machengine.org/mach-basisu/LATEST_COMMIT.tar.gz",
},
},
}
```

Run `zig build` in your project, and the compiler will instruct you to add a `.hash = "..."` field next to `.url`:

```
note: expected .hash = "12209838fcfb7a77d2d6931efdc7448c033a1b7dad11d082c94bbeeba9d1038cd311",
```

Then use the dependency in your `build.zig`:

```zig
pub fn build(b: *std.Build) void {
...
exe.root_module.addImport("mach-basisu", b.dependency("mach_basisu", .{
.target = target,
.optimize = optimize,
}).module("mach-basisu"));
}
```

You can now use it in your `src/main.zig` file:

```zig
const basisu = @import("mach-basisu");
```

See [this test](https://github.com/hexops/mach-basisu/blob/main/src/main.zig#L22-L47) for usage.

### Ran into trouble?

Triple-check you followed the `build.zig.zon` instructions correctly, it's easy to mess that part up.

Feel free to join the [Mach Discord community](../../discord) for help.
**View the older v0.3 documentation:** https://machengine.org/v0.3/pkg/mach-basisu
16 changes: 0 additions & 16 deletions static/assets/mach/basisu-dark.svg

This file was deleted.

187 changes: 0 additions & 187 deletions static/assets/mach/basisu-full-dark.svg

This file was deleted.

Loading

0 comments on commit e6c9bc3

Please sign in to comment.