build-support: Added makeSymlinks function

I have refractored things a little bit. We need a function that would symlink
a bunch of files (ex. created with writeText) to a folder. What `environemnt.etc`
uses looks like a fit, because it has really nice syntax where you can specify
`source`, `target` and `mode` so i generalize its functionality. I also added
support for providing only derivation in a list of files to symlink
where name is used as a `target` (usefull in a case if you use `writeText`).

Just as an example, this allows me to do something like:

```
  configDir = pkgs.makeSymlinks {
    name = "elasticsearch-config";
    files = [
      (pkgs.writeText "elasticsearch.yml" esConfig)
      (pkgs.writeText "logging.yml" cfg.logging)
    ];
  };
```

I don't know what is the best way to generalize this please advise or
propose a better soution. I need this to make a bunch of nixos modules
more pure. I will add documentation if you consider this as correct solution