コード例 #1
0
    def __init__(self, **args):
        self.subinfo = subinfo()
        CMakePackageBase.__init__(self)

        self.subinfo.options.configure.defines = (
                " --build-type=minimal"
                " --build-dir=" + self.buildDir() + \
                " --prefix=" + self.imageDir() + \
                " --stagedir=" + os.path.join(self.buildDir(),"stage") + \
                " threading=multi"
                " link=shared"
                " runtime-link=shared")

        self.subinfo.options.configure.defines += " variant="
        if self.buildType() == "Debug":
            self.subinfo.options.configure.defines += "debug"
        else:
            self.subinfo.options.configure.defines += "release"
        self.subinfo.options.configure.defines += " toolset="
        if compiler.isMinGW():
            self.subinfo.options.configure.defines += "gcc"
        else:
            if compiler.isMSVC2005():
                self.subinfo.options.configure.defines += "msvc-8.0"
            elif compiler.isMSVC2008():
                self.subinfo.options.configure.defines += "msvc-9.0"
            elif compiler.isMSVC2010():
                self.subinfo.options.configure.defines += "msvc-10.0"
        if self.isHostBuild():
            self.subinfo.options.configure.defines += " --with-program_options"
        if not emergePlatform.isCrossCompilingEnabled():
            self.subinfo.options.configure.defines += " --with-python"
コード例 #2
0
 def make(self):
     if self.subinfo.defaultTarget == '1.44.0':
         return True
     cmd  = "build.bat "
     if compiler.isMinGW():
         cmd += "gcc"
     else:
         if compiler.isMSVC2005():
             cmd += "vc8"
         elif compiler.isMSVC2008():
             cmd += "vc9"
         elif compiler.isMSVC2010():
             cmd += "vc10"
     if utils.verbose() >= 1:
         print cmd
     utils.system(cmd, cwd = os.path.join(portage.getPackageInstance('win32libs-bin',
             'boost-headers').sourceDir(),"tools","build","v2","engine")) or utils.die(
             "command: %s failed" % (cmd))
     return True