def doFile(self, path):
        pkgs = self.recipe.autopkg.findComponents(path)
        if not pkgs:
            return
        pkgFiles = [(x, x.getFile(path)) for x in pkgs]
        # this file object used only for tests, not for doing packaging
        f = pkgFiles[0][1]
        macros = self.recipe.macros
        fullpath = macros.destdir + path
        m = self.recipe.magic[path]

        if self._isELF(m, 'requires'):
            isnset = m.contents['isnset']
            if isnset in self.allowableIsnSets:
                # only add requirements for architectures
                # that we are actually building for (this may include
                # major and minor architectures)
                self._addELFRequirements(path, m, pkgFiles)

        # now go through explicit requirements
        for info in self.included:
            for filt in self.included[info]:
                if filt.match(path):
                    self._markManualRequirement(info, path, pkgFiles, m)

        # now check for automatic dependencies besides ELF
        if f.inode.perms() & 0111 and m and m.name == 'script':
            interp = m.contents['interpreter']
            if interp.strip().startswith('/') and self._checkInclusion(interp,
                                                                       path):
                # no interpreter string warning is in BadInterpreterPaths
                if not (os.path.exists(interp) or
                        os.path.exists(macros.destdir+interp)):
                    # this interpreter not on system, warn
                    # cannot be an error to prevent buildReq loops
                    self.warn('interpreter "%s" (referenced in %s) missing',
                        interp, path)
                    # N.B. no special handling for /{,usr/}bin/env here;
                    # if there has been an exception to
                    # NormalizeInterpreterPaths, then it is a
                    # real dependency on the env binary
                self._addRequirement(path, interp, [], pkgFiles,
                                     deps.FileDependencies)

        if (f.inode.perms() & 0111 and m and m.name == 'script' and
            os.path.basename(m.contents['interpreter']).startswith('python')):
            self._addPythonRequirements(path, fullpath, pkgFiles)
        elif self._isPython(path):
            self._addPythonRequirements(path, fullpath, pkgFiles)

        if (f.inode.perms() & 0111 and m and m.name == 'script' and
            os.path.basename(m.contents['interpreter']).startswith('ruby')):
            self._addRubyRequirements(path, fullpath, pkgFiles, script=True)
        elif '/ruby/' in path and path.endswith('.rb'):
            self._addRubyRequirements(path, fullpath, pkgFiles, script=False)

        if self._isCIL(m):
            if not self.monodisPath:
                self.monodisPath = self._getmonodis(macros, path)
                if not self.monodisPath:
                    return
            p = util.popen('%s --assemblyref %s' %(
                           self.monodisPath, fullpath))
            for line in [ x.strip() for x in p.readlines() ]:
                if ': Version=' in line:
                    ver = line.split('=')[1]
                elif 'Name=' in line:
                    name = line.split('=')[1]
                    self._addRequirement(path, name, [ver], pkgFiles,
                                         deps.CILDependencies)
            p.close()

        elif self.CILPolicyRE.match(path):
            name, ver = self._CILPolicyProvides[path]
            self._addRequirement(path, name, [ver], pkgFiles, deps.CILDependencies)

        if self._isJava(m, 'requires'):
            self._addJavaRequirements(path, m, pkgFiles)

        db = self._getDb()
        if self._isPerl(path, m, f):
            perlReqs = self._getPerlReqs(path, fullpath)
            for req in perlReqs:
                thisReq = deps.parseDep('perl: ' + req)
                if db.getTrovesWithProvides([thisReq]) or [
                        x for x in self.recipe.autopkg.getComponents()
                        if x.provides.satisfies(thisReq)]:
                    self._addRequirement(path, req, [], pkgFiles,
                                         deps.PerlDependencies)

        self.whiteOut(path, pkgFiles)
        self.unionDeps(path, pkgFiles)