[Zope-Checkins] CVS: Zope/lib/python/App - config.py:1.2
Fred L. Drake, Jr.
fred@zope.com
Mon, 24 Feb 2003 15:11:10 -0500
Update of /cvs-repository/Zope/lib/python/App
In directory cvs.zope.org:/tmp/cvs-serv28555
Modified Files:
config.py
Log Message:
More legacy 3rd-party support, making sure various sources of
information don't get out of sync.
=== Zope/lib/python/App/config.py 1.1 => 1.2 ===
--- Zope/lib/python/App/config.py:1.1 Tue Feb 11 12:17:04 2003
+++ Zope/lib/python/App/config.py Mon Feb 24 15:11:10 2003
@@ -48,6 +48,15 @@
__builtin__.SOFTWARE_HOME = FindHomes.SOFTWARE_HOME = cfg.softwarehome
__builtin__.ZOPE_HOME = FindHomes.ZOPE_HOME = cfg.zopehome
+ # XXX make sure the environment variables, if set, don't get out
+ # of sync. This is needed to support 3rd-party code written to
+ # support Zope versions prior to 2.7.
+ import os
+ os.environ["CLIENT_HOME"] = cfg.clienthome
+ os.environ["INSTANCE_HOME"] = cfg.instancehome
+ os.environ["SOFTWARE_HOME"] = cfg.softwarehome
+ os.environ["ZOPE_HOME"] = cfg.zopehome
+
import sys
if "Globals" in sys.modules:
# XXX We *really* want to avoid this if Globals hasn't already