Accepting request 663570 from home:plater:blender
New package for blender cycles with OSL see: boo#1120406 OBS-URL: https://build.opensuse.org/request/show/663570 OBS-URL: https://build.opensuse.org/package/show/graphics/OpenShadingLanguage?expand=0&rev=1
This commit is contained in:
commit
27c573a900
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
.osc
|
3
OpenShadingLanguage-Release-1.9.13.tar.gz
Normal file
3
OpenShadingLanguage-Release-1.9.13.tar.gz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:2bcd1d835f210dbc9e73f1d8892bb15c067d269cbb7b77d9fe5054e2f4fee394
|
||||
size 15451839
|
21
OpenShadingLanguage-shaderinstalldir.patch
Normal file
21
OpenShadingLanguage-shaderinstalldir.patch
Normal file
@ -0,0 +1,21 @@
|
||||
Index: src/shaders/CMakeLists.txt
|
||||
===================================================================
|
||||
--- src/shaders/CMakeLists.txt.orig 2018-12-02 04:00:52.000000000 +0200
|
||||
+++ src/shaders/CMakeLists.txt 2019-01-02 12:32:36.665656281 +0200
|
||||
@@ -63,4 +63,4 @@ add_custom_target (shaders ALL
|
||||
SOURCES ${shader_source} ${shader_headers})
|
||||
|
||||
install (FILES ${shader_headers} ${shader_source} ${shader_objs}
|
||||
- DESTINATION shaders)
|
||||
+ DESTINATION ${CMAKE_INSTALL_DATADIR}/shaders)
|
||||
Index: src/shaders/MaterialX/CMakeLists.txt
|
||||
===================================================================
|
||||
--- src/shaders/MaterialX/CMakeLists.txt.orig 2018-12-02 04:00:52.000000000 +0200
|
||||
+++ src/shaders/MaterialX/CMakeLists.txt 2019-01-02 12:50:34.020012017 +0200
|
||||
@@ -196,5 +196,5 @@ add_custom_target (mxshaders ALL
|
||||
SOURCES ${shader_source} ${mx_shader_headers})
|
||||
|
||||
install (FILES ${mx_shader_headers} ${mx_shader_objs} ${mx_shader_osls}
|
||||
- DESTINATION shaders/MaterialX)
|
||||
+ DESTINATION ${CMAKE_INSTALL_DATADIR}/shaders/MaterialX)
|
||||
|
8
OpenShadingLanguage.changes
Normal file
8
OpenShadingLanguage.changes
Normal file
@ -0,0 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 31 11:35:09 UTC 2018 - davejplater@gmail.com
|
||||
|
||||
- Initial version 1.9.13 created for blender see boo#1120406
|
||||
- Blender fails to build with 1.10.x versions
|
||||
- Added OpenShadingLanguage-shaderinstalldir.patch shaders are
|
||||
installed directly under /usr see:
|
||||
https://github.com/imageworks/OpenShadingLanguage/issues/955
|
240
OpenShadingLanguage.spec
Normal file
240
OpenShadingLanguage.spec
Normal file
@ -0,0 +1,240 @@
|
||||
#
|
||||
# spec file for package OpenShadingLanguage
|
||||
#
|
||||
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
# The library soname versions follow the package version major and minor numbers.
|
||||
%define sover %(echo %{version} | cut -d . -f 1,2)
|
||||
%define sufx %(echo %{sover}|tr . _)
|
||||
|
||||
#NOTE: This package was created for blender, blender doesn't build against
|
||||
# the 1.10.x ABI. If there is the need to update to such a version please consult me
|
||||
# first davejplater@gmail.com or suffix the package with a 110 or something.
|
||||
|
||||
Name: OpenShadingLanguage
|
||||
Version: 1.9.13
|
||||
Release: 0
|
||||
Summary: A language for programmable shading
|
||||
License: BSD-3-Clause
|
||||
Group: Productivity/Graphics/Other
|
||||
Url: https://github.com/imageworks/OpenShadingLanguage
|
||||
Source0: https://github.com/imageworks/OpenShadingLanguage/archive/Release-%{version}.tar.gz#/%{name}-Release-%{version}.tar.gz
|
||||
#PATCH-FIX-UPSTREAM OpenShadingLanguage-shaderinstalldir.patch - davejplater@gmail.com - shaders are installed directly under /usr
|
||||
#https://github.com/imageworks/OpenShadingLanguage/issues/955
|
||||
Patch0: OpenShadingLanguage-shaderinstalldir.patch
|
||||
BuildRequires: bison
|
||||
BuildRequires: cmake
|
||||
BuildRequires: cmake(pugixml)
|
||||
BuildRequires: clang5-devel
|
||||
BuildRequires: flex
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: libboost_atomic-devel
|
||||
BuildRequires: libboost_filesystem-devel
|
||||
BuildRequires: libboost_locale-devel
|
||||
BuildRequires: libboost_regex-devel
|
||||
BuildRequires: libboost_thread-devel
|
||||
BuildRequires: libboost_wave-devel
|
||||
BuildRequires: OpenImageIO-devel
|
||||
BuildRequires: OpenEXR-devel
|
||||
BuildRequires: python
|
||||
Recommends: %{name}-doc = %{version}
|
||||
|
||||
%description
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
This package contains binaries.
|
||||
|
||||
%package doc
|
||||
Summary: Headers for shading
|
||||
Group: Documentation/Other
|
||||
Requires: %{name} = %{version}
|
||||
|
||||
%description doc
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
This package contains documentation.
|
||||
|
||||
%package shaders-devel
|
||||
Summary: Headers for shading
|
||||
Group: Development/Languages/Other
|
||||
Requires: %{name} = %{version}
|
||||
|
||||
%description shaders-devel
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
This package contains shaders and headers used by OSL.
|
||||
|
||||
%package -n liboslcomp%{sufx}
|
||||
Summary: Osl library
|
||||
Group: System/Libraries
|
||||
|
||||
%description -n liboslcomp%{sufx}
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
|
||||
%package -n liboslexec%{sufx}
|
||||
Summary: Osl library
|
||||
Group: System/Libraries
|
||||
|
||||
%description -n liboslexec%{sufx}
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
|
||||
%package -n liboslnoise%{sufx}
|
||||
Summary: Osl library
|
||||
Group: System/Libraries
|
||||
|
||||
%description -n liboslnoise%{sufx}
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
|
||||
%package -n liboslquery%{sufx}
|
||||
Summary: Osl library
|
||||
Group: System/Libraries
|
||||
|
||||
%description -n liboslquery%{sufx}
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
|
||||
%package -n libtestshade%{sufx}
|
||||
Summary: Osl library
|
||||
Group: System/Libraries
|
||||
|
||||
%description -n libtestshade%{sufx}
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
|
||||
%package -n osl.imageio%{sufx}
|
||||
Summary: Osl library
|
||||
Group: System/Libraries
|
||||
|
||||
%description -n osl.imageio%{sufx}
|
||||
Open Shading Language (OSL) is a small but rich language for
|
||||
programmable shading in advanced renderers and other applications,
|
||||
ideal for describing materials, lights, displacement, and pattern
|
||||
generation.
|
||||
|
||||
%package devel
|
||||
Summary: Development files for %{name}
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: %{name} = %{version}
|
||||
Requires: liboslcomp%{sufx} = %{version}
|
||||
Requires: liboslexec%{sufx} = %{version}
|
||||
Requires: liboslnoise%{sufx} = %{version}
|
||||
Requires: liboslquery%{sufx} = %{version}
|
||||
Requires: libtestshade%{sufx} = %{version}
|
||||
Requires: osl.imageio%{sufx} = %{version}
|
||||
|
||||
%description devel
|
||||
The %{name}-devel package contains libraries and header files for
|
||||
developing applications that use %{name}.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{name}-Release-%{version}
|
||||
# Shaders and includes for OSL are installed in $PREFIX/shaders
|
||||
%patch0
|
||||
|
||||
%build
|
||||
%cmake \
|
||||
-DLLVM_MCJIT_LIBRARY:FILEPATH=%{_libdir}/libLLVM.so \
|
||||
-DCMAKE_INSTALL_DOCDIR:PATH=%{_docdir}/%{name} \
|
||||
-DCMAKE_INSTALL_DATADIR:PATH=%{_datadir}/%{name}
|
||||
|
||||
make %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
%cmake_install
|
||||
|
||||
find %{buildroot} -name LICENSE -print -delete
|
||||
find %{buildroot} -type f -name "*.la" -delete -print
|
||||
|
||||
%post -n liboslcomp%{sufx} -p /sbin/ldconfig
|
||||
%postun -n liboslcomp%{sufx} -p /sbin/ldconfig
|
||||
|
||||
%post -n liboslexec%{sufx} -p /sbin/ldconfig
|
||||
%postun -n liboslexec%{sufx} -p /sbin/ldconfig
|
||||
|
||||
%post -n liboslnoise%{sufx} -p /sbin/ldconfig
|
||||
%postun -n liboslnoise%{sufx} -p /sbin/ldconfig
|
||||
|
||||
%post -n liboslquery%{sufx} -p /sbin/ldconfig
|
||||
%postun -n liboslquery%{sufx} -p /sbin/ldconfig
|
||||
|
||||
%post -n libtestshade%{sufx} -p /sbin/ldconfig
|
||||
%postun -n libtestshade%{sufx} -p /sbin/ldconfig
|
||||
|
||||
%post -n osl.imageio%{sufx} -p /sbin/ldconfig
|
||||
%postun -n osl.imageio%{sufx} -p /sbin/ldconfig
|
||||
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%{_bindir}/*
|
||||
|
||||
%files doc
|
||||
%license LICENSE
|
||||
%doc %{_docdir}/%{name}/
|
||||
|
||||
%files shaders-devel
|
||||
%license LICENSE
|
||||
%_datadir/%{name}/
|
||||
|
||||
%files -n liboslcomp%{sufx}
|
||||
%license LICENSE
|
||||
%{_libdir}/liboslcomp.so.%{sover}*
|
||||
|
||||
%files -n liboslexec%{sufx}
|
||||
%license LICENSE
|
||||
%{_libdir}/liboslexec.so.%{sover}*
|
||||
|
||||
%files -n liboslnoise%{sufx}
|
||||
%license LICENSE
|
||||
%{_libdir}/liboslnoise.so.%{sover}*
|
||||
|
||||
%files -n liboslquery%{sufx}
|
||||
%license LICENSE
|
||||
%{_libdir}/liboslquery.so.%{sover}*
|
||||
|
||||
%files -n libtestshade%{sufx}
|
||||
%license LICENSE
|
||||
%{_libdir}/libtestshade.so.%{sover}*
|
||||
|
||||
%files -n osl.imageio%{sufx}
|
||||
%license LICENSE
|
||||
%{_libdir}/osl.imageio.so.%{sover}*
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root)
|
||||
%license LICENSE
|
||||
%{_includedir}/*
|
||||
%{_libdir}/*.so
|
||||
|
||||
%changelog
|
Loading…
Reference in New Issue
Block a user