Using an externally-provided C compiler

Yes - you can get an older gcc version from an older nixpkgs version, but you also need a compatible version of glibc - there’s a thread on this here: Including an older glibc in stdenv - #5 by Sandro