summary refs log tree commit diff
path: root/pkgs/build-support/gcc-wrapper/utils.sh
blob: 5163c239527c4b87955634b4ccd499175c26ea71 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
skip () {
    if test "$NIX_DEBUG" = "1"; then
        echo "skipping impure path $1" >&2
    fi
}

badPath() {
    local p=$1
    test \
        "${p:0:${#NIX_STORE}}" != "$NIX_STORE" -a \
        "${p:0:4}" != "/tmp" -a \
        "${p:0:${#NIX_BUILD_TOP}}" != "$NIX_BUILD_TOP"
}