[OPEN-ILS-DEV] Evergreen Perl module package declarations

Mike Rylander mrylander at gmail.com
Thu Jul 5 00:36:46 EDT 2007


On 7/4/07, Peter Newman <Peter.Newman at cdu.edu.au> wrote:
> > Very cool.  We'd love to be involved, of course, to help sort out any
> issues (there seem to be at least a couple).
>
> Well I have an installable rpm - I have some friends keen to help out and
> test them from scratch...
>
> I can guarantee that they will be broken :-) with probably some missing
> dependencies, broken perl due to these changes, an no real ILS system
> configuration but it's a starting point nevertheless

Indeed.  We're deploying on Debian in production right now, so if any
of those friends know deb packaging... ;)

>
> > The files reported missing aren't missing, but instead dead code.  The
> modules that reference them should go away; they will not be coming back.
> >
> > As for the modules reported to have an incorrect name, changing the module
> name declared in the package statement will absolutely and completely break
> and change how the modules work, and it will do > so under /all/
> distributions, certainly not just Ubuntu.
> >
> > Are you sure you understand what is going on in those files?  Thank you,
> though, for your interest.
>
> Actually no I don't understand - but I don't need to yet.  I'm just
> packaging everything up and resolving dependencies - the next step when
> testing is started then yes I'll need to know a little more.
>

The short version is that in some cases(1) they provide mixin (to use
new-fangled "pattern" terminology) methods to other packages, and in
others(2) they act to flesh out stub classes by providing real
implementations.  And sometimes(3) both.

1) OpenILS::Application::Storage::Driver::Pg::dbi
2) OpenILS::Application::Storage::Driver::Pg::fts
3) OpenILS::Application::Storage::Driver::Pg::storage

[snip description of breakage]

>
> However by having both lines together in the Fieldmapper.pm:
>
>   package Fieldmapper;
>   package OpenILS::Utils::Fieldmapper;
>
> Seems to be okay but can you have muItiple decls like this? Anyway now the
> fieldmapper_lookup-gen.pl works again and the dependency is resolved.

Hmmm... well, you can't do precisely what you've done there, but by
swapping the order of the package lines it seems you can accomplish
both goals.  I'll do some testing on that front.

>
> If these are due to dead code - I'm interested in knowing if you fix them?
>

Well, some of that is dead code.  Fieldmapper.pm isn't (it's probably
the most heavily used perl code, other than the OpenSRF stack), but
fieldmapper_lookup-gen.pl (superseded by liboils_idl), the entire
OpenSRF::DOM tree, and most of OpenSRF::DomainObject are.  Most of
that has been removed from trunk (as mentioned).

Thanks again, Pete.

--miker


More information about the Open-ils-dev mailing list