Skip to content

Commit

Permalink
Merge branch 'master' into seize
Browse files Browse the repository at this point in the history
  • Loading branch information
benfred authored Oct 25, 2024
2 parents e4f5774 + b098861 commit 97796a2
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 15 deletions.
11 changes: 1 addition & 10 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,6 @@ jobs:
- uses: actions/setup-python@v4
- uses: pre-commit/[email protected]

build-linux-armv7:
runs-on: [self-hosted, linux, arm]
needs: [lint]
steps:
- uses: actions/checkout@v2
- name: Build
run: cargo build --verbose --examples --features unwind
- name: Run tests
run: cargo test --verbose --features unwind

build-mac:
runs-on: macos-latest
needs: [lint]
Expand Down Expand Up @@ -105,6 +95,7 @@ jobs:
run: lscpu
- name: Install VM tools
run: |
sudo apt-get update -qq
sudo apt-get install -qq -o=Dpkg::Use-Pty=0 moreutils
sudo chronic apt-get install -qq -o=Dpkg::Use-Pty=0 vagrant virtualbox qemu libvirt-daemon-system
- name: Set up VM
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ log = "0.4"
proc-maps = "0.3.2"
read-process-memory = "0.1.6"
goblin = "0.7.1"
memmap = "0.7.0"
regex = ">=1.8.3"
cfg-if = "1.0.0"

Expand All @@ -30,6 +29,7 @@ nix = {version = "0.26", default-features = false, features = ["ptrace", "sched"
object = "0.32"
addr2line = "0.21"
lazy_static = "1.4.0"
memmap2 = "0.9.4"

[target.'cfg(windows)'.dependencies]
winapi = {version = "0.3", features = ["winbase", "consoleapi", "wincon", "handleapi", "timeapi", "processenv", "errhandlingapi" ]}
Expand Down
2 changes: 2 additions & 0 deletions build.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
use std::env;

fn main() {
println!("cargo::rustc-check-cfg=cfg(use_libunwind)");

// We only support native unwinding on some platforms
let target_arch = env::var("CARGO_CFG_TARGET_ARCH").unwrap();
match target_arch.as_str() {
Expand Down
2 changes: 1 addition & 1 deletion ci/Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Vagrant.configure("2") do |config|
chsh -s /usr/local/bin/bash vagrant
pw groupmod wheel -m vagrant
su -l vagrant <<'EOF'
curl https://sh.rustup.rs -sSf | sh -s -- -y --profile minimal --default-toolchain 1.73.0
curl https://sh.rustup.rs -sSf | sh -s -- -y --profile minimal --default-toolchain 1.81.0
EOF
SHELL
end
5 changes: 2 additions & 3 deletions src/linux/symbolication.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ use std::fs::File;
use std::path::Path;

use log::{debug, error, info, trace, warn};
use memmap;
use memmap::Mmap;
use memmap2::Mmap;

use crate::{Error, Pid, Process, StackFrame};
use addr2line::ObjectContext;
Expand Down Expand Up @@ -224,7 +223,7 @@ impl SymbolData {
info!("opening {} for symbols", filename);

let file = File::open(filename)?;
let map = unsafe { memmap::Mmap::map(&file)? };
let map = unsafe { Mmap::map(&file)? };
let file = match object::File::parse(&*map) {
Ok(f) => f,
Err(e) => {
Expand Down

0 comments on commit 97796a2

Please sign in to comment.