Esempio n. 1
0
 def _clean(self):
     # Cleaning in Tools is done explicitly in rbuild script
     # and do not want it run a second time and complaining.
     if not utils.in_tools_tree():
         if os.path.exists("setup.py"):
             utils.run("%s setup.py clean" % self._pycmd)
     Builder._clean(self)
Esempio n. 2
0
 def _configure(self):
     if self._ccom:
         if utils.in_tools_tree():
             self._prefix = self._askaproot
         cmd = "./%s %s --prefix=%s" % (self._ccom, self._opts,
                                        self._prefix)
         utils.run(cmd, self.nowarnings)
Esempio n. 3
0
 def _create_init(self):
     '''
     Create an init script for this package if in Code or 3rdParty.
     '''
     if self.no_initscript or utils.in_tools_tree():
         return
     env = utils.Environment(self.dep, self._prefix,
                             os.path.join(self._bdir, self._infofile))
     utils.create_init_file(self._initscript_name, env)
Esempio n. 4
0
 def _configure(self):
     if self._ccom:
         if utils.in_tools_tree():
             self._prefix = self._askaproot
         if not os.path.exists(self._cmakedir):
             os.makedirs(self._cmakedir)
         os.chdir(self._cmakedir)
         utils.run('%s %s -DCMAKE_INSTALL_PREFIX=%s ..' %
                   (self._ccom, self._opts, self._prefix), self.nowarnings)
Esempio n. 5
0
    def _install(self):
        if os.path.exists("setupegg.py"):
            cmd = "%s setupegg.py install" % self._pycmd
        else:
            cmd = "%s setup.py install" % self._pycmd

        if utils.in_tools_tree():
            msg = "info: 'setuptools egg install', imports use default version."
        else:
            msg = "info: 'setuptools in local 'install' directory."
            installdir = os.path.join(self._bdir, self._installdir)
            cmd += " --prefix %s" % installdir
            utils.create_python_tree(installdir)

        utils.run("%s %s" % (self._get_env(), cmd), self.nowarnings)
        utils.q_print(msg)
        self._version_install()