From ca8149ca6d157eb4b5fc8ba0e5ba3a6e56f72e7e Mon Sep 17 00:00:00 2001 From: Jacek Antonelli Date: Thu, 30 Apr 2009 13:04:20 -0500 Subject: Second Life viewer sources 1.23.0-RC --- linden/scripts/install.py | 75 +++++++++++++++--------- linden/scripts/messages/message_template.msg | 88 ++++++++++++++++++++++++++-- linden/scripts/setup-path.py | 3 +- linden/scripts/template_verifier.py | 40 +++++++------ 4 files changed, 155 insertions(+), 51 deletions(-) (limited to 'linden/scripts') diff --git a/linden/scripts/install.py b/linden/scripts/install.py index f886a6e..5069918 100755 --- a/linden/scripts/install.py +++ b/linden/scripts/install.py @@ -33,6 +33,36 @@ THE SOFTWARE. $/LicenseInfo$ """ +import sys +import os.path + +# Look for indra/lib/python in all possible parent directories ... +# This is an improvement over the setup-path.py method used previously: +# * the script may blocated anywhere inside the source tree +# * it doesn't depend on the current directory +# * it doesn't depend on another file being present. + +def add_indra_lib_path(): + root = os.path.realpath(__file__) + # always insert the directory of the script in the search path + dir = os.path.dirname(root) + if dir not in sys.path: + sys.path.insert(0, dir) + + # Now go look for indra/lib/python in the parent dies + while root != os.path.sep: + root = os.path.dirname(root) + dir = os.path.join(root, 'indra', 'lib', 'python') + if os.path.isdir(dir): + if dir not in sys.path: + sys.path.insert(0, dir) + return root + else: + print >>sys.stderr, "This script is not inside a valid installation." + sys.exit(1) + +base_dir = add_indra_lib_path() + import copy import md5 import optparse @@ -40,7 +70,6 @@ import os import platform import pprint import shutil -import sys import tarfile import tempfile import urllib2 @@ -48,20 +77,21 @@ import urlparse from sets import Set as set, ImmutableSet as frozenset -# Locate -our- python library relative to our install location. -from os.path import realpath, dirname, join - -# Walk back to checkout base directory -base_dir = dirname(dirname(realpath(__file__))) -# Walk in to libraries directory -lib_dir = join(join(join(base_dir, 'indra'), 'lib'), 'python') - -if lib_dir not in sys.path: - sys.path.insert(0, lib_dir) - from indra.base import llsd from indra.util import helpformatter +# *HACK: Necessary for python 2.3. Consider removing this code wart +# after etch has deployed everywhere. 2008-12-23 Phoenix +try: + sorted = sorted +except NameError: + def sorted(in_list): + "Return a list which is a sorted copy of in_list." + # Copy the source to be more functional and side-effect free. + out_list = copy.copy(in_list) + out_list.sort() + return out_list + class InstallFile(object): "This is just a handy way to throw around details on a file in memory." def __init__(self, pkgname, url, md5sum, cache_dir, platform_path): @@ -291,7 +321,7 @@ class Installer(object): def list_installables(self): "Return a list of all known installables." - return self._installables.keys() + return sorted(self._installables.keys()) def detail_installable(self, name): "Return a installable definition detail" @@ -299,7 +329,7 @@ class Installer(object): def list_licenses(self): "Return a list of all known licenses." - return self._licenses.keys() + return sorted(self._licenses.keys()) def detail_license(self, name): "Return a license definition detail" @@ -307,7 +337,7 @@ class Installer(object): def list_installed(self): "Return a list of installed packages." - return self._installed.keys() + return sorted(self._installed.keys()) def detail_installed(self, name): "Return file list for specific installed package." @@ -750,17 +780,6 @@ def _get_platform(): # os/arch/compiler/compiler_version then we can replace the # 'linux64' platform with 'linux/x86_64/gcc/4.1' this_platform = 'linux64' - else: - gcc_version = os.popen("g++ -dumpversion", 'r').read()[:-3] - if gcc_version == '4.1': - # the 'linux32' platform is a HACK until we can figure - # out how to make the install.py script accept a platform of - # the form os/arch/compiler/compiler_version for the download - # and extract stage - #this_platform = 'linux/i686/gcc/4.1' - # NOTE: disabled linux32 as it hasn't been tested well - #this_platform = 'linux32' - this_platform = this_platform return this_platform def _getuser(): @@ -832,13 +851,13 @@ darwin/universal/gcc/4.0 parser.add_option( '--install-manifest', type='string', - default=join(base_dir, 'install.xml'), + default=os.path.join(base_dir, 'install.xml'), dest='install_filename', help='The file used to describe what should be installed.') parser.add_option( '--installed-manifest', type='string', - default=join(base_dir, 'installed.xml'), + default=os.path.join(base_dir, 'installed.xml'), dest='installed_filename', help='The file used to record what is installed.') parser.add_option( diff --git a/linden/scripts/messages/message_template.msg b/linden/scripts/messages/message_template.msg index a7835ad..0dee61a 100644 --- a/linden/scripts/messages/message_template.msg +++ b/linden/scripts/messages/message_template.msg @@ -594,7 +594,7 @@ version 2.0 // global x,y,z. Otherwise, use center of the AABB. // reliable { - PlacesReply Low 30 Trusted Zerocoded + PlacesReply Low 30 Trusted Zerocoded UDPDeprecated { AgentData Single { AgentID LLUUID } @@ -619,6 +619,7 @@ version 2.0 { SnapshotID LLUUID } { Dwell F32 } { Price S32 } + //{ ProductSKU Variable 1 } } } @@ -723,6 +724,10 @@ version 2.0 { Auction BOOL } { Dwell F32 } } + { + StatusData Variable + { Status U32 } + } } // DirPeopleReply @@ -767,6 +772,10 @@ version 2.0 { UnixTime U32 } { EventFlags U32 } } + { + StatusData Variable + { Status U32 } + } } // DirGroupsReply @@ -852,6 +861,10 @@ version 2.0 { ExpirationDate U32 } { PriceForListing S32 } } + { + StatusData Variable + { Status U32 } + } } @@ -1036,7 +1049,7 @@ version 2.0 // dataserver -> simulator -> viewer // reliable { - DirLandReply Low 50 Trusted Zerocoded + DirLandReply Low 50 Trusted Zerocoded UDPDeprecated { AgentData Single { AgentID LLUUID } @@ -1053,6 +1066,7 @@ version 2.0 { ForSale BOOL } { SalePrice S32 } { ActualArea S32 } + //{ ProductSKU Variable 1 } } } @@ -1465,7 +1479,7 @@ version 2.0 } } -// TeleportFailed somehwere->sim->viewer +// TeleportFailed somewhere->sim->viewer // announce failure of teleport request { TeleportFailed Low 74 Trusted Unencoded @@ -1474,6 +1488,11 @@ version 2.0 { AgentID LLUUID } { Reason Variable 1 } // string } + { + AlertInfo Variable + { Message Variable 1 } // string id + { ExtraParams Variable 1 } // llsd extra parameters + } } @@ -2589,6 +2608,10 @@ version 2.0 { East F32 } { North F32 } } + { + ModifyBlockExtended Variable + { BrushSize F32 } + } } @@ -2806,6 +2829,11 @@ version 2.0 AlertData Single { Message Variable 1 } } + { + AlertInfo Variable + { Message Variable 1 } + { ExtraParams Variable 1 } + } } // Send an AlertMessage to the named agent. @@ -2942,6 +2970,14 @@ version 2.0 { UseEstateSun BOOL } { SunHour F32 } // last value set by estate or region controls JC } + { + RegionInfo2 Single + { ProductSKU Variable 1 } // string + { ProductName Variable 1 } // string + { MaxAgents32 U32 } // Identical to RegionInfo.MaxAgents but allows greater range + { HardMaxAgents U32 } + { HardMaxObjects U32 } + } } // GodUpdateRegionInfo @@ -3059,6 +3095,14 @@ version 2.0 RegionInfo2 Single { RegionID LLUUID } } + { + RegionInfo3 Single + { CPUClassID S32 } + { CPURatio S32 } + { ColoName Variable 1 } // string + { ProductSKU Variable 1 } // string + { ProductName Variable 1 } // string + } } // RegionHandshakeReply @@ -8701,7 +8745,7 @@ version 2.0 // spaceserver -> simulator { - RpcScriptRequestInboundForward Low 416 Trusted Unencoded + RpcScriptRequestInboundForward Low 416 Trusted Unencoded UDPDeprecated { DataBlock Single { RPCServerIP IPADDR } @@ -8854,3 +8898,39 @@ version 2.0 } } + +// This message is sent from viewer -> simulator when the viewer wants +// to rez an object out of inventory back to its position before it +// last moved into the inventory +{ + RezRestoreToWorld Low 425 NotTrusted Unencoded UDPDeprecated + { + AgentData Single + { AgentID LLUUID } + { SessionID LLUUID } + } + { + InventoryData Single + { ItemID LLUUID } + { FolderID LLUUID } + { CreatorID LLUUID } // permissions + { OwnerID LLUUID } // permissions + { GroupID LLUUID } // permissions + { BaseMask U32 } // permissions + { OwnerMask U32 } // permissions + { GroupMask U32 } // permissions + { EveryoneMask U32 } // permissions + { NextOwnerMask U32 } // permissions + { GroupOwned BOOL } // permissions + { TransactionID LLUUID } + { Type S8 } + { InvType S8 } + { Flags U32 } + { SaleType U8 } + { SalePrice S32 } + { Name Variable 1 } + { Description Variable 1 } + { CreationDate S32 } + { CRC U32 } + } +} diff --git a/linden/scripts/setup-path.py b/linden/scripts/setup-path.py index 7a73dad..157bda0 100755 --- a/linden/scripts/setup-path.py +++ b/linden/scripts/setup-path.py @@ -19,7 +19,8 @@ online at http://secondlifegrid.net/programs/open_source/licensing/gplv2 There are special exceptions to the terms and conditions of the GPL as it is applied to this Source Code. View the full text of the exception in the file doc/FLOSS-exception.txt in this software distribution, or -online at http://secondlifegrid.net/programs/open_source/licensing/flossexception +online at +http://secondlifegrid.net/programs/open_source/licensing/flossexception By copying, modifying or distributing this software, you acknowledge that you have read and understood your obligations described above, diff --git a/linden/scripts/template_verifier.py b/linden/scripts/template_verifier.py index de9a444..8bb5e1d 100755 --- a/linden/scripts/template_verifier.py +++ b/linden/scripts/template_verifier.py @@ -18,7 +18,8 @@ online at http://secondlifegrid.net/programs/open_source/licensing/gplv2 There are special exceptions to the terms and conditions of the GPL as it is applied to this Source Code. View the full text of the exception in the file doc/FLOSS-exception.txt in this software distribution, or -online at http://secondlifegrid.net/programs/open_source/licensing/flossexception +online at +http://secondlifegrid.net/programs/open_source/licensing/flossexception By copying, modifying or distributing this software, you acknowledge that you have read and understood your obligations described above, @@ -47,23 +48,26 @@ import os.path # * it doesn't depend on the current directory # * it doesn't depend on another file being present. -root = os.path.abspath(__file__) -# always insert the directory of the script in the search path -dir = os.path.dirname(root) -if dir not in sys.path: - sys.path.insert(0, dir) - -# Now go look for indra/lib/python in the parent dies -while root != os.path.sep: - root = os.path.dirname(root) - dir = os.path.join(root, 'indra', 'lib', 'python') - if os.path.isdir(dir): - if dir not in sys.path: - sys.path.insert(0, dir) - break -else: - print >>sys.stderr, "This script is not inside a valid installation." - sys.exit(1) +def add_indra_lib_path(): + root = os.path.realpath(__file__) + # always insert the directory of the script in the search path + dir = os.path.dirname(root) + if dir not in sys.path: + sys.path.insert(0, dir) + + # Now go look for indra/lib/python in the parent dies + while root != os.path.sep: + root = os.path.dirname(root) + dir = os.path.join(root, 'indra', 'lib', 'python') + if os.path.isdir(dir): + if dir not in sys.path: + sys.path.insert(0, dir) + break + else: + print >>sys.stderr, "This script is not inside a valid installation." + sys.exit(1) + +add_indra_lib_path() import optparse import os -- cgit v1.1