Пример #1
0
    def install(self):
        src = self.sourceDir()
        dst = self.imageDir()

        if not os.path.isdir(dst):
            os.mkdir(dst)
        if not os.path.isdir(os.path.join(dst, "bin")):
            os.mkdir(os.path.join(dst, "bin"))
        if not os.path.isdir(os.path.join(dst, "lib")):
            os.mkdir(os.path.join(dst, "lib"))
        if not os.path.isdir(os.path.join(dst, "include")):
            os.mkdir(os.path.join(dst, "include"))

        if self.staticBuild:
            outdir = "out32"
        else:
            outdir = "out32dll"

        if not self.staticBuild:
            shutil.copy(os.path.join(src, outdir, "libeay32.dll"),
                        os.path.join(dst, "bin"))
            shutil.copy(os.path.join(src, outdir, "ssleay32.dll"),
                        os.path.join(dst, "bin"))
        shutil.copy(os.path.join(src, outdir, "libeay32.lib"),
                    os.path.join(dst, "lib"))
        shutil.copy(os.path.join(src, outdir, "ssleay32.lib"),
                    os.path.join(dst, "lib"))
        utils.copyDir(os.path.join(src, "inc32"), os.path.join(dst, "include"))

        return True
Пример #2
0
 def install(self):
     if not AutoToolsPackageBase.cleanImage(self):
         return False
     os.makedirs(os.path.join(self.imageDir(), "bin"))
     os.makedirs(os.path.join(self.imageDir(), "lib"))
     os.makedirs(os.path.join(self.imageDir(), "include", "ghostscript"))
     utils.copyDir(os.path.join(self.sourceDir(), "sobin"),
                   os.path.join(self.imageDir(), "bin"), False)
     utils.moveFile(os.path.join(self.imageDir(), "bin", "libgs.dll.a"),
                    os.path.join(self.imageDir(), "lib", "libgs.dll.a"))
     utils.copyFile(
         os.path.join(self.sourceDir(), "psi", "iapi.h"),
         os.path.join(self.imageDir(), "include", "ghostscript", "iapi.h"),
         False)
     utils.copyFile(
         os.path.join(self.sourceDir(), "psi", "ierrors.h"),
         os.path.join(self.imageDir(), "include", "ghostscript",
                      "ierrors.h"), False)
     utils.copyFile(
         os.path.join(self.sourceDir(), "devices", "gdevdsp.h"),
         os.path.join(self.imageDir(), "include", "ghostscript",
                      "gdevdsp.h"), False)
     utils.copyFile(
         os.path.join(self.sourceDir(), "base", "gserrors.h"),
         os.path.join(self.imageDir(), "include", "ghostscript",
                      "gserrors.h"), False)
     utils.copyDir(os.path.join(self.sourceDir(), "lib"),
                   os.path.join(self.imageDir(), "lib"), False)
     return True
Пример #3
0
 def install(self):
     if not AutoToolsPackageBase.cleanImage(self):
         return False
     os.makedirs(os.path.join(self.imageDir(), "bin"))
     os.makedirs(os.path.join(self.imageDir(), "lib"))
     os.makedirs(os.path.join(self.imageDir(), "include", "ghostscript"))
     utils.copyDir(os.path.join(self.sourceDir(), "sobin"), os.path.join(self.imageDir(), "bin"), False)
     utils.moveFile(
         os.path.join(self.imageDir(), "bin", "libgs.dll.a"), os.path.join(self.imageDir(), "lib", "libgs.dll.a")
     )
     utils.copyFile(
         os.path.join(self.sourceDir(), "psi", "iapi.h"),
         os.path.join(self.imageDir(), "include", "ghostscript", "iapi.h"),
         False,
     )
     utils.copyFile(
         os.path.join(self.sourceDir(), "psi", "ierrors.h"),
         os.path.join(self.imageDir(), "include", "ghostscript", "ierrors.h"),
         False,
     )
     utils.copyFile(
         os.path.join(self.sourceDir(), "devices", "gdevdsp.h"),
         os.path.join(self.imageDir(), "include", "ghostscript", "gdevdsp.h"),
         False,
     )
     utils.copyFile(
         os.path.join(self.sourceDir(), "base", "gserrors.h"),
         os.path.join(self.imageDir(), "include", "ghostscript", "gserrors.h"),
         False,
     )
     utils.copyDir(os.path.join(self.sourceDir(), "lib"), os.path.join(self.imageDir(), "lib"), False)
     return True
