Skip to content

Commit

Permalink
CI: make cuda tests even run to begin with
Browse files Browse the repository at this point in the history
Arch profile.d scripts were converted to use an appending function that
disappears when /etc/profile exits, and overall are simply not suitable
-- any more -- for sourcing individually.

(I will freely admit I'm not really sure what the overall goal of
refraining from sourcing /etc/profile itself is. Arguably it's kind of
misuse of the profile...)

This silently broke the cuda tests, which never ran because the cuda
compiler was not detected as available.

While we are at it, I guess we can convert gentoo to use the same trick
of appending it in install.sh
  • Loading branch information
eli-schwartz committed May 30, 2024
1 parent f457791 commit d9e3a3f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
5 changes: 0 additions & 5 deletions ci/ciimage/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,6 @@ def gen_bashrc(self) -> None:
fi
'''

if self.data_dir.name == 'gentoo':
out_data += '''
source /etc/profile
'''

out_file.write_text(out_data, encoding='utf-8')

# make it executable
Expand Down
2 changes: 1 addition & 1 deletion ci/ciimage/cuda/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ install_minimal_python_packages
# Manually remove cache to avoid GitHub space restrictions
rm -rf /var/cache/pacman

echo "source /etc/profile.d/cuda.sh" >> /ci/env_vars.sh
echo "source /etc/profile" >> /ci/env_vars.sh
2 changes: 2 additions & 0 deletions ci/ciimage/gentoo/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -156,3 +156,5 @@ rm /usr/lib/python/EXTERNALLY-MANAGED
python3 -m ensurepip
install_python_packages
python3 -m pip install "${base_python_pkgs[@]}"

echo "source /etc/profile" >> /ci/env_vars.sh

0 comments on commit d9e3a3f

Please sign in to comment.