summaryrefslogtreecommitdiffstats
path: root/php-kdyby-events-autoload.php
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2015-11-01 08:54:46 +0100
committerRemi Collet <fedora@famillecollet.com>2015-11-01 08:54:46 +0100
commit151fb3f9a88c0ec538374483744b02eb81f45328 (patch)
treeebe3c01081e5b4736ab40e0e460c62411bab4a21 /php-kdyby-events-autoload.php
php-kdyby-events: 2.4.0, new package
Diffstat (limited to 'php-kdyby-events-autoload.php')
-rw-r--r--php-kdyby-events-autoload.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/php-kdyby-events-autoload.php b/php-kdyby-events-autoload.php
new file mode 100644
index 0000000..7f9fc3a
--- /dev/null
+++ b/php-kdyby-events-autoload.php
@@ -0,0 +1,18 @@
+<?php
+$vendor = '/usr/share/php';
+
+if (!isset($fedoraClassLoader) || !($fedoraClassLoader instanceof \Symfony\Component\ClassLoader\ClassLoader)) {
+ if (!class_exists('Symfony\\Component\\ClassLoader\\ClassLoader', false)) {
+ require_once $vendor . '/Symfony/Component/ClassLoader/ClassLoader.php';
+ }
+
+ $fedoraClassLoader = new \Symfony\Component\ClassLoader\ClassLoader();
+ $fedoraClassLoader->register();
+}
+$fedoraClassLoader->addPrefix('Kdyby\\Events\\', dirname(dirname(__DIR__)));
+require_once __DIR__ . '/exceptions.php';
+
+// Dependencies
+require_once $vendor . '/Doctrine/Common/autoload.php';
+require_once $vendor . '/Nette/DI/autoload.php';
+require_once $vendor . '/Nette/Utils/autoload.php';