Unverified Commit dd598be6 authored by 7c6f434c's avatar 7c6f434c Committed by GitHub
Browse files

Merge pull request #226968 from delroth/zbar-0.23.92

zbar: 0.23.90 -> 0.23.92 (+ enable checkPhase)
parents ec84e41b fdd4f77e
Loading
Loading
Loading
Loading
+27 −2
Original line number Diff line number Diff line
@@ -24,11 +24,14 @@
, libintl
, libiconv
, Foundation
, bash
, python3
, argp-standalone
}:

stdenv.mkDerivation rec {
  pname = "zbar";
  version = "0.23.90";
  version = "0.23.92";

  outputs = [ "out" "lib" "dev" "doc" "man" ];

@@ -36,7 +39,7 @@ stdenv.mkDerivation rec {
    owner = "mchehab";
    repo = "zbar";
    rev = version;
    sha256 = "sha256-FvV7TMc4JbOiRjWLka0IhtpGGqGm5fis7h870OmJw2U=";
    sha256 = "sha256-VhVrngAX7pXZp+szqv95R6RGAJojp3svdbaRKigGb0w=";
  };

  nativeBuildInputs = [
@@ -66,6 +69,22 @@ stdenv.mkDerivation rec {
    qtx11extras
  ];

  nativeCheckInputs = [
    bash
    python3
  ];

  checkInputs = lib.optionals stdenv.isDarwin [
    argp-standalone
  ];

  # Note: postConfigure instead of postPatch in order to include some
  # autoconf-generated files. The template files for the autogen'd scripts are
  # not chmod +x, so patchShebangs misses them.
  postConfigure = ''
    patchShebangs test
  '';

  # Disable assertions which include -dev QtBase file paths.
  env.NIX_CFLAGS_COMPILE = "-DQT_NO_DEBUG";

@@ -83,6 +102,12 @@ stdenv.mkDerivation rec {
    "--without-qt"
  ]);

  doCheck = true;

  preCheck = lib.optionalString stdenv.isDarwin ''
    export NIX_LDFLAGS="$NIX_LDFLAGS -largp"
  '';

  dontWrapQtApps = true;
  dontWrapGApps = true;