forked from mmtk/mmtk-julia
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding
GC: MMTk
tag to Julia's banner when building with MMTk (mmtk…
…#193) Merge with mmtk/julia#72. Should add info to Julia's banner about the version of MMTk used in the build such as: ``` _ _ _ _(_)_ | Documentation: https://docs.julialang.org (_) | (_) (_) | _ _ _| |_ __ _ | Type "?" for help, "]?" for Pkg help. | | | | | | |/ _` | | | | |_| | | | (_| | | Version 1.12.0-DEV.955 (2024-11-26) _/ |\__'_|_|_|\__'_| | adding-tag-to-banner/0ccc307863* (fork: 101 commits, 134 days) |__/ | Built with MMTk Julia 0.1.0 (a775934-dirty), using MMTk 0.27.0 (de10fa4, DEFAULT, IMMIX_NON_MOVING, IMMIX_SMALLER_BLOCK, OBJECT_PINNING, VM_SPACE) ```
- Loading branch information
Showing
6 changed files
with
30 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
use std::ffi::CString; | ||
|
||
mod raw { | ||
// The include imports a full list of the constants in built.rs from https://docs.rs/built/latest/built/index.html | ||
include!(concat!(env!("OUT_DIR"), "/built.rs")); | ||
} | ||
|
||
lazy_static! { | ||
// Owned string for the binding version, such as MMTk Julia 0.14.0 (cfc755f-dirty) | ||
static ref BINDING_VERSION_STRING: String = match (raw::GIT_COMMIT_HASH, raw::GIT_DIRTY) { | ||
(Some(hash), Some(dirty)) => format!("Built with MMTk Julia {} ({}{})", raw::PKG_VERSION, hash.split_at(7).0, if dirty { "-dirty" } else { "" }), | ||
(Some(hash), None) => format!("Built with MMTk Julia {} ({}{})", raw::PKG_VERSION, hash.split_at(7).0, "-?"), | ||
_ => format!("Built with MMTk Julia {}", raw::PKG_VERSION), | ||
}; | ||
// Owned string for both binding and core version. | ||
#[derive(Debug)] | ||
pub static ref MMTK_JULIA_FULL_VERSION_STRING: CString = CString::new(format!("{}, using {}", *BINDING_VERSION_STRING, *mmtk::build_info::MMTK_FULL_BUILD_INFO)).unwrap(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters