Merge pull request #238393 from NickCao/assimp

assimp: fix build for riscv
This commit is contained in:
Weijia Wang 2023-06-20 03:23:05 +03:00 committed by GitHub
commit 457b8200c1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
version = "5.2.5";
outputs = [ "out" "lib" "dev" ];
src = fetchFromGitHub{
src = fetchFromGitHub {
owner = "assimp";
repo = "assimp";
rev = "v${version}";
@ -23,10 +23,12 @@ stdenv.mkDerivation rec {
cmakeFlags = [ "-DASSIMP_BUILD_ASSIMP_TOOLS=ON" ];
env.NIX_CFLAGS_COMPILE = toString [
env.NIX_CFLAGS_COMPILE = toString ([
# Needed with GCC 12
"-Wno-error=array-bounds"
];
] ++ lib.optionals stdenv.hostPlatform.isRiscV [
"-Wno-error=free-nonheap-object"
]);
meta = with lib; {
description = "A library to import various 3D model formats";