at 23.05-pre 44 lines 1.4 kB view raw
1{ lib, stdenv, fetchFromGitHub, autoreconfHook, flex }: 2 3stdenv.mkDerivation rec { 4 pname = "libconfuse"; 5 version = "3.3"; 6 7 src = fetchFromGitHub { 8 sha256 = "1npfk5jv59kk4n8pkyx89fn9s6p8x3gbffs42jaw24frgxfgp8ca"; 9 rev = "v${version}"; 10 repo = "libconfuse"; 11 owner = "martinh"; 12 }; 13 14 postPatch = '' 15 substituteInPlace tests/Makefile.am \ 16 --replace 'TESTS += empty_string' "" \ 17 --replace 'TESTS += print_filter' "" 18 ''; 19 20 nativeBuildInputs = [ autoreconfHook flex ]; 21 22 enableParallelBuilding = true; 23 24 # On darwin the tests depend on the installed libraries because of install_name. 25 doInstallCheck = true; 26 installCheckTarget = "check"; 27 28 meta = with lib; { 29 inherit (src.meta) homepage; 30 description = "Small configuration file parser library for C"; 31 longDescription = '' 32 libConfuse (previously libcfg) is a configuration file parser library 33 written in C. It supports sections and (lists of) values, as well as 34 some other features. It makes it very easy to add configuration file 35 capability to a program using a simple API. 36 37 The goal of libConfuse is not to be the configuration file parser library 38 with a gazillion of features. Instead, it aims to be easy to use and 39 quick to integrate with your code. 40 ''; 41 license = licenses.isc; 42 platforms = platforms.linux ++ platforms.darwin; 43 }; 44}