d3: Enable usage as an AMD module (and fix file permissions)

This allows using D3 as an AMD module, like:

```typescript
import d3 = require('d3');
```

Due to the way the module is exported, I think you can't access D3 class names directly though, which could be a problem if one needs to do casts.