···11+{ lib
22+, stdenv
33+, fetchFromGitHub
44+, cmake
55+}:
66+77+stdenv.mkDerivation rec {
88+ pname = "argagg";
99+ version = "0.4.6";
1010+1111+ src = fetchFromGitHub {
1212+ owner = "vietjtnguyen";
1313+ repo = pname;
1414+ rev = version;
1515+ hash = "sha256-MCtlAPfwdJpgfS8IH+zlcgaaxZ5AsP4hJvbZAFtOa4o=";
1616+ };
1717+1818+ patches = [
1919+ # Fix compilation of macro catch statement
2020+ ./0001-catch.diff
2121+ ];
2222+2323+ nativeBuildInputs = [
2424+ cmake
2525+ ];
2626+2727+ meta = with lib; {
2828+ homepage = "https://github.com/vietjtnguyen/argagg";
2929+ description = "Argument Aggregator";
3030+ longDescription = ''
3131+ argagg is yet another C++ command line argument/option parser. It was
3232+ written as a simple and idiomatic alternative to other frameworks like
3333+ getopt, Boost program options, TCLAP, and others. The goal is to achieve
3434+ the majority of argument parsing needs in a simple manner with an easy to
3535+ use API. It operates as a single pass over all arguments, recognizing
3636+ flags prefixed by - (short) or -- (long) and aggregating them into easy to
3737+ access structures with lots of convenience functions. It defers processing
3838+ types until you access them, so the result structures end up just being
3939+ pointers into the original command line argument C-strings.
4040+ '';
4141+ license = licenses.mit;
4242+ maintainers = with maintainers; [ AndersonTorres ];
4343+ platforms = with platforms; all;
4444+ badPlatforms = [ "aarch64-darwin" ];
4545+ };
4646+}