mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-01 01:07:51 -04:00
minor fixes
This commit is contained in:
parent
ab98281c44
commit
b469a507a1
@ -820,8 +820,6 @@ class PackageInfo:
|
||||
vfs = VirtualFileSystem.getGlobalPtr()
|
||||
vfs.mount(mf, root, vfs.MFReadOnly)
|
||||
|
||||
appRunner.loadMultifilePrcFiles(mf, root)
|
||||
|
||||
# Add this to the Python search path, if it's not already
|
||||
# there. We have to take a bit of care to check if it's
|
||||
# already there, since there can be some ambiguity in
|
||||
@ -851,6 +849,10 @@ class PackageInfo:
|
||||
envvar = '%s_ROOT' % (self.packageName.upper())
|
||||
ExecutionEnvironment.setEnvironmentVariable(envvar, self.packageDir.toOsSpecific())
|
||||
|
||||
# Now that the environment variable is set, read all of the
|
||||
# prc files in the package.
|
||||
appRunner.loadMultifilePrcFiles(mf, root)
|
||||
|
||||
# Also, find any toplevel Python packages, and add these as
|
||||
# shared packages. This will allow different packages
|
||||
# installed in different directories to share Python files as
|
||||
|
@ -352,7 +352,8 @@ class Packager:
|
||||
self.compressionLevel = 6
|
||||
|
||||
# Every p3dapp requires panda3d.
|
||||
self.packager.do_require('panda3d')
|
||||
if 'panda3d' not in map(lambda p: p.packageName, self.requires):
|
||||
self.packager.do_require('panda3d')
|
||||
|
||||
# If this flag is set, enable allow_python_dev.
|
||||
if self.packager.allowPythonDev:
|
||||
|
@ -44,7 +44,7 @@ Options:
|
||||
Sets the indicated config flag in the application. This option
|
||||
may be repeated as necessary.
|
||||
|
||||
-r package
|
||||
-r package[,version[,hostURL]]
|
||||
Names an additional package that this application requires at
|
||||
startup time. The default package is 'panda3d'; you may repeat
|
||||
this option to indicate dependencies on additional packages.
|
||||
@ -106,7 +106,11 @@ def makePackedApp(args):
|
||||
elif option == '-c':
|
||||
configFlags.append(value.split('=', 1))
|
||||
elif option == '-r':
|
||||
requires.append(value)
|
||||
tokens = value.split(',')
|
||||
while len(tokens) < 3:
|
||||
tokens.append('')
|
||||
name, version, host = tokens[:3]
|
||||
requires.append((name, version, host))
|
||||
elif option == '-s':
|
||||
packager.installSearch.appendDirectory(Filename.fromOsSpecific(value))
|
||||
elif option == '-D':
|
||||
@ -159,11 +163,7 @@ def makePackedApp(args):
|
||||
try:
|
||||
packager.setup()
|
||||
packager.beginPackage(appBase, p3dApplication = True)
|
||||
for requireName in requires:
|
||||
tokens = requireName.split(',')
|
||||
while len(tokens) < 3:
|
||||
tokens.append(None)
|
||||
name, version, host = tokens
|
||||
for name, version, host in requires:
|
||||
packager.do_require(name, version = version, host = host)
|
||||
|
||||
if configFlags:
|
||||
|
Loading…
x
Reference in New Issue
Block a user