Пример #4
0
    def install( self ):
        src = self.sourceDir()
        dst = self.imageDir()

        if not os.path.isdir(dst):
            os.mkdir(dst)
        if not os.path.isdir(os.path.join(dst, "bin")):
            os.mkdir(os.path.join(dst, "bin"))
        if not os.path.isdir(os.path.join(dst, "lib")):
            os.mkdir(os.path.join(dst, "lib"))
        if not os.path.isdir(os.path.join(dst, "include")):
            os.mkdir(os.path.join(dst, "include"))
        if not os.path.isdir(os.path.join(dst, "include", "ghostscript")):
            os.mkdir(os.path.join(dst, "include", "ghostscript"))

        if compiler.isX64():
            _bit = "64"
        else:
            _bit = "32"
        utils.copyFile(os.path.join(src, "bin", "gsdll%s.dll" % _bit), os.path.join(dst, "bin"), False)
        utils.copyFile(os.path.join(src, "bin", "gsdll%s.lib" % _bit), os.path.join(dst, "lib"), False)
        utils.copyFile(os.path.join(src, "bin", "gswin%s.exe" % _bit), os.path.join(dst, "bin"), False)
        utils.copyFile(os.path.join(src, "bin", "gswin%sc.exe" % _bit), os.path.join(dst, "bin"), False)
        utils.copyFile(os.path.join(self.sourceDir(), "psi", "iapi.h"), os.path.join(self.imageDir(), "include", "ghostscript", "iapi.h"), False)
        utils.copyFile(os.path.join(self.sourceDir(), "psi", "ierrors.h"), os.path.join(self.imageDir(), "include", "ghostscript", "ierrors.h"), False)
        utils.copyFile(os.path.join(self.sourceDir(), "devices", "gdevdsp.h"), os.path.join(self.imageDir(), "include", "ghostscript", "gdevdsp.h"), False)
        utils.copyFile(os.path.join(self.sourceDir(), "base", "gserrors.h"), os.path.join(self.imageDir(), "include", "ghostscript", "gserrors.h"), False)
        utils.copyDir(os.path.join(self.sourceDir(), "lib"), os.path.join(self.imageDir(), "lib"), False)

        return True
Пример #5
0
    def install(self):
        utils.copyDir(os.path.join(self.sourceDir(), "..", "bin"), os.path.join(self.imageDir(), "bin"))
        utils.copyDir(os.path.join(self.sourceDir(), "..", "bin64"), os.path.join(self.imageDir(), "bin"))
        utils.copyDir(os.path.join(self.sourceDir(), "..", "include"), os.path.join(self.imageDir(), "include"))
        utils.copyDir(os.path.join(self.sourceDir(), "..", "lib"), os.path.join(self.imageDir(), "lib"))
        utils.copyDir(os.path.join(self.sourceDir(), "..", "lib64"), os.path.join(self.imageDir(), "lib"))

        if compiler.isMSVC() and self.buildType() == "Debug":
            imagedir = os.path.join( self.installDir(), "lib" )
            filelist = os.listdir( imagedir )
            for f in filelist:
                if f.endswith( "d.lib" ):
                    utils.copyFile( os.path.join( imagedir, f ), os.path.join( imagedir, f.replace( "d.lib", ".lib" ) ) )

        return True
Пример #6
0
    def install( self ):
        srcdir = self.sourceDir()
        dstdir = self.installDir()

        utils.cleanDirectory( dstdir )
        os.makedirs (os.path.join (dstdir, "lib", "R"))
        os.makedirs (os.path.join (dstdir, "bin"))

        # place everything in dstdir/lib/R (similar to debian packaging)
        portage.remInstalled( self.category, self.package, "stablelatest" )
        utils.copyDir (srcdir, os.path.join (dstdir, "lib", "R"))

        # create a shortcut in dstdir/bin
        f = open(os.path.join (dstdir, "bin", "R.bat"), "w")
        f.write("REM redirect to R.exe, autocreated during installation\n" + os.path.join ("%~dsp0", "..", "lib", "R", "bin", "R.exe") + " %1 %2 %3 %4 %5 %6 %7 %8 %9\n")
        f.close()

        return True
Пример #7
0
    def install(self):
        utils.copyDir(os.path.join(self.sourceDir(), "..", "bin"),
                      os.path.join(self.imageDir(), "bin"))
        utils.copyDir(os.path.join(self.sourceDir(), "..", "bin64"),
                      os.path.join(self.imageDir(), "bin"))
        utils.copyDir(os.path.join(self.sourceDir(), "..", "include"),
                      os.path.join(self.imageDir(), "include"))
        utils.copyDir(os.path.join(self.sourceDir(), "..", "lib"),
                      os.path.join(self.imageDir(), "lib"))
        utils.copyDir(os.path.join(self.sourceDir(), "..", "lib64"),
                      os.path.join(self.imageDir(), "lib"))

        if compiler.isMSVC() and self.buildType() == "Debug":
            imagedir = os.path.join(self.installDir(), "lib")
            filelist = os.listdir(imagedir)
            for f in filelist:
                if f.endswith("d.lib"):
                    utils.copyFile(
                        os.path.join(imagedir, f),
                        os.path.join(imagedir, f.replace("d.lib", ".lib")))

        return True