Compare commits

..

No commits in common. "4962f12867b0b6c4c4d39b98e6016e7f925a802c" and "8a7923bd4e5d36b186408d5432568a91ac67b695" have entirely different histories.

2 changed files with 32 additions and 42 deletions

8
flake.lock generated
View File

@ -2,10 +2,10 @@
"nodes": { "nodes": {
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1737299813, "lastModified": 1718318537,
"narHash": "sha256-Qw2PwmkXDK8sPQ5YQ/y/icbQ+TYgbxfjhgnkNJyT1X8=", "narHash": "sha256-4Zu0RYRcAY/VWuu6awwq4opuiD//ahpc2aFHg2CWqFY=",
"path": "/nix/store/sbnwhhx7zjp45n53bkmnj4whg79aw8pq-source", "path": "/nix/store/qqwr649pc0qprc9lw2fmdsi1km6p7q2h-source",
"rev": "107d5ef05c0b1119749e381451389eded30fb0d5", "rev": "e9ee548d90ff586a6471b4ae80ae9cfcbceb3420",
"type": "path" "type": "path"
}, },
"original": { "original": {

View File

@ -1,44 +1,34 @@
{ {
description = "zremap nix flake"; description = "zremap nix flake";
outputs = outputs = {
{ self,
self, nixpkgs,
nixpkgs, }: {
}: defaultPackage.x86_64-linux = with import nixpkgs {system = "x86_64-linux";};
{ stdenv.mkDerivation {
defaultPackage.x86_64-linux = pname = "zremap";
with import nixpkgs { system = "x86_64-linux"; }; version = "0.2";
stdenv.mkDerivation { src = self;
pname = "zremap"; nativeBuildInputs = [zig.hook];
version = "0.2"; buildInputs = [libevdev pkg-config];
src = self; buildPhase = ''
nativeBuildInputs = [ zig.hook ]; NIX_CFLAGS_COMPILE="-static -isystem $(pkg-config --variable=includedir libevdev)/libevdev-1.0 $NIX_CFLAGS_COMPILE"
buildInputs = [ '';
libevdev };
pkg-config
];
buildPhase = ''
NIX_CFLAGS_COMPILE="-static -isystem $(pkg-config --variable=includedir libevdev)/libevdev-1.0 $NIX_CFLAGS_COMPILE"
'';
};
devShells.x86_64-linux.default = devShells.x86_64-linux.default = with import nixpkgs {system = "x86_64-linux";};
with import nixpkgs { system = "x86_64-linux"; }; mkShell {
mkShell { nativeBuildInputs = [zig_0_12 lldb];
nativeBuildInputs = [ buildInputs = [
zig libevdev
lldb pkg-config
]; ];
buildInputs = [
libevdev
pkg-config
];
shellHook = '' shellHook = ''
NIX_CFLAGS_COMPILE="-isystem $(pkg-config --variable=includedir libevdev)/libevdev-1.0 $NIX_CFLAGS_COMPILE" NIX_CFLAGS_COMPILE="-isystem $(pkg-config --variable=includedir libevdev)/libevdev-1.0 $NIX_CFLAGS_COMPILE"
echo "happy hacking!" echo "happy hacking!"
''; '';
}; };
}; };
} }