Stream: beginners

Topic: ✔ How to build roc-ray platform locally and use it?


view this post on Zulip radekm (Aug 24 2026 at 06:33):

Hi,

I'm trying to use roc-ray platform locally. I built it using bundle.sh script and now I'm trying to use it from another program with this code:

app [main!] {
    cli: platform "../roc-ray/8jGkXwdkXRM6SJkEze7ZjZedpSKbG315ZnBDcwEM8bJz.tar.zst",
}

Unfortunately I'm getting compiler error from roc build:

This project's header declares ../roc-ray/8jGkXwdkXRM6SJkEze7ZjZedpSKbG315ZnBDcwEM8bJz.tar.zst as its platform, but that package does not have
a platform header.

Seems it's not valid platform file? How can I fix that? Thanks

view this post on Zulip Luke Boswell (Aug 24 2026 at 06:38):

If you want to use a bundle locally you will need a web server to serve the files on localhost

view this post on Zulip Luke Boswell (Aug 24 2026 at 06:38):

Alternatively upload the bundle to a location online with a https:// location

view this post on Zulip Luke Boswell (Aug 24 2026 at 06:39):

If you are just working locally you can use a relative path to the platform/main.roc ... you build the host files using zig build and then you should see the libhost.a etc in platform/targets/* etc

view this post on Zulip radekm (Aug 24 2026 at 06:58):

Thanks, it works with local web server. I also had to use --max-transitive-mb=160because the package is big

view this post on Zulip Notification Bot (Aug 24 2026 at 06:59):

radekm has marked this topic as resolved.

view this post on Zulip removewingman (Aug 28 2026 at 21:56):

You can also point to the platform/main.roc, then it should work aswell: https://codeberg.org/removewingman/restricted-roc/src/branch/main/test/hello-world.roc


Last updated: Sep 03 2026 at 15:16 UTC