lol

frozen: init at unstable-2021-02-23

frozen is a small JSON parser and generator library,
targeted at embedded use-cases. As it only uses two
source files, add meson.build on the fly to enable
cross compilation.

Signed-off-by: Markus Theil <theil.markus@gmail.com>

authored by

Markus Theil and committed by
Anderson Torres
aba5b377 0bd643d5

+58
+37
pkgs/development/libraries/frozen/default.nix
··· 1 + { lib 2 + , stdenv 3 + , fetchFromGitHub 4 + , meson 5 + , ninja 6 + }: 7 + 8 + stdenv.mkDerivation rec { 9 + pname = "frozen"; 10 + # pin to a newer release if frozen releases again, see cesanta/frozen#72 11 + version = "unstable-2021-02-23"; 12 + 13 + src = fetchFromGitHub { 14 + owner = "cesanta"; 15 + repo = "frozen"; 16 + rev = "21f051e3abc2240d9a25b2add6629b38e963e102"; 17 + hash = "sha256-BpuYK9fbWSpeF8iPT8ImrV3CKKaA5RQ2W0ZQ03TciR0="; 18 + }; 19 + 20 + nativeBuildInputs = [ meson ninja ]; 21 + 22 + # frozen has a simple Makefile and a GN BUILD file as building scripts. 23 + # Since it has only two source files, the best course of action to support 24 + # cross compilation is to create a small meson.build file. 25 + # Relevant upstream issue: https://github.com/cesanta/frozen/pull/71 26 + preConfigure = '' 27 + cp ${./meson.build} meson.build 28 + ''; 29 + 30 + meta = { 31 + homepage = "https://github.com/cesanta/frozen"; 32 + description = "Minimal JSON parser for C, targeted for embedded systems"; 33 + license = lib.licenses.asl20; 34 + maintainers = with lib.maintainers; [ thillux ]; 35 + platforms = lib.platforms.unix; 36 + }; 37 + }
+19
pkgs/development/libraries/frozen/meson.build
··· 1 + project( 2 + 'frozen', 3 + 'c', 4 + default_options: [ 5 + 'c_args=-Wextra -fno-builtin -pedantic', 6 + 'c_std=c99', 7 + 'werror=true' 8 + ], 9 + license: 'Apache-2.0', 10 + version: '20210223' 11 + ) 12 + 13 + library( 14 + 'frozen', 15 + 'frozen.c', 16 + install: true 17 + ) 18 + 19 + install_headers('frozen.h')
+2
pkgs/top-level/all-packages.nix
··· 21204 21204 21205 21205 fribidi = callPackage ../development/libraries/fribidi { }; 21206 21206 21207 + frozen = callPackage ../development/libraries/frozen { }; 21208 + 21207 21209 funambol = callPackage ../development/libraries/funambol { }; 21208 21210 21209 21211 function-runner = callPackage ../development/web/function-runner { };