From 15bcfe1e0009b985266f22537b16f4a8a1fc0b25 Mon Sep 17 00:00:00 2001 From: revol-xut Date: Thu, 9 Nov 2023 11:34:06 +0100 Subject: [PATCH] fixing typo --- derivation.nix | 6 +++--- flake.lock | 24 ++++++++++++------------ src/backends/cmake.rs | 2 ++ src/package/mod.rs | 2 +- 4 files changed, 18 insertions(+), 16 deletions(-) diff --git a/derivation.nix b/derivation.nix index 0d9792c..19f9a4c 100644 --- a/derivation.nix +++ b/derivation.nix @@ -1,4 +1,4 @@ -{ naersk, src, lib, pkg-config, cmake, zlib, openssl }: +{ naersk, src, lib, pkg-config, cmake, zlib, openssl, glibc}: naersk.buildPackage { pname = "lingo"; @@ -8,8 +8,8 @@ naersk.buildPackage { cargoSha256 = lib.fakeSha256; - nativeBuildInputs = [ pkg-config cmake ]; - buildInputs = [ zlib openssl ]; + nativeBuildInputs = [ pkg-config cmake zlib openssl glibc]; + buildInputs = [ ]; meta = with lib; { description = "Simple package manager for lingua franca"; diff --git a/flake.lock b/flake.lock index c883e91..11a72f9 100644 --- a/flake.lock +++ b/flake.lock @@ -5,11 +5,11 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1688229166, - "narHash": "sha256-9lGDg8K1ASjTThzYjctdgd35WqocIIeakQXs5tAbQsM=", + "lastModified": 1698420672, + "narHash": "sha256-/TdeHMPRjjdJub7p7+w55vyABrsJlt5QkznPYy55vKA=", "owner": "nix-community", "repo": "naersk", - "rev": "714e701eb4ca2491d34d794b98be4b994a796ae7", + "rev": "aeb58d5e8faead8980a807c840232697982d47b9", "type": "github" }, "original": { @@ -20,11 +20,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1688188316, - "narHash": "sha256-CXuQllDKCxtZaB/umnZOvoJ/d4kJguYgffeTA9l1B3o=", + "lastModified": 1699343069, + "narHash": "sha256-s7BBhyLA6MI6FuJgs4F/SgpntHBzz40/qV0xLPW6A1Q=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "8277b539d371bf4308fc5097911aa58bfac1794f", + "rev": "ec750fd01963ab6b20ee1f0cb488754e8036d89d", "type": "github" }, "original": { @@ -34,11 +34,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1699186365, - "narHash": "sha256-Pxrw5U8mBsL3NlrJ6q1KK1crzvSUcdfwb9083sKDrcU=", + "lastModified": 1699343069, + "narHash": "sha256-s7BBhyLA6MI6FuJgs4F/SgpntHBzz40/qV0xLPW6A1Q=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "a0b3b06b7a82c965ae0bb1d59f6e386fe755001d", + "rev": "ec750fd01963ab6b20ee1f0cb488754e8036d89d", "type": "github" }, "original": { @@ -73,11 +73,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1687709756, - "narHash": "sha256-Y5wKlQSkgEK2weWdOu4J3riRd+kV/VCgHsqLNTTWQ/0=", + "lastModified": 1694529238, + "narHash": "sha256-zsNZZGTGnMOf9YpHKJqMSsa0dXbfmxeoJ7xHlrt+xmY=", "owner": "numtide", "repo": "flake-utils", - "rev": "dbabf0ca0c0c4bce6ea5eaf65af5cb694d2082c7", + "rev": "ff7b65b44d01cf9ba6a71320833626af21126384", "type": "github" }, "original": { diff --git a/src/backends/cmake.rs b/src/backends/cmake.rs index b71b9c6..a07b059 100644 --- a/src/backends/cmake.rs +++ b/src/backends/cmake.rs @@ -12,6 +12,7 @@ use crate::backends::{ pub struct Cmake; fn gen_cmake_files(app: &App, options: &BuildCommandOptions) -> BuildResult { + println!("ERROR: {:?}", app.src_dir_path()); let build_dir = app.output_root.join("build"); fs::create_dir_all(&build_dir)?; @@ -84,6 +85,7 @@ fn do_cmake_build(results: &mut BatchBuildResults, options: &BuildCommandOptions let cmake_binary_name = app.main_reactor.file_stem().unwrap(); // cleanup: rename executable to match the app name let bin_dir = app.output_root.join("bin"); + println!("moving {:?} to {:?}", bin_dir.join(cmake_binary_name), app.executable_path()); fs::rename(bin_dir.join(cmake_binary_name), app.executable_path())?; Ok(()) }); diff --git a/src/package/mod.rs b/src/package/mod.rs index 48afc7b..8f1db4a 100644 --- a/src/package/mod.rs +++ b/src/package/mod.rs @@ -119,7 +119,7 @@ impl App { pub fn src_dir_path(&self) -> Option { for path in self.main_reactor.ancestors() { - if path.ends_with("sec") { + if path.ends_with("src") { return Some(path.clone().to_path_buf()); } }