-
Notifications
You must be signed in to change notification settings - Fork 606
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changes to SPI custom build scripts, versioning/disting policy changes
This mostly concerns builds at SPI, but a tiny bit touches the generic build scripts. Most of you will want to tune out now, unless you're especially curious. Changes for everybody: * Switching to a 4-part formal version number (e.g. 2.1.3.0), so there is an additional (rarely used) CMake variable OPENIMAGEIO_VERSION_TWEAK. This gives me a little more flexibility with certain tags and releases in the master branch but there are very few contexts in which anybody will care about or refer to the last tweak number, and in practice we may rarely or never use it. * New CMake option `OIIO_NAMESPACE_INCLUDE_PATCH`, if turned on, will make the "inner namespace" include the patch number (such as namespace OpenImageIO_v2_1_3), whereas the default is the usual major/minor (OpenImageIO_v2_1). In general, for external/supported releases, we want just major/minor, since within a major/minor family we guarantee link compatibility and specifically DON'T want to force a recompile for patch updates only. But for studios like ours who build for production directly from master, link compatibility is not guaranteed at any time, so we make sure even down to the patch level is carefully namespaced. Changes that only have an effect if you're building at SPI: * The *default* build (regular old "make") now uses the generic default namespace. If you want to make the special namespaced version we use for Arnold, build with `make OIIO_ARNOLD=1`. * Change SpComp2 versioning from consecutive low integer SpComp2 versions (like v47, v48) to canonical multidigit numbers corresponding to external releases, such as v20101 for OIIO 2.1.1. Also install the bins in the same place (even though it's nonstandard SpComp2 practice). * A new build mode enabled by `make OIIO_SPIREZ=1` does the kind of build we want for an experimental Rez packaging. Some notable details and options: - `REZ_PACKAGE_ROOT=path` overrides the usual root area where we store the packages. - `OIIO_REZ_NAME=name` overrides the default package name for the Rez distribution (default is "OpenImageIO"). - An appropriate package.py is automatically generated. - The Rez variants fold in the SPI compiler compatibility platform, Python major/minor version, and Boost version. - The build automatically sets the Rpath for the Rez install area so that nobody needs to mess with their LD_LIBRARY_PATH to get the libraries to be found (especially if you're just importing the Python module). * Make the appcfg xml for releasing the binaries to the facility. * Instructions for building for the facility are now in site/spi/README-SPI.md
- Loading branch information
Showing
9 changed files
with
310 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
Build a variant for Rez/general use | ||
----------------------------------- | ||
|
||
Skip this section if you are instead building for SpComp2. | ||
|
||
Note: For testing or to make your own local rez package, you can customize | ||
either the rez package name, or the rez install location name, with make | ||
flags `OIIO_REZ_NAME=blah REZ_PACKAGE_ROOT=/path/to/my/rez/pkgs` appended | ||
to the `make` commands of any of the variants listed below. For example, | ||
|
||
make OIIO_SPIREZ=1 OIIO_REZ_NAME=oiio_test REZ_PACKAGE_ROOT=/path/to/my/rez/pkgs | ||
|
||
|
||
Variants: | ||
|
||
# Python 2.7, Boost 1.55, C++11/gcc4.8 compat | ||
make nuke | ||
make OIIO_SPIREZ=1 | ||
|
||
# Python 2.7, Boost 1.55 sp namespaced, C++11/gcc4.8 compat | ||
make nuke | ||
make OIIO_SPIREZ=1 BOOSTVERS=1.55sp | ||
|
||
# Python 3.7, Boost 1.66, C++11/gcc4.8 compat | ||
make nuke | ||
make OIIO_SPIREZ=1 BOOSTVERS=1.66 PYTHON_VERSION=3.7 | ||
|
||
# Python 3.6, Boost 1.55, C++11/gcc4.8 compat (for Jon Ware) | ||
make nuke | ||
make OIIO_SPIREZ=1 PYTHON_VERSION=3.6 | ||
|
||
You can do any of these on your local machine. | ||
|
||
|
||
Rez/general release (do for each variant) | ||
----------------------------------------- | ||
|
||
This must be done from compile40 (for correct write permissions on certain | ||
shared directories), even if you did the build itself locally. | ||
|
||
First: | ||
|
||
ss spi/home | ||
cd /the/oiio/src/area | ||
cd dist/rhel7 | ||
|
||
For any of the variants that you built above: | ||
|
||
rez release --skip-repo-errors | ||
|
||
That command will release the dist to the studio. | ||
|
||
|
||
Appwrapper binary releases | ||
-------------------------- | ||
|
||
This step is for the ONE general/rez variant that we believe is the | ||
canonical source of command line oiiotool and maketx. After building and | ||
releasing as above, | ||
|
||
cp OpenImageIO_*.xml /shots/spi/home/lib/app_cfg/OpenImageIO | ||
|
||
That will make appcfg aware of the release. | ||
|
||
To also make this release the new facility default: | ||
|
||
db-any spi/home/OpenImageIO.bin highest /shots/spi/home/lib/app_cfg/OpenImageIO_A.B.C.D.xml | ||
|
||
where A.B.C.D is the version. | ||
|
||
|
||
SpComp2 build and release | ||
------------------------- | ||
|
||
If you are trying to do an SpComp2 release, forget all the steps above, you | ||
will need some different flags. | ||
|
||
First, to make a TEST build and release to your local spcomp2 mock-up: | ||
|
||
make OIIO_SPCOMP2=1 SPCOMP2_LOCAL_PATH=/test/path spcomp2_install_local | ||
|
||
When you are ready for the real thing, you will want to build each of the | ||
following variants: | ||
|
||
# Python 2.7, Boost 1.55, C++11/gcc4.8 compat | ||
make nuke | ||
make OIIO_SPCOMP2=1 spcomp2_install | ||
|
||
# Python 2.7, Boost 1.55 sp namespaced, C++11/gcc4.8 compat | ||
make nuke | ||
make OIIO_SPCOMP2=1 BOOSTVERS=1.55sp spcomp2_install | ||
|
||
# Python 3.7, Boost 1.66, C++11/gcc4.8 compat | ||
make nuke | ||
make OIIO_SPCOMP2=1 BOOSTVERS=1.66 PYTHON_VERSION=3.7 spcomp2_install | ||
|
||
# Python 3.6, Boost 1.55, C++11/gcc4.8 compat (for Jon Ware) | ||
make nuke | ||
make OIIO_SPCOMP2=1 PYTHON_VERSION=3.6 spcomp2_install | ||
|
||
Nobody should do this but lg, except in extraordinary circumstances. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<cfg> | ||
<version>@OIIO_VERSION_MAJOR@.@OIIO_VERSION_MINOR@.@OIIO_VERSION_PATCH@.@OIIO_VERSION_TWEAK@</version> | ||
<appdir architecture="@SP_OS@">@OIIO_REZ_INSTALL_PATH@</appdir> | ||
<launchprogram></launchprogram> | ||
<setup></setup> | ||
</cfg> |
Oops, something went wrong.