composer/composer — pull request #1310 by simensen (2012-11-09 18:15:53+00:00)
Title: [WIP] Incorporate md5 of package name into an additional ComposerAutoloaderInit

Updated version of #1297 that handles the same problem by generating an additional autoload_real looking file that has an additional name suffix thing based on the md5sum of the package name.

End result should be that we can always expect that there will be exactly one `ComposerAutoloaderInit` class in existence and it will always have that name. If it already exists for some reason (like in the case of phpunit) then a package-specific class is used to init the existing autoloader.

No end-user intervention required.

Live example:

**vendor/autoload.php**

```php
$path) {
$loader->add($namespace, $path);
}

$classMap = require __DIR__ . '/autoload_classmap.php';
if ($classMap) {
$loader->addClassMap($classMap);
}

$loader->register();

return $loader;
}
}
```

**vendor/composer/autoload_real_0f998949c16cd60fb01c4cab3c9537b3.php**
```php
$path) {
$loader->add($namespace, $path);
}

$classMap = require __DIR__ . '/autoload_classmap.php';
if ($classMap) {
$loader->addClassMap($classMap);
}

$loader->register();

return $loader;
}
}
ComposerAutoloaderInit0f998949c16cd60fb01c4cab3c9537b3::initLoader(ComposerAutoLoaderInit::getLoader());
```