mirror of
https://github.com/roapi/roapi.git
synced 2026-06-05 21:04:02 +08:00
30 lines
884 B
Nix
30 lines
884 B
Nix
{
|
|
description = "ROAPI";
|
|
inputs = {
|
|
nixpkgs.url = "github:NixOS/nixpkgs/release-24.11";
|
|
flake-utils.url = "github:numtide/flake-utils";
|
|
};
|
|
|
|
outputs = { self, nixpkgs, flake-utils }:
|
|
flake-utils.lib.eachDefaultSystem
|
|
(system:
|
|
let pkgs = nixpkgs.legacyPackages.${system}; in
|
|
{
|
|
devShells.default = pkgs.mkShell {
|
|
name = "roapi";
|
|
buildInputs = [
|
|
# for databases feature
|
|
pkgs.openssl
|
|
pkgs.pkg-config
|
|
];
|
|
shellHook = ''
|
|
export OPENSSL_DIR="${pkgs.openssl.dev}"
|
|
export OPENSSL_LIB_DIR="${pkgs.openssl.out}/lib"
|
|
export OPENSSL_INCLUDE_DIR="${pkgs.openssl.dev}/include"
|
|
export PKG_CONFIG_PATH="${pkgs.openssl.dev}/lib/pkgconfig:$PKG_CONFIG_PATH"
|
|
'';
|
|
};
|
|
}
|
|
);
|
|
}
|