Change:
We define two packages, one for version 1.12 and one for version 2.0. The package for version 1.12 . Upstream has the fixes needed but only for version 2.0. The version 1.12 branch does not appear maintained, and there to it since March of 2020. We can continue to maintain this (e.g. we can disable warnings, or we can adapt those fixes to 1.12 and patch them), but perhaps we could drop support for the old version altogether? ZHF: /cc
Disabling -Werror is always reasonable, but if there's no users left in nixpkgs I think it's ok to drop it. Unless the maintainer or someone else still has a use for this (do a scream test by removing it, I guess)
is unused and can be safely removed.

Discussion:
<del> { callPackage, fetchpatch, lib, stdenv }: callPackage ./generic.nix { version = "1.12.0"; sha256 = "0f7xd66vc1lzjbn7jzd5kyqrgxpsfxi4zc7iymhb5xrwyxipjl1g"; patches = [ (fetchpatch { # Fixed a compilation error with GCC 10.0 to 11.0. June 1, 2020. # Should be included in the next release after 1.12.0 url = "https://github.com/google/flatbuffers/commit/988164f6e1675bbea9c852e2d6001baf4d1fcf59.patch"; sha256 = "0d8c2bywqmkhdi0a41cry85wy4j58pl0vd6h5xpfqm3fr8w0mi9s"; excludes = [ "src/idl_gen_cpp.cpp" ]; }) (fetchpatch { # Fixed a compilation error with GCC 10.0 to 11.0. July 6, 2020. # Should be included in the next release after 1.12.0 url = "https://github.com/google/flatbuffers/pull/6020/commits/44c7a4cf439b0a298720b5a448bcc243a882b0c9.patch"; sha256 = "126xwkvnlc4ignjhxv9jygfd9j6kr1jx39hyk0ddpcmvzfqsccf4"; }) ]; preConfigure = lib.optionalString stdenv.buildPlatform.isDarwin '' rm BUILD ''; } </del>

<del> { callPackage, fetchpatch }: callPackage ./generic.nix { version = "2.0.0"; sha256 = "1zbf6bdpps8369r1ql00irxrp58jnalycc8jcapb8iqg654vlfz8"; patches = [ # Pull patch pending upstream inclustion for gcc-12 support: #  https://github.com/google/flatbuffers/pull/6946 (fetchpatch { name = "gcc-12.patch"; url = "https://github.com/google/flatbuffers/commit/17d9f0c4cf47a9575b4f43a2ac33eb35ba7f9e3e.patch"; sha256 = "0sksk47hi7camja9ppnjr88jfdgj0nxqxy8976qs1nx73zkgbpf9"; }) ]; } </del>

<ins> { lib , stdenv , fetchFromGitHub , fetchpatch , cmake }: stdenv.mkDerivation rec { pname = "flatbuffers"; version = "2.0.0"; src = fetchFromGitHub { owner = "google"; repo = "flatbuffers"; rev = "v${version}"; sha256 = "1zbf6bdpps8369r1ql00irxrp58jnalycc8jcapb8iqg654vlfz8"; }; patches = [ # Pull patch pending upstream inclustion for gcc-12 support: # https://github.com/google/flatbuffers/pull/6946 (fetchpatch { name = "gcc-12.patch"; url = "https://github.com/google/flatbuffers/commit/17d9f0c4cf47a9575b4f43a2ac33eb35ba7f9e3e.patch"; sha256 = "0sksk47hi7camja9ppnjr88jfdgj0nxqxy8976qs1nx73zkgbpf9"; }) ]; nativeBuildInputs = [ cmake ]; cmakeFlags = [ "-DFLATBUFFERS_BUILD_TESTS=${if doCheck then "ON" else "OFF"}" ]; doCheck = stdenv.hostPlatform == stdenv.buildPlatform; checkTarget = "test"; meta = with lib; { description = "Memory Efficient Serialization Library"; longDescription = '' FlatBuffers is an efficient cross platform serialization library for games and other memory constrained apps. It allows you to directly access serialized data without unpacking/parsing it first, while still having great forwards/backwards compatibility. ''; homepage = "https://google.github.io/flatbuffers/"; license = licenses.asl20; maintainers = [ maintainers.teh ]; mainProgram = "flatc"; platforms = platforms.unix; }; } </ins>

<del> { lib , stdenv , fetchFromGitHub , cmake , version , sha256 , patches ? [ ] , preConfigure ? null }: stdenv.mkDerivation rec { pname = "flatbuffers"; inherit version; src = fetchFromGitHub { owner = "google"; repo = "flatbuffers"; rev = "v${version}"; inherit sha256; }; inherit patches preConfigure; nativeBuildInputs = [ cmake ]; cmakeFlags = [ "-DFLATBUFFERS_BUILD_TESTS=${if doCheck then "ON" else "OFF"}" ]; doCheck = stdenv.hostPlatform == stdenv.buildPlatform; checkTarget = "test"; meta = with lib; { description = "Memory Efficient Serialization Library"; longDescription = '' FlatBuffers is an efficient cross platform serialization library for games and other memory constrained apps. It allows you to directly access serialized data without unpacking/parsing it first, while still having great forwards/backwards compatibility. ''; homepage = "https://google.github.io/flatbuffers/"; license = licenses.asl20; maintainers = [ maintainers.teh ]; mainProgram = "flatc"; platforms = platforms.unix; }; } </del>

flashplayer-standalone = throw "flashplayer-standalone has been removed as Adobe Flash Player is now deprecated"; # Added 2021-02-07 flashplayer = throw "flashplayer has been removed as Adobe Flash Player is now deprecated"; # Added 2021-02-07 flashtool = throw "flashtool was removed from nixpkgs, because the download is down for copyright reasons and the site looks very fishy"; # Added 2021-06-31 <ins> flatbuffers_1_12 = throw "FlatBuffers version 1.12 has been removed, because upstream no longer maintains it"; # Added 2022-05-12 flatbuffers_2_0 = flatbuffers; # Added 2022-05-12 </ins> flink_1_5 = throw "flink_1_5 was removed, use flink instead"; # Added 2021-01-25 flutter-beta = throw "Non-stable versions of Flutter have been removed. You can use flutterPackages.mkFlutter to generate a package for other Flutter versions"; # Added 2020-01-15 flutter-dev = throw "Non-stable versions of Flutter have been removed. You can use flutterPackages.mkFlutter to generate a package for other Flutter versions"; # Added 2020-01-15

protozero = callPackage ../development/libraries/protozero { }; <del> flatbuffers = flatbuffers_2_0; flatbuffers_2_0 = callPackage ../development/libraries/flatbuffers/2.0.nix { }; flatbuffers_1_12 = callPackage ../development/libraries/flatbuffers/1.12.nix { }; </del> <ins> flatbuffers = callPackage ../development/libraries/flatbuffers { }; </ins> nanopb = callPackage ../development/libraries/nanopb { };