fix packaging
authorMichael Wallner <mike@php.net>
Fri, 4 Sep 2015 10:50:20 +0000 (12:50 +0200)
committerMichael Wallner <mike@php.net>
Fri, 4 Sep 2015 10:50:25 +0000 (12:50 +0200)
app/Pharext/Package.php

index 342a103aa16e1fa828ef021efed6b3a51920b517..0f2e2f4f108280308fa0dbe1ebcd7ba55918fd0d 100644 (file)
@@ -44,10 +44,12 @@ class Package
                        "name" => $this->name,
                        "release" => $this->release,
                        "license" => $this->source->getLicense(),
-                       "stub" => "pharext_installer.php",
                        "type" => $this->zend ? "zend_extension" : "extension",
                ];
-               $this->file = (new Task\PharBuild($this->source, $meta))->run();
+               /* needed for the packager, so the pharstub task can find includes */
+               set_include_path(__DIR__."/../../vendor/m6w6/pharext/src:".get_include_path());
+               $stub = __DIR__."/../../vendor/m6w6/pharext/src/pharext_installer.php";
+               $this->file = (new Task\PharBuild($this->source, $stub, $meta))->run();
                
                return sprintf("%s-%s.ext.phar", $this->name, $this->release);
        }