direct.p3d.DeploymentTools

from direct.p3d.DeploymentTools import Icon, Installer, PackageTree, Standalone, TarInfoRoot, TarInfoRootOSX, archiveFilter

This module is used to build a graphical installer or a standalone executable from a p3d file. It will try to build for as many platforms as possible.

Deprecated since version 1.10.0: The p3d packaging system has been replaced with the new setuptools-based system. See the Distributing Panda3D Applications manual section.

Inheritance diagram

Inheritance diagram of direct.p3d.DeploymentTools

class Icon[source]

Bases: object

This class is used to create an icon for various platforms.

__init__(self)[source]
addImage(self, image)[source]

Adds an image to the icon. Returns False on failure, True on success. Only one image per size can be loaded, and the image size must be square.

generateMissingImages(self)[source]

Generates image sizes that should be present but aren’t by scaling from the next higher size.

makeICNS(self, fn)[source]

Writes the images to an Apple ICNS file. Returns True on success.

makeICO(self, fn)[source]

Writes the images to a Windows ICO file. Returns True on success.

notify = <direct.directnotify.Notifier.Notifier object>
class Installer(p3dfile, shortname, fullname, version, tokens={})[source]

Bases: object

This class creates a (graphical) installer from a given .p3d file.

__init__(self, p3dfile, shortname, fullname, version, tokens={})[source]
build(self, output, platform=None)[source]

Builds (graphical) installers and stores it into the path indicated by the ‘output’ argument. You can specify to build for a different platform by altering the ‘platform’ argument. If ‘output’ is a directory, the installer will be stored in it.

buildAPP(self, output, platform)[source]
buildAll(self, outputDir='.')[source]

Creates a (graphical) installer for every known platform. Call this after you have set the desired parameters.

buildArch(self, output, platform)[source]

Builds an ArchLinux package and stores it in the path indicated by the ‘output’ argument. It will be built for the architecture specified by the ‘arch’ argument. If ‘output’ is a directory, the deb file will be stored in it.

buildDEB(self, output, platform)[source]

Builds a .deb archive and stores it in the path indicated by the ‘output’ argument. It will be built for the architecture specified by the ‘arch’ argument. If ‘output’ is a directory, the deb file will be stored in it.

buildNSIS(self, output, platform)[source]
buildPKG(self, output, platform)[source]
installPackagesInto(self, hostDir, platform)[source]

Installs the packages required by the .p3d file into the specified directory, for the given platform.

notify = <direct.directnotify.Notifier.Notifier object>
os_walk(self, top)[source]

Re-implements os.walk(). For some reason the built-in definition is failing on Windows when this is run within a p3d environment!?

class PackageTree(platform, hostDir, hostUrl)[source]

Bases: object

A class used internally to build a temporary package tree for inclusion into an installer.

__init__(self, platform, hostDir, hostUrl)[source]
getHost(self, hostUrl)[source]
installPackage(self, name, version, hostUrl=None)[source]

Installs the named package into the tree.

class Standalone(p3dfile, tokens={})[source]

Bases: object

This class creates a standalone executable from a given .p3d file.

__init__(self, p3dfile, tokens={})[source]
build(self, output, platform=None, extraTokens={})[source]

Builds a standalone executable and stores it into the path indicated by the ‘output’ argument. You can specify to build for a different platform by altering the ‘platform’ argument.

buildAll(self, outputDir='.')[source]

Builds standalone executables for every known platform, into the specified output directory.

embed(self, output, p3dembed, extraTokens={})[source]

Embeds the p3d file into the provided p3dembed executable. This function is not really useful - use build() or buildAll() instead.

getExtraFiles(self, platform)[source]

Returns a list of extra files that will need to be included with the standalone executable in order for it to run, such as dependent libraries. The returned paths are full absolute paths.

notify = <direct.directnotify.Notifier.Notifier object>
class TarInfoRoot(name='')[source]

Bases: TarInfo

chksum
devmajor
devminor
gid
gname
linkname
mode
mtime
name
offset
offset_data
pax_headers
size
sparse
tarfile
type
uid
uname
class TarInfoRootOSX(name='')[source]

Bases: TarInfoRoot

chksum
devmajor
devminor
gid
gname
linkname
mode
mtime
name
offset
offset_data
pax_headers
size
sparse
tarfile
type
uid
uname
archiveFilter(info)[source]