Port to FreeBSD

This commit is contained in:
MikaelUrankar
2019-11-24 20:08:54 +01:00
parent 589a99452c
commit fcbdada259
12 changed files with 509 additions and 12 deletions

View File

@@ -58,6 +58,7 @@ lazy_static! {
"llvm-config".into(),
format!("llvm-config-{}", CRATE_VERSION.major),
format!("llvm-config-{}.{}", CRATE_VERSION.major, CRATE_VERSION.minor),
format!("llvm-config{}{}", CRATE_VERSION.major, CRATE_VERSION.minor),
]
};

View File

@@ -206,7 +206,10 @@ impl LLVMBackend {
let buffer = Arc::new(Buffer::LlvmMemory(memory_buffer));
#[cfg(all(any(target_os = "linux", target_os = "macos"), target_arch = "x86_64"))]
#[cfg(all(
any(target_os = "freebsd", target_os = "linux", target_os = "macos"),
target_arch = "x86_64"
))]
{
use super::stackmap::{self, StkMapRecord, StkSizeRecord};
use std::collections::BTreeMap;

View File

@@ -53,7 +53,10 @@ pub enum StackmapEntryKind {
}
impl StackmapEntry {
#[cfg(all(any(target_os = "linux", target_os = "macos"), target_arch = "x86_64"))]
#[cfg(all(
any(target_os = "freebsd", target_os = "linux", target_os = "macos"),
target_arch = "x86_64"
))]
pub fn populate_msm(
&self,
module_info: &ModuleInfo,