I’m trying to make module that contains a selection of Pear packages:
Here is a sample of directory structure I’m using
protected/
modules/
pear/
components/
controllers/
lib/
pear/
Genealogy/
Gedcom/
Genealogy_Gedcom.php
Genealogy_Parse.php
Inside the file Genealogy_Gedcom.php at line 34 there is this line: “require_once ‘Gedcom/Parser.php’;” This file does not exist! Take a look at the files belonging to this package, they are all prefixed “Genealogy_”, but there are many references in the beginning of the files where they skip this prefix.
I’ve made an autoloader that adds the protected/modules/lib/pear/ to include_path and will try to locate a class Genealogy_Gedcom as “Genealogy/Gedcom.php”, and that works. But when that class (Genealogy_Gedcom) again wants to require file references that are wrong, it fails.
It obviously works when Pear is properly installed on a system, but I am unable to wrap parts of Pear into a Yii module.
So what am I missing here?