Skip to content

Commit 161bab8

Browse files
committed
Update OpenCL activation instructions. [ci skip]
1 parent 77c54e3 commit 161bab8

2 files changed

Lines changed: 8 additions & 10 deletions

File tree

README.rst

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -145,14 +145,13 @@ you haven't created this file.)
145145

146146
If you need OpenCL support (e.g. for OpenMM), note that pixi does not run
147147
conda post-link scripts, so the ``ocl-icd-system`` symlink won't be created
148-
automatically. Add the following to your ``pixi.sh`` to fix this:
148+
automatically. After creating the environment, run the following once to fix
149+
this:
149150

150151
.. code-block:: bash
151152
152-
# Create OpenCL ICD symlink (pixi doesn't run post-link scripts)
153-
if [ -d /etc/OpenCL/vendors ] && [ ! -e "${CONDA_PREFIX}/etc/OpenCL/vendors/ocl-icd-system" ]; then
154-
ln -s /etc/OpenCL/vendors "${CONDA_PREFIX}/etc/OpenCL/vendors/ocl-icd-system" 2>/dev/null || true
155-
fi
153+
pixi shell -e dev
154+
ln -s /etc/OpenCL/vendors "${CONDA_PREFIX}/etc/OpenCL/vendors/ocl-icd-system"
156155
157156
Support and Development
158157
=======================

doc/source/install.rst

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -335,14 +335,13 @@ you haven't created this file.)
335335

336336
If you need OpenCL support (e.g. for OpenMM), note that pixi does not run
337337
conda post-link scripts, so the ``ocl-icd-system`` symlink won't be created
338-
automatically. Add the following to your ``pixi.sh`` to fix this:
338+
automatically. After creating the environment, run the following once to fix
339+
this:
339340

340341
.. code-block:: bash
341342
342-
# Create OpenCL ICD symlink (pixi doesn't run post-link scripts)
343-
if [ -d /etc/OpenCL/vendors ] && [ ! -e "${CONDA_PREFIX}/etc/OpenCL/vendors/ocl-icd-system" ]; then
344-
ln -s /etc/OpenCL/vendors "${CONDA_PREFIX}/etc/OpenCL/vendors/ocl-icd-system" 2>/dev/null || true
345-
fi
343+
pixi shell -e dev
344+
ln -s /etc/OpenCL/vendors "${CONDA_PREFIX}/etc/OpenCL/vendors/ocl-icd-system"
346345
347346
Compile and install
348347
-------------------

0 commit comments

Comments
 (0)