Skip to content

Commit

Permalink
add lib64 to path even without conda build, bump deps
Browse files Browse the repository at this point in the history
  • Loading branch information
Rob Patro committed Jul 9, 2024
1 parent 0151f71 commit 068ca5c
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 25 deletions.
10 changes: 5 additions & 5 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "piscem"
version = "0.10.0"
version = "0.10.1"
edition = "2021"
build = "build.rs"
repository = "https://github.com/COMBINE-lab/piscem"
Expand All @@ -13,7 +13,7 @@ cmake = "0.1.50"
[dependencies]
num_cpus = "1.16.0"
anyhow = "1.0.86"
clap = { version = "4.5.8", features = ["cargo", "derive", "env", "wrap_help"] }
clap = { version = "4.5.9", features = ["cargo", "derive", "env", "wrap_help"] }
tracing = "0.1.40"
tracing-subscriber = { version = "0.3.18", default-features = true, features = ["env-filter"] }
prepare_fasta = "0.1.0"
Expand Down
40 changes: 22 additions & 18 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,14 @@ fn main() {
let nopie_build = env::var("NOPIE");
let nobmi2_var = env::var("NO_BMI2");

let mut is_conda_build = false;
let is_conda_build = match conda_build {
Ok(val) => match val.to_uppercase().as_str() {
"TRUE" | "1" | "YES" => true,
"FALSE" | "0" | "NO" => false,
_ => true,
},
Err(_e) => false,
};

println!("cargo:rerun-if-changed=cuttlefish/CMakeLists.txt");
println!("cargo:rerun-if-changed=piscem-cpp/CMakeLists.txt");
Expand All @@ -27,11 +34,10 @@ fn main() {
(*cfg_cf).define("CMAKE_CXX_COMPILER", cxx_var);
}

if let Ok(_conda_build) = conda_build {
if is_conda_build {
(*cfg_cf).define("CONDA_BUILD", "TRUE");
(*cfg_cf).define("CMAKE_OSX_DEPLOYMENT_TARGET", "10.15");
(*cfg_cf).define("MACOSX_SDK_VERSION", "10.15");
is_conda_build = true;
}

if let Ok(nobmi2) = nobmi2_var {
Expand Down Expand Up @@ -67,21 +73,19 @@ fn main() {
dst_piscem_cpp.join("lib").display()
);

if is_conda_build {
// For some reason, if we are using
// conda and we are building for the
// linux target; things get put in the
// lib64 directory rather than lib...
// So, we add that here
println!(
"cargo:rustc-link-search=native={}",
dst_cf.join("lib64").display()
);
println!(
"cargo:rustc-link-search=native={}",
dst_piscem_cpp.join("lib64").display()
);
}
// For some reason, if we are using
// *some* linux distros (and on conda) and are
// building for the linux target;
// things get put in the lib64 directory
// rather than lib... So, we add that here
println!(
"cargo:rustc-link-search=native={}",
dst_cf.join("lib64").display()
);
println!(
"cargo:rustc-link-search=native={}",
dst_piscem_cpp.join("lib64").display()
);

println!("cargo:rustc-link-lib=static=kmc_core");
//println!("cargo:rustc-link-lib=static=pesc_static");
Expand Down
8 changes: 8 additions & 0 deletions src/piscem_commands.rs
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,10 @@ pub(crate) struct MapSCOpts {
#[arg(short, long, help_heading = "Input")]
pub index: String,

/// list available geometries supported by the underlying `pesc-sc` mapper
// #[arg(long, help_heading = "Advanced")]
// pub list_geometries: bool,

/// geometry of barcode, umi and read
#[arg(short, long)]
pub geometry: String,
Expand Down Expand Up @@ -332,6 +336,10 @@ impl AsArgv for MapSCOpts {
CString::new(self.output.as_str()).unwrap(),
];

/*if self.list_geometries {
args.push(CString::new("--list-geometries").unwrap());
}*/

if self.ignore_ambig_hits {
args.push(CString::new("--ignore-ambig-hits").unwrap());
} else {
Expand Down

0 comments on commit 068ca5c

Please sign in to comment.