def _enforceProvidedPath(self, path, fileType='interpreter',
                             unmanagedError=False):
        key = path, fileType
        if key in self.cachedProviders:
            return self.cachedProviders[key]
        db = self._getDb()
        troveNames = [ x.getName() for x in db.iterTrovesByPath(path) ]
        if not troveNames:
            talk = {True: self.error, False: self.warn}[bool(unmanagedError)]
            talk('%s file %s not managed by conary' %(fileType, path))
            return None
        troveName = sorted(troveNames)[0]

        # prefer corresponding :devel to :devellib if it exists
        package, component = troveName.split(':', 1)
        if component in ('devellib', 'lib'):
            for preferredComponent in ('devel', 'devellib'):
                troveSpec = (
                    ':'.join((package, preferredComponent)),
                    None, None
                )
                results = db.findTroves(None, [troveSpec],
                                             allowMissing = True)
                if troveSpec in results:
                    troveName = results[troveSpec][0][0]
                    break

        if troveName not in self.recipe._getTransitiveBuildRequiresNames():
            self.recipe.reportMissingBuildRequires(troveName)

        self.cachedProviders[key] = troveName
        return troveName