Opened 5 years ago
Closed 4 years ago
#60182 closed request (invalid)
port to install clang 8.1.0?
Reported by: | simon-dedeo | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | |
Keywords: | Cc: | ||
Port: |
Description
MacPorts has a port that allows us to install clang 8.0.1.
Is it possible to create a port that allows us to install the particular version of clang 8.1.0? I haven't been able to figure out how to do this myself.
Such a port would be particularly useful because that particular version of clang is necessary (!) to install CUDA support for PyTorch, i.e., to let us with older Macs use our GPUs for machine learning tasks. NVIDIA's CUDA support is very fussy. I've tried to use the XCode version of clang 8.1.0, but somehow it is not linking correctly to the OpenMPI libraries it needs. The MacPorts version does (it just crashes because the version doesn't match perfectly.)
Thank you!
Simon
Change History (7)
comment:1 Changed 5 years ago by ryandesign (Ryan Carsten Schmidt)
comment:2 Changed 5 years ago by kencu (Ken)
I am not familiar with clang-8.1.0
.
Can you point me to it?
All I know about are these <https://releases.llvm.org/> and the github repo version.
Thanks!
comment:3 Changed 5 years ago by simon-dedeo
So, it is available as part of the Mac OS X Xcode distribution. I don't know how to find it elsewhere—this is frustrating!
For some reason, when I try to use the Xcode clang 8.1.0, it starts failing to compile things correctly almost from the start. I can't figure out why.
When I use macports clang 8.0, it works great, up until it tries to install CUDA/GPU support, and then the installer quits because it demands 8.1.
It may be the case that 8.1 was made by Apple, but not officially released to the community via LLVM. That seems weird. But I can't find a place to download it at all.
comment:4 Changed 5 years ago by ryandesign (Ryan Carsten Schmidt)
As I said above, the Apple LLVM/clang versioning scheme is not the same as the open source LLVM/clang versioning scheme. Apple LLVM/clang and open source LLVM/clang are two different products. They have diverged from one another over time and are developed by different teams of developers who have decided to number their versions differently.
Xcode 8.3 was released in March 2017 and contained Apple LLVM/clang 8.1.0. At that time, the current version of open source LLVM/clang was 4.0.0. So Apple LLVM/clang 8.1.0 is comparable to (but not identical to) open source LLVM/clang 4.0.0 (or possibly the previous version, 3.9.1). There may be features or bugs present in one that are not present in the other and vice versa
Open source LLVM/clang 8.0.0 was not released until March 2019. The next version of Xcode after that time was Xcode 10.2 released in May 2019 containing Apple LLVM/clang 10.0.1. There was an open source LLVM/clang 8.0.1 released in July 2019 but we cannot find any evidence of the existence of open source LLVM/clang 8.1.0.
If the software you are trying to build says it requires clang 8.1.0, then I can only assume that refers to Apple LLVM/clang 8.1.0, since there does not appear to be any such thing as open source LLVM/clang 8.1.0. The best place to get Apple LLVM/clang 8.1.0 is by installing Xcode 8.3.x (on a version of macOS that supports it). If the program nevertheless does not build with Apple LLVM/clang 8.1.0 despite the developers' claims that it will, that's something you'll have to take up with those developers.
comment:5 Changed 5 years ago by ryandesign (Ryan Carsten Schmidt)
Additionally, you may need to make the developers of that software aware of the existence of the two LLVM/clang version numbering schemes. It may be that open source LLVM/clang 4.0.0 and later would build the software just fine if the version restriction were removed from their build system.
comment:6 Changed 5 years ago by kencu (Ken)
If possible, you may want to try letting us have a go with the software build. It is possible we might get you sorted out.
Ryan did a nice explanation. My back of the envelope figuring uses something like this:
xcode 300s is about equal to open source llvm/clang 3.3 xcode 400s is about equal to opwn source llvm/clang 3.4 ... xcode 800s is about equal to open source llvm/clang 3.8 xcode 900s is about equal to open soutce llvm/clang 3.9
and that broke down with xcode in the 1000s, which is about equal to llvm/clang 6.0
Apple's forks of llvm/clang are available in Apple's github repo. Last I checked, there are about 10,000 commits different added. Apple rebases on top of the llvm trunk regularly...what an effort to maintain!
comment:7 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → invalid |
---|---|
Status: | new → closed |
I am not able to find a clang 8.1.0 at https://releases.llvm.org/download.html. If such a version of open source clang existed, the clang-8.0 port should be updated to it.
The Xcode clang versioning scheme is not the same as the open source clang versioning scheme. Please verify whether the CUDA PyTorch clang version requirement refers to an Xcode clang version or an open source clang version.