1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 cmake,
6}:
7
8stdenv.mkDerivation rec {
9 pname = "ada";
10 version = "3.2.7";
11
12 src = fetchFromGitHub {
13 owner = "ada-url";
14 repo = "ada";
15 tag = "v${version}";
16 hash = "sha256-IDJgrjmIqhnIZuzBAckowpmhRypb1a1NB1P5YZz4E1A=";
17 };
18
19 nativeBuildInputs = [ cmake ];
20
21 cmakeFlags = [
22 # uses CPM that requires network access
23 (lib.cmakeBool "ADA_TOOLS" false)
24 (lib.cmakeBool "ADA_TESTING" false)
25 ];
26
27 meta = {
28 description = "WHATWG-compliant and fast URL parser written in modern C";
29 homepage = "https://github.com/ada-url/ada";
30 license = with lib.licenses; [
31 asl20
32 mit
33 ];
34 maintainers = with lib.maintainers; [ nickcao ];
35 platforms = lib.platforms.all;
36 };
37}