Merge pull request #326041 from dotlambda/materialx
This commit is contained in:
@@ -16,7 +16,6 @@
|
||||
config,
|
||||
cudaPackages,
|
||||
cudaSupport ? config.cudaSupport,
|
||||
darwin,
|
||||
dbus,
|
||||
embree,
|
||||
fetchpatch,
|
||||
@@ -55,7 +54,6 @@
|
||||
libxkbcommon,
|
||||
llvmPackages,
|
||||
makeWrapper,
|
||||
materialx,
|
||||
mesa,
|
||||
ocl-icd,
|
||||
openal,
|
||||
@@ -127,7 +125,7 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
substituteInPlace source/creator/CMakeLists.txt \
|
||||
--replace-fail '${"$"}{LIBDIR}/python' \
|
||||
'${python3}' \
|
||||
--replace-fail '${"$"}{LIBDIR}/materialx/' '${materialx}/'
|
||||
--replace-fail '${"$"}{LIBDIR}/materialx/' '${python3Packages.materialx}/'
|
||||
substituteInPlace build_files/cmake/platform/platform_apple.cmake \
|
||||
--replace-fail '${"$"}{LIBDIR}/brotli/lib/libbrotlicommon-static.a' \
|
||||
'${lib.getLib brotli}/lib/libbrotlicommon.dylib' \
|
||||
@@ -160,7 +158,7 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
"-DWITH_FFTW3=ON"
|
||||
"-DWITH_IMAGE_OPENJPEG=ON"
|
||||
"-DWITH_INSTALL_PORTABLE=OFF"
|
||||
"-DMaterialX_DIR=${materialx}/lib/cmake/MaterialX"
|
||||
"-DMaterialX_DIR=${python3Packages.materialx}/lib/cmake/MaterialX"
|
||||
"-DWITH_MOD_OCEANSIM=ON"
|
||||
"-DWITH_OPENCOLLADA=${if colladaSupport then "ON" else "OFF"}"
|
||||
"-DWITH_OPENCOLORIO=ON"
|
||||
@@ -233,7 +231,6 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
libsndfile
|
||||
libtiff
|
||||
libwebp
|
||||
materialx
|
||||
opencolorio
|
||||
openexr
|
||||
openimageio
|
||||
@@ -244,6 +241,7 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
potrace
|
||||
pugixml
|
||||
python3
|
||||
python3Packages.materialx
|
||||
tbb
|
||||
zlib
|
||||
zstd
|
||||
@@ -299,7 +297,7 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
ps = python3Packages;
|
||||
in
|
||||
[
|
||||
materialx
|
||||
ps.materialx
|
||||
ps.numpy
|
||||
ps.requests
|
||||
ps.zstandard
|
||||
|
||||
+8
-6
@@ -1,19 +1,20 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
buildPythonPackage,
|
||||
fetchFromGitHub,
|
||||
cmake,
|
||||
setuptools,
|
||||
darwin,
|
||||
libX11,
|
||||
libXt,
|
||||
libGL,
|
||||
openimageio,
|
||||
imath,
|
||||
python3Packages,
|
||||
python3
|
||||
python,
|
||||
}:
|
||||
|
||||
python3Packages.buildPythonPackage rec {
|
||||
buildPythonPackage rec {
|
||||
pname = "materialx";
|
||||
version = "1.38.10";
|
||||
|
||||
@@ -21,14 +22,14 @@ python3Packages.buildPythonPackage rec {
|
||||
owner = "AcademySoftwareFoundation";
|
||||
repo = "MaterialX";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-/kMHmW2dptZNtjuhE5s+jvPRIdtY+FRiVtMU+tiBgQo=";
|
||||
hash = "sha256-/kMHmW2dptZNtjuhE5s+jvPRIdtY+FRiVtMU+tiBgQo=";
|
||||
};
|
||||
|
||||
format = "other";
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
python3Packages.setuptools
|
||||
setuptools
|
||||
];
|
||||
|
||||
buildInputs =
|
||||
@@ -60,13 +61,14 @@ python3Packages.buildPythonPackage rec {
|
||||
|
||||
postInstall = ''
|
||||
# Make python lib properly accessible
|
||||
target_dir=$out/${python3.sitePackages}
|
||||
target_dir=$out/${python.sitePackages}
|
||||
mkdir -p $(dirname $target_dir)
|
||||
# required for cmake to find the bindings, when included in other projects
|
||||
ln -s $out/python $target_dir
|
||||
'';
|
||||
|
||||
meta = {
|
||||
changelog = "https://github.com/AcademySoftwareFoundation/MaterialX/blob/${src.rev}/CHANGELOG.md";
|
||||
description = "Open standard for representing rich material and look-development content in computer graphics";
|
||||
homepage = "https://materialx.org";
|
||||
maintainers = [ lib.maintainers.gador ];
|
||||
@@ -5735,6 +5735,8 @@ with pkgs;
|
||||
|
||||
mat2 = with python3.pkgs; toPythonApplication mat2;
|
||||
|
||||
materialx = with python3Packages; toPythonApplication materialx;
|
||||
|
||||
maxcso = callPackage ../tools/archivers/maxcso { };
|
||||
|
||||
measureme = callPackage ../development/tools/rust/measureme { };
|
||||
|
||||
@@ -7344,6 +7344,8 @@ self: super: with self; {
|
||||
|
||||
material-color-utilities = callPackage ../development/python-modules/material-color-utilities { };
|
||||
|
||||
materialx = callPackage ../development/python-modules/materialx { };
|
||||
|
||||
matchpy = callPackage ../development/python-modules/matchpy { };
|
||||
|
||||
mathlibtools = callPackage ../development/python-modules/mathlibtools { };
|
||||
|
||||
Reference in New Issue
Block a user