tfcconnection-zola/default.nix

100 lines
1.5 KiB
Nix

{
stdenv,
lib,
hugo,
go,
cargo,
rustc,
clippy,
rust-analyzer,
rustfmt,
pkg-config,
# sbcl,
# sbclPackages,
makeWrapper,
openssl,
rustPlatform
}:
# let
# sbcl' = sbcl.withPackages (ps: with ps; [
# hunchentoot
# dexador
# jzon
# serapeum
# deploy
# spinneret
# lass
# cl-smtp
# # pkgs.openssl
# # pkgs.openssl.out
# # pkgs.openssl.dev
# ]);
# in
rustPlatform.buildRustPackage rec {
name = "tfcconnection";
pname = "tfcconnection";
version = "0.0.1";
src = ./.;
# cargoHash = "sha256-jtBw4ahSl88L0iuCXxQgZVm1EcboWRJMNtjxLVTtzts=";
cargoLock = {
lockFile = ./Cargo.lock;
};
nativeBuildInputs = [
makeWrapper
pkg-config
rustc
cargo
];
buildInputs = [
# rustPlatform
# clippy
# rustfmt
openssl
# openssl.out
# openssl.dev
];
# nativeLibs = [
# openssl
# openssl.out
# openssl.dev
# ];
# lispLibs = with sbclPackages; [
# hunchentoot
# dexador
# jzon
# serapeum
# deploy
# spinneret
# lass
# cl-smtp
# ];
buildPhase = ''
export HOME=$(pwd)
${cargo}/bin/cargo build
'';
installPhase = ''
mkdir -p $out/bin
cp target/debug/tfcapi $out/bin
wrapProgram $out/bin/tfcapi \
--prefix LD_LIBRARY_PATH : $LD_LIBRARY_PATH \
'';
meta = with lib; {
name = "tfcconnection";
description = "TFC Connection Website";
homepage = "https://tfcconnection.org";
license = licenses.gpl3;
maintainers = [ "chriscochrun" ];
platforms = platforms.all;
};
}