mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-02 09:52:27 -04:00
ppackage -H is convenient
This commit is contained in:
parent
846505743d
commit
b4900f139b
@ -1851,6 +1851,11 @@ class Packager:
|
||||
# Particularly useful on OSX to reference the universal SDK.
|
||||
self.systemRoot = None
|
||||
|
||||
# Set this true to treat setHost() the same as addHost(), thus
|
||||
# ignoring any request to specify a particular download host,
|
||||
# e.g. for testing and development.
|
||||
self.ignoreSetHost = False
|
||||
|
||||
# The download URL at which these packages will eventually be
|
||||
# hosted.
|
||||
self.hosts = {}
|
||||
@ -2065,7 +2070,9 @@ class Packager:
|
||||
""" Specifies the URL that will ultimately host these
|
||||
contents. """
|
||||
|
||||
self.host = host
|
||||
if not self.ignoreSetHost:
|
||||
self.host = host
|
||||
|
||||
self.addHost(host, downloadUrl = downloadUrl,
|
||||
descriptiveName = descriptiveName, hostDir = hostDir,
|
||||
mirrors = mirrors)
|
||||
|
@ -106,6 +106,12 @@ Options:
|
||||
instead of the system library. This is particularly useful for
|
||||
cross-compilation. At the moment, this is supported only on OSX.
|
||||
|
||||
-H
|
||||
Treats a packager.setHost() call in the pdef file as if it were
|
||||
merely a call to packager.addHost(). This allows producing a
|
||||
package for an alternate host than its normally configured host,
|
||||
which is sometimes useful in development.
|
||||
|
||||
-h
|
||||
Display this help
|
||||
"""
|
||||
@ -129,10 +135,11 @@ signParams = []
|
||||
allowPythonDev = False
|
||||
universalBinaries = False
|
||||
systemRoot = None
|
||||
ignoreSetHost = False
|
||||
platforms = []
|
||||
|
||||
try:
|
||||
opts, args = getopt.getopt(sys.argv[1:], 'i:ps:S:DuP:R:h')
|
||||
opts, args = getopt.getopt(sys.argv[1:], 'i:ps:S:DuP:R:Hh')
|
||||
except getopt.error, msg:
|
||||
usage(1, msg)
|
||||
|
||||
@ -157,6 +164,8 @@ for opt, arg in opts:
|
||||
platforms.append(arg)
|
||||
elif opt == '-R':
|
||||
systemRoot = arg
|
||||
elif opt == '-H':
|
||||
ignoreSetHost = True
|
||||
|
||||
elif opt == '-h':
|
||||
usage(0)
|
||||
@ -200,6 +209,7 @@ for platform in platforms:
|
||||
packager.signParams = signParams
|
||||
packager.allowPythonDev = allowPythonDev
|
||||
packager.systemRoot = systemRoot
|
||||
packager.ignoreSetHost = ignoreSetHost
|
||||
|
||||
try:
|
||||
packager.setup()
|
||||
|
Loading…
x
Reference in New Issue
Block a user