44# SPDX-License-Identifier: Apache-2.0
55# https://github.com/AcademySoftwareFoundation/OpenImageIO
66
7- # DEP_DIR="$PWD/ext/dist"
87DEP_DIR=" $PWD /dist/$PLATFORM "
98mkdir -p " $DEP_DIR "
10- mkdir -p ext && true
9+ mkdir -p ext
1110INT_DIR=" build/$PLATFORM "
1211VCPKG_INSTALLATION_ROOT=/c/vcpkg
1312
3736pip install numpy
3837
3938
40- # #######################################################################
41- # Dependency method #1: Use vcpkg (disabled)
42- #
43- # Currently we are not using this, but here it is for reference:
44- #
45- echo " All pre-installed VCPkg installs:"
46- vcpkg list
47- echo " ---------------"
39+ # In case we need vcpkg, example:
40+ # echo "All pre-installed VCPkg installs:"
41+ # vcpkg list
42+ # echo "---------------"
4843# vcpkg update
49- #
50-
51- # vcpkg install libdeflate:x64-windows-release
52- # vcpkg install zlib:x64-windows-release
53- vcpkg install tiff:x64-windows-release
54- # vcpkg install libpng:x64-windows-release
55- # vcpkg install giflib:x64-windows-release
56- vcpkg install freetype:x64-windows-release
57- # # vcpkg install openexr:x64-windows-release
58- vcpkg install libjpeg-turbo:x64-windows-release
59- #
60- # vcpkg install libraw:x64-windows-release
61- # vcpkg install openjpeg:x64-windows-release
62- # # vcpkg install ffmpeg:x64-windows-release # takes FOREVER!
63- # # vcpkg install webp:x64-windows-release # No such vcpkg package?a
64- #
65- # #echo "$VCPKG_INSTALLATION_ROOT"
66- # #ls "$VCPKG_INSTALLATION_ROOT"
67- # #echo "$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release"
68- # #ls "$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release"
69- # #echo "$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release/lib"
70- # #ls "$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release/lib"
71- # #echo "$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release/bin"
72- # #ls "$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release/bin"
73- #
74- # # export PATH="$PATH:$DEP_DIR/bin:$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release/bin"
75- # export PATH="$DEP_DIR/lib:$DEP_DIR/bin:$PATH:$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release/lib"
76- export CMAKE_PREFIX_PATH=" $CMAKE_PREFIX_PATH :$VCPKG_INSTALLATION_ROOT /installed/x64-windows-release"
77- # export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release/lib:$DEP_DIR/lib:$DEP_DIR/bin"
78- #
79- echo " All VCPkg installs:"
80- vcpkg list
81- #
82- # #######################################################################
83-
84-
85- # #######################################################################
86- # Dependency method #2: Build from source ourselves
87- #
88- #
89-
90- # src/build-scripts/build_zlib.bash
91- # export ZLIB_ROOT=$PWD/ext/dist
92-
93- # src/build-scripts/build_libpng.bash
94- # export PNG_ROOT=$PWD/ext/dist
95-
96- # We're currently getting libtiff from vcpkg
97- src/build-scripts/build_libtiff.bash
98- export TIFF_ROOT=$PWD /ext/dist
99-
100- # We're currently getting jpeg from vcpkg
101- # LIBJPEGTURBO_CONFIG_OPTS=-DWITH_SIMD=OFF
102- # # ^^ because we're too lazy to build nasm
103- # src/build-scripts/build_libjpeg-turbo.bash
104- # export JPEGTurbo_ROOT=$PWD/ext/dist
105-
106- source src/build-scripts/build_pybind11.bash
107- # export pybind11_ROOT=$PWD/ext/dist
44+ # vcpkg install libdeflate:x64-windows-release
45+ # export CMAKE_PREFIX_PATH="$CMAKE_PREFIX_PATH:$VCPKG_INSTALLATION_ROOT/installed/x64-windows-release"
46+ # echo "All VCPkg installs:"
47+ # vcpkg list
48+
49+
50+
51+ if [[ " $LIBTIFF_VERSION " != " " ]] ; then
52+ source src/build-scripts/build_libtiff.bash
53+ fi
54+
55+ if [[ " $PYBIND11_VERSION " != " 0" ]] ; then
56+ source src/build-scripts/build_pybind11.bash
57+ fi
10858
10959
11060# curl --location https://ffmpeg.zeranoe.com/builds/win64/dev/ffmpeg-4.2.1-win64-dev.zip -o ffmpeg-dev.zip
@@ -116,7 +66,6 @@ echo "CMAKE_PREFIX_PATH = $CMAKE_PREFIX_PATH"
11666
11767if [[ " $OPENEXR_VERSION " != " " ]] ; then
11868 OPENEXR_CXX_FLAGS=" /W1 /EHsc /DWIN32=1 "
119- # OPENEXR_BUILD_TYPE=$CMAKE_BUILD_TYPE
12069 OPENEXR_INSTALL_DIR=$DEP_DIR
12170 source src/build-scripts/build_openexr.bash
12271 export PATH=" $OPENEXR_INSTALL_DIR /bin:$OPENEXR_INSTALL_DIR /lib:$PATH "
@@ -130,10 +79,5 @@ echo "DEP_DIR $DEP_DIR :"
13079ls -R -l " $DEP_DIR "
13180
13281
133- # source src/build-scripts/build_openexr.bash
134- # export CMAKE_PREFIX_PATH="$CMAKE_PREFIX_PATH;$OPENEXR_ROOT"
135- # source src/build-scripts/build_opencolorio.bash
136-
137-
13882# Save the env for use by other stages
13983src/build-scripts/save-env.bash
0 commit comments