flynn/slugbuilder — pull request #6 by miracle2k (2014-02-24 01:45:41+00:00)
Title: Support certain (older?) buildpacks

I was trying to use https://github.com/localmed/heroku-buildpack-python-extras which is based off of an older version of the Python buildpack, and there are a couple of issues:

1. I am running into the same issue as https://github.com/progrium/buildstep/pull/4 (Heroku has separate directories for $APP_DIR and build root, and the buildpack expects that). So I've ported the buildstep patch to extract to a different directory and copy to the build dir.

2. As a related problem - slugbuilder does not set the ``$APP_DIR`` variable (not sure if it is a real thing, I didn't find any info on it), which makes the buildpack assume ``$HOME`` by default, and in the slugrunner environment, ``$HOME`` appears to be /). The patch sets both ``$APP_DIR`` and ``$HOME`` to the location the tarball is extracted to.

3. Finally, the buildpack release script doesn't generate any output (in some cases), so the ``.release`` file is empty, which the script could't handle. This is also fixed.