Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- pkgs ? import <nixpkgs> { },
- ...
- }:
- with pkgs;
- mkShell {
- buildInputs = [
- gcc15
- coreutils
- gawk
- gnumake
- binutils
- ];
- shellHook = ''
- # TODO: This could be done with an overlay
- # filesystem and so not disrupt a thing.
- w='-' # '+' for noisy, '-' for quiet.
- syms=symlinks$w
- libs=libraries$w
- pkgs="${glibc} ${glibc.dev}"
- rm -R -f POSIX
- mkdir -p POSIX/include
- for p in $pkgs; do
- for dir in include; do
- $HOME/.local/bin/mte $syms $p/$dir POSIX/$dir
- done
- done
- mkdir -p POSIX/lib
- for p in $pkgs; do
- for dir in lib; do
- $HOME/.local/bin/mte $libs $p/$dir POSIX/$dir
- done
- done
- export PATH="${gcc15}/bin:$PATH"
- export CC=${gcc15}/bin/gcc
- export CPPFLAGS=-idirafter`pwd`/POSIX/include
- export LDFLAGS=-L`pwd`/POSIX/lib
- '';
- }
Advertisement
Add Comment
Please, Sign In to add comment