| 12 Jan 2025 |
artemis | Or s/motivation/mental context/ if you like, nix stuff takes awhile for me to get back into since I don't do it much | 23:24:50 |
John Ericson | artemis: all good, were you interested in cross compiling just for nix purposes, or also for another reason? | 23:32:48 |
John Ericson | so far, I built dmake (rebasing that somake port) and cw | 23:33:23 |
artemis | It was a fun challenge and people said it wasn't possible so I wanted to do it. Ended up getting there with gentoo crossdev and then I was satisfied because I'd pulled it off But cross comp didn't really seem to serve any practical purpose aside from the particular task of bootstrapping nix, and I couldn't figure out the nixpkgs internals enough to try My interest in nix on illumos was mostly as an alternative to pkgsrc, in the role of auxiliary package repository | 23:38:34 |
John Ericson | artemis: oh! so you got further than your blog post indicated? | 23:39:08 |
artemis | Yeah I have a half written post about what I got working but I never got it to the point of publishing it | 23:39:44 |
John Ericson | ooo! | 23:39:53 |
artemis | I could share what I had though | 23:39:59 |
John Ericson | yes that would be great | 23:40:08 |
John Ericson | if you have, e.g. like a "compat" library for building stuff on linux with non-illumos glibc (like the freebsd and netbsd compat libs) | 23:40:46 |
John Ericson | that would be fantastic | 23:40:52 |
John Ericson | in general, if you did it once before, and we can read the code, I think we can "nixify" and merge it in nixpkgs really quick | 23:41:20 |
artemis | The way I did it basically was I used gentoo's crossdev tool to build a gcc targeting illumos (took a few tweaks to the gcc config to get it to work, right). Then I bundled up a ton of .so files I ripped off a real system and dropped them into the lib folder so linking against them would work. After that I was able to crossbuild OpenSSL (needed some build system fixes) and its dependencies, maybe a few other things, and with that environment I cross compiled a rust program and copied it over and it worked | 23:43:35 |
artemis | * The way I did it basically was I used gentoo's crossdev tool to build a gcc targeting illumos (took a few tweaks to the gcc config to get it to work right). Then I bundled up a ton of .so files I ripped off a real system and dropped them into the lib folder so linking against them would work. After that I was able to crossbuild OpenSSL (needed some build system fixes) and its dependencies, maybe a few other things, and with that environment I cross compiled a rust program and copied it over and it worked | 23:44:05 |
artemis | So I have an ebuild that uses my balls of .so and puts them in the right place, and also puts the headers where they need to be | 23:44:58 |
John Ericson | ah ok | 23:45:07 |
John Ericson | what did end up doing for the linker? | 23:45:32 |
artemis | To my surprise the gnu linker just worked | 23:45:47 |
John Ericson | oh, lol | 23:45:57 |
John Ericson | that helps | 23:45:59 |
artemis | Despite the fact that people had told me only the illumos linker can link for illumos | 23:46:08 |
John Ericson | heh. Well that's a relief! | 23:46:30 |
artemis | Download illumos-gentoo-overlay.tar.gz | 23:58:23 |
artemis | John Ericson ^ | 23:58:26 |
John Ericson | great thank you! | 23:58:35 |
artemis | this has my blog post basically as it, as well as the ebuilds | 23:58:38 |
artemis | the ebuilds if you ran them as they are pull from my file server for their "sources" at https://pkg.artemis.sh/gentoo/pkg-deps/illumos/ | 23:59:00 |
artemis | https://pkg.artemis.sh/gentoo/pkg-deps/illumos/helios-system-library-bin/what-is-where.html was some notes i was taking as to which illumos packages are in which tarfiles | 23:59:49 |
artemis | * https://pkg.artemis.sh/gentoo/pkg-deps/illumos/helios-system-library-bin/what-is-where.html was some notes i was taking as to which illumos packages i shoved into which tarfiles | 23:59:59 |
| 13 Jan 2025 |
| edef joined the room. | 00:00:50 |