Skip to content

Commit a6e507c

Browse files
committed
build: Get OptiX headers from new improved location
NVIDIA recently set up a GitHub repo with the OptiX headers (with version tags!), which is much better than the unreliable semi-secret location we used to use. Signed-off-by: Larry Gritz <[email protected]>
1 parent 05deead commit a6e507c

File tree

2 files changed

+6
-16
lines changed

2 files changed

+6
-16
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,8 @@ jobs:
260260
pybind11_ver: v2.10.0
261261
simd: avx2,f16c
262262
skip_tests: 1
263-
setenvs: export OSL_CMAKE_FLAGS="-DOSL_USE_OPTIX=1" OPTIX_VERSION=7.0
263+
setenvs: export OSL_CMAKE_FLAGS="-DOSL_USE_OPTIX=1"
264+
OPTIX_VERSION=7.0.0
264265
OPENIMAGEIO_CMAKE_FLAGS=-DBUILD_FMT_VERSION=9.1.0
265266
- desc: VP2024 gcc11/C++17 llvm17 py3.11 boost1.82 oiio-rel avx2
266267
nametag: linux-vfx2024

src/build-scripts/gh-installdeps.bash

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -148,21 +148,10 @@ cmake --version
148148

149149

150150
if [[ "$OPTIX_VERSION" != "" ]] ; then
151-
echo "Requested OPTIX_VERSION = '${OPTIX_VERSION}'"
152-
mkdir -p $LOCAL_DEPS_DIR/dist/include/internal
153-
OPTIXLOC=https://developer.download.nvidia.com/redist/optix/v${OPTIX_VERSION}
154-
for f in optix.h optix_device.h optix_function_table.h \
155-
optix_function_table_definition.h optix_host.h \
156-
optix_stack_size.h optix_stubs.h optix_types.h optix_7_device.h \
157-
optix_7_host.h optix_7_types.h \
158-
internal/optix_7_device_impl.h \
159-
internal/optix_7_device_impl_exception.h \
160-
internal/optix_7_device_impl_transformations.h
161-
do
162-
curl --retry 100 -m 120 --connect-timeout 30 \
163-
$OPTIXLOC/include/$f > $LOCAL_DEPS_DIR/dist/include/$f
164-
done
165-
export OptiX_ROOT=$LOCAL_DEPS_DIR/dist
151+
OPTIXREPO=${OPTIXREPO:=https://github.com/NVIDIA/optix-dev}
152+
echo "Requested OPTIX_VERSION = '${OPTIX_VERSION}' from ${OPTIXREPO}"
153+
export OptiX_ROOT=$LOCAL_DEPS_DIR/dist/optix-dev
154+
git clone -b v${OPTIX_VERSION} ${OPTIXREPO} ${OptiX_ROOT}
166155
fi
167156

168157

0 commit comments

Comments
 (0)