finally got mozilla.cfg working firefox nix, broke webgl

This commit is contained in:
Freya Murphy 2024-11-15 16:23:04 -05:00
parent e3fc26134e
commit f473641826
Signed by: freya
GPG key ID: 9FBC6FFD6D2DBF17
2 changed files with 1 additions and 31 deletions

View file

@ -1,4 +1,4 @@
{ pkgs, nixgl, ... }:
{ pkgs ... }:
let
lock-false = {
Value = false;

View file

@ -1,30 +0,0 @@
{ pkgs, nixgl, ... }:
let
nixGL = "${nixgl.packages.${pkgs.system}.nixGLIntel}/bin/nixGLIntel";
in
pkg:
(pkg.overrideAttrs (old: {
buildCommand = ''
set -eo pipefail
${
# Heavily inspired by https://stackoverflow.com/a/68523368/6259505
pkgs.lib.concatStringsSep "\n" (map (outputName: ''
echo "Copying output ${outputName}"
set -x
cp -rs --no-preserve=mode "${pkg.${outputName}}" "''$${outputName}"
set +x
'') (old.outputs or [ "out" ]))}
rm -rf $out/bin/*
shopt -s nullglob # Prevent loop from running if no files
for file in ${pkg.out}/bin/*; do
echo "#!${pkgs.bash}/bin/bash" > "$out/bin/$(basename $file)"
echo "exec -a \"\$0\" ${nixGL} $file \"\$@\"" >> "$out/bin/$(basename $file)"
chmod +x "$out/bin/$(basename $file)"
done
shopt -u nullglob # Revert nullglob back to its normal default state
'';
}))