Files
nixpkgs/pkgs/development/libraries/qt-5/modules/qtlocation.nix
Silvan Mosberger 667d42c00d treewide: format all inactive Nix files
After final improvements to the official formatter implementation,
this commit now performs the first treewide reformat of Nix files using it.
This is part of the implementation of RFC 166.

Only "inactive" files are reformatted, meaning only files that
aren't being touched by any PR with activity in the past 2 months.
This is to avoid conflicts for PRs that might soon be merged.
Later we can do a full treewide reformat to get the rest,
which should not cause as many conflicts.

A CI check has already been running for some time to ensure that new and
already-formatted files are formatted, so the files being reformatted here
should also stay formatted.

This commit was automatically created and can be verified using

    nix-build a08b3a4d19.tar.gz \
      --argstr baseRev 57b193d8dd
    result/bin/apply-formatting $NIXPKGS_PATH
2024-12-10 20:27:17 +01:00

35 lines
991 B
Nix

{
lib,
stdenv,
qtModule,
qtbase,
qtmultimedia,
}:
qtModule {
pname = "qtlocation";
propagatedBuildInputs = [
qtbase
qtmultimedia
];
outputs = [
"bin"
"out"
"dev"
];
# Clang 18 treats a non-const, narrowing conversion in an initializer list as an error,
# which results in a failure building a 3rd party dependency of qtlocation. Just suppress it.
env =
lib.optionalAttrs (stdenv.cc.isClang && (lib.versionAtLeast (lib.getVersion stdenv.cc) "18"))
{
NIX_CFLAGS_COMPILE = "-Wno-c++11-narrowing-const-reference";
};
qmakeFlags = lib.optionals stdenv.hostPlatform.isDarwin [
# boost uses std::auto_ptr which has been disabled in clang with libcxx
# This flag re-enables this feature
# https://libcxx.llvm.org/docs/UsingLibcxx.html#c-17-specific-configuration-macros
"QMAKE_CXXFLAGS+=-D_LIBCPP_ENABLE_CXX17_REMOVED_AUTO_PTR"
"QMAKE_CXXFLAGS+=-D_LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION"
];
}