mirror of
https://github.com/serai-dex/serai.git
synced 2025-01-31 06:55:56 +00:00
42d62c38b9
* Remove the Monero CMake and make * Download the Monero daemon instead of building it * Cache the Monero daemon Prevents hammering the Monero servers, should reduce CI time. * Correct YAML * Add back sodium-dev * Create an independent job for downloading the Monero daemon Improves parallelism while decreasing the amount of work re-done if build fails. Also increases modularity. * Correct Monero job definition * Correct skipping the Monero download on cache hit
52 lines
1.5 KiB
Rust
52 lines
1.5 KiB
Rust
use std::process::Command;
|
|
|
|
fn main() {
|
|
if !Command::new("git")
|
|
.args(&["submodule", "update", "--init", "--recursive"])
|
|
.status()
|
|
.unwrap()
|
|
.success()
|
|
{
|
|
panic!("git failed to init submodules");
|
|
}
|
|
|
|
println!("cargo:rerun-if-changed=c/wrapper.cpp");
|
|
#[rustfmt::skip]
|
|
cc::Build::new()
|
|
.static_flag(true)
|
|
.warnings(false)
|
|
.extra_warnings(false)
|
|
.flag("-Wno-deprecated-declarations")
|
|
|
|
.include("c/monero/external/supercop/include")
|
|
.include("c/monero/contrib/epee/include")
|
|
.include("c/monero/src")
|
|
.include("c/monero/build/release/generated_include")
|
|
|
|
.define("AUTO_INITIALIZE_EASYLOGGINGPP", None)
|
|
.include("c/monero/external/easylogging++")
|
|
.file("c/monero/external/easylogging++/easylogging++.cc")
|
|
|
|
.file("c/monero/src/common/aligned.c")
|
|
.file("c/monero/src/common/perf_timer.cpp")
|
|
|
|
.include("c/monero/src/crypto")
|
|
.file("c/monero/src/crypto/crypto-ops-data.c")
|
|
.file("c/monero/src/crypto/crypto-ops.c")
|
|
.file("c/monero/src/crypto/keccak.c")
|
|
.file("c/monero/src/crypto/hash.c")
|
|
|
|
.include("c/monero/src/ringct")
|
|
.file("c/monero/src/ringct/rctCryptoOps.c")
|
|
.file("c/monero/src/ringct/rctTypes.cpp")
|
|
.file("c/monero/src/ringct/rctOps.cpp")
|
|
.file("c/monero/src/ringct/multiexp.cc")
|
|
.file("c/monero/src/ringct/bulletproofs.cc")
|
|
.file("c/monero/src/ringct/rctSigs.cpp")
|
|
|
|
.file("c/wrapper.cpp")
|
|
.compile("wrapper");
|
|
|
|
println!("cargo:rustc-link-lib=wrapper");
|
|
println!("cargo:rustc-link-lib=stdc++");
|
|
}
|