riscv-software-src / homebrew-riscv

homebrew (macOS) packages for RISC-V toolchain
https://riscv.org
314 stars 49 forks source link

build riscv-isa-sim with boost [RFC] #71

Closed kammoh closed 2 years ago

kammoh commented 3 years ago

riscv-isa-sim build fails when boost is automatically detected, partly due to https://github.com/riscv-software-src/riscv-isa-sim/issues/820. Apparently some functionality is only supported when build with boost(?) Does it make sense to depend on boost anyways? This PR includes an ugly patch to circumvent https://github.com/riscv-software-src/riscv-isa-sim/issues/820 and to avoid dependency on autoconf@2.69 or autoupdate steps.

aswaterman commented 3 years ago

The functionality that depends on Boost--opening a socket to listen for commands--is entirely optional. Spike is supposed to build correctly and be fully functional as a simulator without Boost.

I just tried building Spike from source on my Mac (x86, Mojave) without Boost, and it was successful.

kammoh commented 3 years ago

The issue shows up only when boost is already installed and picked up by configure.

  1. Maybe boost can be disabled by default instead of being auto detected?
  2. As boost+clang+PCH is broken at least on some platforms, maybe there should be an option to disable (or better selectively enable) PCH.
aswaterman commented 3 years ago

Try using --without-boost --without-boost-asio --without-boost-regex.

If the PCH problem only manifests with boost, then I guess this sidesteps the PCH problem, too.

sbeamer commented 3 years ago

Recently, I also had problems with the Boost auto-detection on spike. I'll look into this and will probably just set the explicit flags to not use Boost.

kammoh commented 3 years ago

@aswaterman yes, I just wasn't sure if any desirable feature could be missed by disabling boost. I updated the PR to disable boost by default.

sbeamer commented 2 years ago

Thanks!!!