MCPcopy Create free account
hub / github.com/Autodesk/Aurora / InstallOpenImageIO

Function InstallOpenImageIO

Scripts/installExternals.py:505–540  ·  view source on GitHub ↗
(context, force, buildArgs)

Source from the content-addressed store, hash-verified

503OIIO_PACKAGE_NAME = "OpenImageIO"
504
505def InstallOpenImageIO(context, force, buildArgs):
506 with CurrentWorkingDirectory(DownloadURL(OIIO_URL, context, force)):
507 ApplyGitPatch(context, "OpenImageIO.patch")
508
509 extraArgs = ['-DOIIO_BUILD_TOOLS=OFF',
510 '-DOIIO_BUILD_TESTS=OFF',
511 '-DBUILD_DOCS=OFF',
512 '-DUSE_PYTHON=OFF',
513 '-DSTOP_ON_WARNING=OFF',
514 '-DUSE_PTEX=OFF']
515
516 # Make sure to use boost installed by the build script and not any
517 # system installed boost
518 extraArgs.append('-DBoost_NO_BOOST_CMAKE=On')
519 extraArgs.append('-DBoost_NO_SYSTEM_PATHS=True')
520
521 # Add on any user-specified extra arguments.
522 extraArgs += buildArgs
523
524 # OIIO's FindOpenEXR module circumvents CMake's normal library
525 # search order, which causes versions of OpenEXR installed in
526 # /usr/local or other hard-coded locations in the module to
527 # take precedence over the version we've built, which would
528 # normally be picked up when we specify CMAKE_PREFIX_PATH.
529 # This may lead to undefined symbol errors at build or runtime.
530 # So, we explicitly specify the OpenEXR we want to use here.
531 extraArgs.append('-DOPENEXR_ROOT="{}"'.format(
532 os.path.join(context.externalsInstDir, OPENEXR_INSTALL_FOLDER)))
533
534 tbbConfigs = {
535 "Debug": '-DTBB_USE_DEBUG_BUILD=ON',
536 "Release": '-DTBB_USE_DEBUG_BUILD=OFF',
537 "RelWithDebInfo": '-DTBB_USE_DEBUG_BUILD=OFF',
538 }
539
540 RunCMake(context, True, OIIO_INSTALL_FOLDER, extraArgs, configExtraArgs=tbbConfigs)
541
542OPENIMAGEIO = Dependency(OIIO_INSTALL_FOLDER, OIIO_PACKAGE_NAME, InstallOpenImageIO, OIIO_URL, "include/OpenImageIO/oiioversion.h")
543

Callers

nothing calls this directly

Calls 5

CurrentWorkingDirectoryFunction · 0.85
DownloadURLFunction · 0.85
ApplyGitPatchFunction · 0.85
RunCMakeFunction · 0.85
formatMethod · 0.80

Tested by

no test coverage detected