semarie / build-rust

Script helper for building rustc and cargo from source on OpenBSD (without rustup)
59 stars 15 forks source link

fails to build beta on openbsd6.6/amd64 #12

Closed tera-torn closed 4 years ago

tera-torn commented 4 years ago

tried on two different openbsd6.6/amd64 boxes - same errors. errors don't really make sense to me and google isn't much help.

I would really appreciate any help understanding the problem or figuring out a workaround. Thanks for making build-rust - I really wish it worked for me, and would love to help fix this (I know it may not be the script's fault.. probably isn't.. but we'll see)

build.log

error: cannot find attribute macro `rustc_diagnostic_item` in this scope
   --> src/libcore/fmt/mod.rs:521:3
    |
521 | #[rustc_diagnostic_item = "debug_trait"]
    |   ^^^^^^^^^^^^^^^^^^^^^

error[E0522]: definition of an unknown language item: `bool`
 --> src/libcore/bool.rs:3:1
  |
3 | #[lang = "bool"]
  | ^^^^^^^^^^^^^^^^ definition of unknown language item `bool`

error[E0118]: no base type found for inherent implementation
 --> src/libcore/bool.rs:4:6
  |
4 | impl bool {
  |      ^^^^ impl requires a base type
  |
  = note: either implement a trait on it or create a newtype to wrap it instead

error: aborting due to 3 previous errors
semarie commented 4 years ago

From build.log:

Mon Dec  9 23:40:10 CST 2019: info: required stage0:
        date: 2019-11-07
        rustc: 1.39.0
        cargo: 0.40.0
Mon Dec  9 23:40:10 CST 2019: info: rustc -vV
        rustc 1.38.0
        binary: rustc
        commit-hash: unknown
        commit-date: unknown
        host: x86_64-unknown-openbsd
        release: 1.38.0
        LLVM version: 8.0

you are trying to build 1.40.0-beta.5 with 1.38.0. It isn't supported by rust itself. For building 1.40.0 you need to first have 1.39.0.

Regarding OpenBSD itself, 6.6 doesn't have 1.39.0 in ports (and will not). Only -current will have it. Eventually, you could try to build lang/rust from current on 6.6 (it should work, even if it is an unsupported configuration).

tera-torn commented 4 years ago

Good to know. I'll try to build some intermediate compilers first. Thanks!