Gentoo Archives: gentoo-osx

From: m h <sesquile@×××××.com>
To: gentoo-osx@l.g.o
Subject: [gentoo-osx] [PREFIX] Portage eating variables?
Date: Tue, 25 Jul 2006 22:49:12
Message-Id: e36b84ee0607251548r7f744c9fo3b74b8591d1b9bf8@mail.gmail.com
Has anyone else noticed that some variables disappear into the ether
under PREFIX?  One example is ebuilds that inherit webapp.eclass,
we've had to add an extra "webapp_read_config" to the
webapp_src_preinst function, otherwise the variables aren't set...
ie:

function webapp_src_preinst ()
{
        # create the directories that we need

        dodir "${MY_HTDOCSDIR}"
        dodir "${MY_HOSTROOTDIR}"
        dodir "${MY_CGIBINDIR}"
        dodir "${MY_ICONSDIR}"
        dodir "${MY_ERRORSDIR}"
        dodir "${MY_SQLSCRIPTSDIR}"
        dodir "${MY_HOOKSCRIPTSDIR}"
        dodir "${MY_SERVERCONFIGDIR}"
}

has to be changed to:
function webapp_src_preinst ()
{
    # =-=  for some reason, we need to re-source variables
        webapp_read_config

        # create the directories that we need

        dodir "${MY_HTDOCSDIR}"
        dodir "${MY_HOSTROOTDIR}"
        dodir "${MY_CGIBINDIR}"
        dodir "${MY_ICONSDIR}"
        dodir "${MY_ERRORSDIR}"
        dodir "${MY_SQLSCRIPTSDIR}"
        dodir "${MY_HOOKSCRIPTSDIR}"
        dodir "${MY_SERVERCONFIGDIR}"
}
-- 
gentoo-osx@g.o mailing list