Skip to content

Commit

Permalink
Merge #3396
Browse files Browse the repository at this point in the history
3396: Fix build doc and minimum-sys build r=ptitSeb a=ptitSeb

# Description
* Fix build-doc that was not working if only LLVM-13 is installed and `llvm-config` is not available (only `llvm-config-13` is)
* Fix minimum-sys build
* Forced libncurses5 in linux-x64 OS used by [CI] for build, as the custom build of LLVM needs libtinfo5 to run.

Co-authored-by: ptitSeb <[email protected]>
  • Loading branch information
bors[bot] and ptitSeb authored Dec 1, 2022
2 parents df8307e + ae6ffb2 commit a565e73
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,14 @@ env:
jobs:
lint:
name: Code lint
runs-on: ubuntu-latest
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v3
- name: Set up libstdc++ on Linux
run: |
sudo apt-get update -y
sudo apt-get install -y --allow-downgrades libstdc++6=8.4.0-1ubuntu1~18.04
sudo apt-get install --reinstall g++-8
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
Expand Down
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,8 @@ else ifeq ($(ENABLE_LLVM), 1)
else ifneq (, $(shell which llvm-config-13 2>/dev/null))
LLVM_VERSION := $(shell llvm-config-13 --version)
compilers += llvm
# need force LLVM_SYS_120_PREFIX, or llvm_sys will not build in the case
export LLVM_SYS_120_PREFIX = $(shell llvm-config-13 --prefix)
else ifneq (, $(shell which llvm-config-12 2>/dev/null))
LLVM_VERSION := $(shell llvm-config-12 --version)
compilers += llvm
Expand Down
4 changes: 4 additions & 0 deletions lib/api/src/sys/store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -197,24 +197,28 @@ impl AsStoreMut for Store {
}
}

#[cfg(feature = "compiler")]
impl AsEngineRef for Store {
fn as_engine_ref(&self) -> EngineRef<'_> {
EngineRef::new(&self.engine)
}
}

#[cfg(feature = "compiler")]
impl AsEngineRef for &Store {
fn as_engine_ref(&self) -> EngineRef<'_> {
EngineRef::new(&self.engine)
}
}

#[cfg(feature = "compiler")]
impl AsEngineRef for StoreRef<'_> {
fn as_engine_ref(&self) -> EngineRef<'_> {
EngineRef::new(&self.inner.engine)
}
}

#[cfg(feature = "compiler")]
impl AsEngineRef for StoreMut<'_> {
fn as_engine_ref(&self) -> EngineRef<'_> {
EngineRef::new(&self.inner.engine)
Expand Down

0 comments on commit a565e73

Please sign in to comment.