New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issues with Platform Support wiki page #6903
Comments
Thanks for pointing all of these out! Unfortunately, we had to limit the wiki edit permissions due to the recent influx of trolls to our repos. The problem with this is that we're left with no editorial workflow for contributions coming from the community. One possible follow up would be to delete this page and move the information to the Crystal book. It would sort of make sense because we already have a chapter about installation methods in different platforms. |
|
@mverzilli is it possible to limit the Wiki editions only to contributors? It would be nice! |
It's either a) public or b) restricted to users in teams with push access only. It would be great option, definitely. |
@wmoxam That's interesting. It seems like LLVM itself isn't even sure if it's LLVM 3.8 on Ubuntu xenial doesn't even know an $ llc -march=amd64 -mattr=help
llc-3.8: error: invalid target 'amd64'. But it can still compile an object file for that target. Although the Crystal compiler might be changing some things in between, I don't know. |
For the point about arm/armv6/armv7, #4167 is the relevant PR. |
Oh, and most of the target triples are normalised wrong:
There's an API for LLVM C++ to normalize target triples. I suggest we bind that and normalise all triples early on in the compiler. |
I've updated the target names on the wiki page according to #7282. So at least the issues with different naming between the source folder and wiki page are fixed. Additional issues:
|
Yes @straight-shoota , I confirm I can compile statically on the |
I removed Now the wiki page should be up to date. |
I see another problem with this page: it is not self-sufficient. To understand how to compile for these architectures, you still have to get to the main documentation. Adding a reference to Also, this page relates to platform support, but the compiler itself cannot be compiled as easily. |
This page is intended as an overview of platform support. It's not a guide about cross compiling. But I suppose a link to https://crystal-lang.org/reference/syntax_and_semantics/cross-compilation.html should do? That page needs a refresh though, too.
What do you mean by that? Compiler and stdlib are different stories, yes. That's why there are separate columns for them to indicate differences. |
The platform support page was transferred in crystal-lang/crystal-book#468 and I don't think there is anything open here anymore. |
The Wiki page Platform Support was created a year ago and hasn't seen much change since then. It's still considered a draft. That doesn't need to be changed, but I noticed a few issues, mostly inconsistencies in target names between wiki page and
src/lib_c
.aarch64-linux-musl
was added in Add support for target aarch64-linux-musl #5861. I suppose it should be listed in Tier 2.x86_64-unknown-openbsd
but that target is not available. There is a folder calledamd64-unknown-openbsd
which seems like the same target. LLVM doesn't know aamd64
architecture on my system (it'sx68-64
). I suppose the target should be renamed in the source code unless there is some explicit reason for this beingamd64
?x86_64-apple-darwin
, but the source folder is calledx86_64-macosx-darwin
armv6-linux-gnueabihf
andarmv7-linux-gnueabihf
but in the source there is onlyarm-linux-gnueabihf
.x86_64-portbld-freebsd
is missing from the wiki page (it's the same asx86_64-unknown-freebsd
, though).x86_64-pc-windows-msvc
but the source folder is calledx86_64-windows-msvc
.Additionally, since musl is the only way to reliably compile with statically linked libraries, I'd suggest to improve its support level. Mainly, automatic tests would be great.#6943This shouldn't be very difficult to integrate into CI. Both travis and circle support docker images and the specs can just be executed in an alpine image for
i686-linux-musl
andx86_64-linux-musl
.For all other targets (at least on Tier 2), there could be a simple smoke test to ensure that the stdlib specs at least compile for that target. It would probably be enough to run this prior to a release (or on nightly), not on every PR.
BTW: I can't edit wiki any pages anymore. Has there been a change to access rights?
/cc @mverzilli @RX14 @bcardiff
The text was updated successfully, but these errors were encountered: