]> git.ipfire.org Git - ipfire-2.x.git/blobdiff - lfs/cleanup-toolchain
toolchain: Remove the cross compiler, when we don't need it anymore.
[ipfire-2.x.git] / lfs / cleanup-toolchain
index ed1a97ef5d003a3a52ffe7557c8191d1578f4cdb..1be39fef6ca6580c614957aa31aa468a24752fa9 100644 (file)
@@ -57,7 +57,11 @@ ifeq "$(PASS)" "1"
                -e 's@/lib\(64\)\?/ld@/tools&@g' \
                -e "/^\*cpp:$$/{n;s,$$, -isystem /tools/include,}" > $$SPECS
 endif
+
 ifeq "$(PASS)" "2"
+       # Remove the first cross compiler which is not needed anymore.
+       find /tools/ -name "$(CROSSTARGET)*" | xargs rm -rfv
+
        -strip --strip-debug /tools/lib/*
        -strip --strip-unneeded /tools/{,s}bin/*
        rm -rfv /tools/{,share}/{info,man} /usr/local/man