!djTaTBQyWEPRQxrPTb:nixos.org

Nixpkgs Architecture Team

237 Members
https://github.com/nixpkgs-architecture, weekly public meetings on Wednesday 15:00-16:00 UTC at https://meet.jit.si/nixpkgs-architecture54 Servers

Load older messages


SenderMessageTime
20 Jul 2022
@yorik.sar:matrix.orgyorik.sarI mean, we should probably define that.16:07:16
@yorik.sar:matrix.orgyorik.sarThere's also https://github.com/SwadicalRag/wasm2lua that could be used as last resort for such platforms...16:08:19
@kevincox:matrix.orgkevincoxFWIW I don't think we need to exactly define it. We consider it as part of the tradeoff. If two options are basically the same but one supports 10 "systems" and the other only supports 8 we prefer the 10 one. However there is probably a minimum set that is a deal breaker that we can define.16:08:21
@gytis-ivaskevicius:matrix.orgGytis IvaskeviciusFor lua vs ruby argument: Initially i wrote most of this in lua, but its nowhere near as clean, requires quite a few extra dependencies and overall less convenient https://github.com/gytis-ivaskevicius/nix-reinventing-the-wheel/tree/master/builders/scripts And i was learning ruby with this project, there definetelly are some issues, off the top of my head it requires a little DSL for env/json values access and make spawning processes more asynchronous. All in all - till now i cant think of a better language choice while keeping our restrictions in mind16:08:43
@yorik.sar:matrix.orgyorik.sarWell, we should probably take into account what platforms we want to support in the end...16:08:50
@infinisil:matrix.orginfinisilFor some exotic platforms, this user seems to do some work: https://github.com/NixOS/nixpkgs/pulls?q=author%3Aamjoseph-nixpkgs16:08:57
@yorik.sar:matrix.orgyorik.sarWe could also fall back to generating Bash code...16:09:48
@kity:kity.wtfproblemsthe point is to do things bash can't do, like working with structured data16:10:43
@gytis-ivaskevicius:matrix.orgGytis Ivaskevicius
In reply to @yorik.sar:matrix.org
We could also fall back to generating Bash code...
I'd say either we keep mkderivation as it is or change it for the better
16:10:51
@infinisil:matrix.orginfinisil ash (it/its) 🏳️‍⚧️: I think yorik.sar means to essentially compile to bash from the language that's picked 16:11:03
@gytis-ivaskevicius:matrix.orgGytis Ivaskevicius
In reply to @yorik.sar:matrix.org
We could also fall back to generating Bash code...
* I'd say either we keep mkderivation as it is or change it for the better. No middle ground
16:11:03
@infinisil:matrix.orginfinisilI think that's a viable temporary solution while the language waits for support for more exotic platforms16:11:25
@yorik.sar:matrix.orgyorik.sarBy the way, it's also an option - use Bash as runtime, but add a good language that can be translated to it. Then the translator is responsible for all type checking and guarnatees.16:11:38
@infinisil:matrix.orginfinisilOh but then the compiler from language X to bash needs to be portable..16:11:57
@infinisil:matrix.orginfinisilSounds messy!16:12:09
@yorik.sar:matrix.orgyorik.sarWell, we could build the builder on Linux or smth...16:12:28
@gytis-ivaskevicius:matrix.orgGytis Ivaskevicius
In reply to @yorik.sar:matrix.org
By the way, it's also an option - use Bash as runtime, but add a good language that can be translated to it. Then the translator is responsible for all type checking and guarnatees.
i am not aware of such languages and i find difficult to imagine something that does the job well. but surprise me ;)
16:12:34
@yorik.sar:matrix.orgyorik.sar(if we use system-agnostic drv for that)16:12:38
@infinisil:matrix.orginfinisilProbably best to pick a very portable language from the start16:12:40
@infinisil:matrix.orginfinisilOr wait for WASM16:12:50
@infinisil:matrix.orginfinisil/WASI16:12:54
@kity:kity.wtfproblemsmy gf would like me to mention that if a language is picked for this that works with netbsd/vax, she's interested in trying to get it actually working on that platform16:12:58
@yorik.sar:matrix.orgyorik.sar
In reply to @kity:kity.wtf
my gf would like me to mention that if a language is picked for this that works with netbsd/vax, she's interested in trying to get it actually working on that platform
Port wasmtime there and all languages will come ;)
16:13:29
@kevincox:matrix.orgkevincox FWIW I don't think we need strong type checking for builder scripts. I just think we need more types than string and array of string. 16:13:33
@infinisil:matrix.orginfinisilGood point, portability isn't something static, people might be motivated to add support if they can use it for nixpkgs16:13:38
@kity:kity.wtfproblems
In reply to@yorik.sar:matrix.org
Port wasmtime there and all languages will come ;)
not possible due to floating point issues
16:13:46
@yorik.sar:matrix.orgyorik.sarhttps://github.com/batsh-dev-team/Batsh16:14:14
@gytis-ivaskevicius:matrix.orgGytis Ivaskevicius
In reply to @infinisil:matrix.org
Or wait for WASM
lua/ruby can run on wasm as well as many others. Either way these derivations would not suddenly become system agnostic since we need something to covnvert xLang -> wasm
16:14:15
@yorik.sar:matrix.orgyorik.sar
In reply to @kity:kity.wtf
not possible due to floating point issues
You can emulate them if needed. It would be slower, but would still work.
16:14:49
@kevincox:matrix.orgkevincox The performance of the builder script is unlikely to be a significant cost even with emulated floating point. 16:15:31

Show newer messages


Back to Room ListRoom Version: 9