in reply to Dynamic Packages in Perl

I'd also recommend Class::MOP for this kind of thing, but basically, the only thing you need to do to create a package (and all its parent packages) is to put some entry in its symbol table.
my $package_name = "Bla::Dee::Bla"; no strict 'refs'; ${"$package_name::PARENT"} = "Bla::Dee"; # create $Bla::Dee::Bla::PARE +NT;

Replies are listed 'Best First'.
Re^2: Dynamic Packages in Perl
by Narveson (Chaplain) on Nov 14, 2008 at 23:38 UTC

    Whoops!

    This assigns the string 'Bla::Dee' to the scalar ${""} in package main.

    To do what you intend, say

    ${$package_name.'::PARENT'} = "Bla::Dee";