2 Aug 2021 |
siraben | because isn't the point of having cross systems is to be able to cross-compile programs? | 06:48:40 |
siraben | e.g. similarly to MMIX support | 06:48:47 |
Alyssa Ross | right, but GNU hello is a Unix program | 07:06:11 |
Alyssa Ross | you're trying to compile to bare metal aiui | 07:06:18 |
siraben | In reply to @qyliss:fairydust.space you're trying to compile to bare metal aiui even so, I can't obtain a shell with a cross compiler
$ nix-shell --expr --impure 'with import ./. { crossSystem = { config = "pdp11-aout"; }; }; mkShell {}'
error: Unknown libc native/impure
(use '--show-trace' to show detailed location information)
-bash-4.2$
| 07:18:26 |
siraben | In reply to @qyliss:fairydust.space you're trying to compile to bare metal aiui * even so, I can't obtain a shell with a cross compiler
$ nix-shell --expr --impure 'with import ./. { crossSystem = { config = "pdp11-aout"; }; }; mkShell {}'
error: Unknown libc native/impure
(use '--show-trace' to show detailed location information)
| 07:18:29 |
siraben | hm, maybe need to specify newlib | 07:18:40 |
Alyssa Ross | Is cross compiling to PDP-11 bare metal actually what you want? You don't want to target Unix? | 07:21:46 |
siraben | If I targeted unix, the syscalls would have to be supported, right? | 07:23:15 |
siraben | I just thought that bare metal would be easiest to get working | 07:23:26 |
Alyssa Ross | Well, do you have any programs that support running on bare metal on a PDP-11? | 07:40:06 |
siraben | int main () { return 0; } ? | 07:58:17 |
siraben | 😅 | 07:58:26 |
siraben | I'm not sure if newlib or glibc cross-compiles | 07:59:19 |
siraben | the Unix that PDP-11 ran has not been used in decades | 07:59:27 |
Alyssa Ross | what are you intending on running on this, then? | 08:00:13 |
siraben | literally just doing it to make it a cross target | 08:04:08 |
siraben | same motivation as MMIX | 08:04:14 |
siraben | * same motivation as MMIX, at most there's a simulator | 08:04:22 |
Alyssa Ross | hmm, I'm not sure about adding cross targets that don't even have a realistic use case | 08:05:11 |
Alyssa Ross | not because I'm opposed to more cross targets, but just because it's too hard to know whether we've got it right | 08:05:23 |
siraben | they don't add load on hydra and encourage build diversity | 08:05:32 |
Alyssa Ross | you don't have to convince me that more cross targets in general are a good thing | 08:05:50 |
siraben | ok | 08:06:02 |
siraben | Yeah, getting it right is the hard bit | 08:06:06 |
siraben | I usually use GNU Hello as "good enough" | 08:06:11 |
Alyssa Ross | but in this case, where there's no software we can even build for this thing, there's no way for us to even test it | 08:06:14 |
Alyssa Ross | so I don't think it really makes sense to have this particular target in Nixpkgs | 08:08:41 |
siraben | I see | 08:12:41 |
siraben | Closing, then. | 08:12:59 |