mirror of
https://github.com/yann64/haikuports.git
synced 2026-05-05 22:48:55 +02:00
The quotes around $binDir and $prefix are not needed in the definitions of commandBinDir. There are over 120 recipes which define commandBinDir, and *most* of them don't have quotes in the lines defining commandBinDir and commandSuffix. 15 recipes were not consistent with the wiki. Now they are.
158 lines
4.3 KiB
Bash
158 lines
4.3 KiB
Bash
SUMMARY="Advanced shading language for production GI renderers"
|
|
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."
|
|
HOMEPAGE="https://github.com/imageworks/OpenShadingLanguage"
|
|
COPYRIGHT="2009-2017 Sony Pictures Imageworks Inc."
|
|
LICENSE="BSD (3-clause)"
|
|
REVISION="1"
|
|
SOURCE_URI="$HOMEPAGE/archive/Release-$portVersion.tar.gz"
|
|
CHECKSUM_SHA256="5d9dc71f3b79714350ae94e4ad5929a7aabae40f292e7837d1749fca180eae96"
|
|
SOURCE_DIR="OpenShadingLanguage-Release-$portVersion"
|
|
PATCHES="osl-$portVersion.patchset"
|
|
|
|
ARCHITECTURES="!x86_gcc2 ?x86 x86_64"
|
|
SECONDARY_ARCHITECTURES="?x86"
|
|
|
|
# On x86_gcc2 we don't want to install the commands in bin/<arch>/, but in bin/.
|
|
commandSuffix=$secondaryArchSuffix
|
|
commandBinDir=$binDir
|
|
if [ "$targetArchitecture" = x86_gcc2 ]; then
|
|
commandSuffix=
|
|
commandBinDir=$prefix/bin
|
|
fi
|
|
|
|
libVersion="$portVersion"
|
|
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
|
|
|
PROVIDES="
|
|
osl$secondaryArchSuffix = $libVersionCompat
|
|
cmd:oslc$commandSuffix
|
|
cmd:oslinfo$commandSuffix
|
|
cmd:testrender$commandSuffix
|
|
cmd:testshade$commandSuffix
|
|
cmd:testshade_dso$commandSuffix
|
|
lib:liboslcomp$secondaryArchSuffix
|
|
lib:liboslexec$secondaryArchSuffix
|
|
lib:liboslnoise$secondaryArchSuffix
|
|
lib:liboslquery$secondaryArchSuffix
|
|
lib:libtestshade$secondaryArchSuffix
|
|
lib:osl.imageio$secondaryArchSuffix
|
|
"
|
|
REQUIRES="
|
|
haiku$secondaryArchSuffix
|
|
lib:libboost_atomic$secondaryArchSuffix
|
|
lib:libboost_chrono$secondaryArchSuffix
|
|
lib:libboost_date_time$secondaryArchSuffix
|
|
lib:libboost_filesystem$secondaryArchSuffix
|
|
lib:libboost_serialization$secondaryArchSuffix
|
|
lib:libboost_system$secondaryArchSuffix
|
|
lib:libboost_thread$secondaryArchSuffix
|
|
lib:libboost_wave$secondaryArchSuffix
|
|
lib:libHalf$secondaryArchSuffix
|
|
lib:libIex_2_2$secondaryArchSuffix
|
|
lib:libilmimf$secondaryArchSuffix
|
|
lib:libIlmThread_2_2$secondaryArchSuffix
|
|
lib:libImath_2_2$secondaryArchSuffix
|
|
lib:libLLVM_5.0$secondaryArchSuffix
|
|
lib:libopenimageio$secondaryArchSuffix
|
|
lib:libpugixml$secondaryArchSuffix
|
|
lib:libz$secondaryArchSuffix
|
|
"
|
|
|
|
PROVIDES_devel="
|
|
osl${secondaryArchSuffix}_devel = $libVersionCompat
|
|
devel:liboslcomp$secondaryArchSuffix
|
|
devel:liboslexec$secondaryArchSuffix
|
|
devel:liboslnoise$secondaryArchSuffix
|
|
devel:liboslquery$secondaryArchSuffix
|
|
devel:libtestshade$secondaryArchSuffix
|
|
devel:osl.imageio$secondaryArchSuffix
|
|
"
|
|
REQUIRES_devel="
|
|
osl$secondaryArchSuffix == $portVersion base
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku${secondaryArchSuffix}_devel
|
|
gcc_syslibs_devel$secondaryArchSuffix
|
|
devel:libboost_atomic$secondaryArchSuffix
|
|
devel:libboost_chrono$secondaryArchSuffix
|
|
devel:libboost_date_time$secondaryArchSuffix
|
|
devel:libboost_filesystem$secondaryArchSuffix
|
|
devel:libboost_serialization$secondaryArchSuffix
|
|
devel:libboost_system$secondaryArchSuffix
|
|
devel:libboost_thread$secondaryArchSuffix
|
|
devel:libboost_wave$secondaryArchSuffix
|
|
devel:libHalf$secondaryArchSuffix
|
|
devel:libIex_2_2$secondaryArchSuffix
|
|
devel:libilmimf$secondaryArchSuffix
|
|
devel:libIlmThread_2_2$secondaryArchSuffix
|
|
devel:libImath_2_2$secondaryArchSuffix
|
|
devel:libLLVM_5.0$secondaryArchSuffix
|
|
devel:libopenimageio$secondaryArchSuffix
|
|
devel:libpartio$secondaryArchSuffix
|
|
devel:libpugixml$secondaryArchSuffix
|
|
devel:libz$secondaryArchSuffix
|
|
"
|
|
BUILD_PREREQUIRES="
|
|
cmd:bison
|
|
cmd:clang
|
|
cmd:cmake
|
|
cmd:flex
|
|
cmd:gcc$secondaryArchSuffix
|
|
cmd:make
|
|
cmd:pkg_config$secondaryArchSuffix
|
|
cmd:python2
|
|
"
|
|
|
|
defineDebugInfoPackage osl$secondaryArchSuffix \
|
|
$libDir/liboslcomp.so \
|
|
$libDir/liboslexec.so \
|
|
$libDir/liboslnoise.so \
|
|
$libDir/liboslquery.so \
|
|
$libDir/libtestshade.so \
|
|
$libDir/osl.imageio.so \
|
|
$commandBinDir/oslc$commandSuffix \
|
|
$commandBinDir/oslinfo$commandSuffix \
|
|
$commandBinDir/testrender$commandSuffix \
|
|
$commandBinDir/testshade$commandSuffix \
|
|
$commandBinDir/testshade_dso$commandSuffix
|
|
|
|
BUILD()
|
|
{
|
|
mkdir -p build
|
|
cd build
|
|
cmake .. \
|
|
$cmakeDirArgs \
|
|
-DCMAKE_CXX_FLAGS="-DBOOST_NO_CXX11_CONSTEXPR" \
|
|
-DCMAKE_INSTALL_BINDIR=$commandBinDir
|
|
|
|
make $jobArgs
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
cd build
|
|
make install
|
|
|
|
prepareInstalledDevelLibs \
|
|
liboslcomp \
|
|
liboslexec \
|
|
liboslnoise \
|
|
liboslquery \
|
|
libtestshade \
|
|
osl.imageio
|
|
|
|
fixPkgconfig
|
|
|
|
packageEntries devel \
|
|
$developDir
|
|
}
|
|
|
|
TEST()
|
|
{
|
|
cd build
|
|
make test
|
|
}
|