diff options
Diffstat (limited to 'linden/scripts')
-rwxr-xr-x | linden/scripts/install.py | 75 | ||||
-rw-r--r-- | linden/scripts/messages/message_template.msg | 88 | ||||
-rwxr-xr-x | linden/scripts/setup-path.py | 3 | ||||
-rwxr-xr-x | linden/scripts/template_verifier.py | 40 |
4 files changed, 155 insertions, 51 deletions
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. | |||
33 | $/LicenseInfo$ | 33 | $/LicenseInfo$ |
34 | """ | 34 | """ |
35 | 35 | ||
36 | import sys | ||
37 | import os.path | ||
38 | |||
39 | # Look for indra/lib/python in all possible parent directories ... | ||
40 | # This is an improvement over the setup-path.py method used previously: | ||
41 | # * the script may blocated anywhere inside the source tree | ||
42 | # * it doesn't depend on the current directory | ||
43 | # * it doesn't depend on another file being present. | ||
44 | |||
45 | def add_indra_lib_path(): | ||
46 | root = os.path.realpath(__file__) | ||
47 | # always insert the directory of the script in the search path | ||
48 | dir = os.path.dirname(root) | ||
49 | if dir not in sys.path: | ||
50 | sys.path.insert(0, dir) | ||
51 | |||
52 | # Now go look for indra/lib/python in the parent dies | ||
53 | while root != os.path.sep: | ||
54 | root = os.path.dirname(root) | ||
55 | dir = os.path.join(root, 'indra', 'lib', 'python') | ||
56 | if os.path.isdir(dir): | ||
57 | if dir not in sys.path: | ||
58 | sys.path.insert(0, dir) | ||
59 | return root | ||
60 | else: | ||
61 | print >>sys.stderr, "This script is not inside a valid installation." | ||
62 | sys.exit(1) | ||
63 | |||
64 | base_dir = add_indra_lib_path() | ||
65 | |||
36 | import copy | 66 | import copy |
37 | import md5 | 67 | import md5 |
38 | import optparse | 68 | import optparse |
@@ -40,7 +70,6 @@ import os | |||
40 | import platform | 70 | import platform |
41 | import pprint | 71 | import pprint |
42 | import shutil | 72 | import shutil |
43 | import sys | ||
44 | import tarfile | 73 | import tarfile |
45 | import tempfile | 74 | import tempfile |
46 | import urllib2 | 75 | import urllib2 |
@@ -48,20 +77,21 @@ import urlparse | |||
48 | 77 | ||
49 | from sets import Set as set, ImmutableSet as frozenset | 78 | from sets import Set as set, ImmutableSet as frozenset |
50 | 79 | ||
51 | # Locate -our- python library relative to our install location. | ||
52 | from os.path import realpath, dirname, join | ||
53 | |||
54 | # Walk back to checkout base directory | ||
55 | base_dir = dirname(dirname(realpath(__file__))) | ||
56 | # Walk in to libraries directory | ||
57 | lib_dir = join(join(join(base_dir, 'indra'), 'lib'), 'python') | ||
58 | |||
59 | if lib_dir not in sys.path: | ||
60 | sys.path.insert(0, lib_dir) | ||
61 | |||
62 | from indra.base import llsd | 80 | from indra.base import llsd |
63 | from indra.util import helpformatter | 81 | from indra.util import helpformatter |
64 | 82 | ||
83 | # *HACK: Necessary for python 2.3. Consider removing this code wart | ||
84 | # after etch has deployed everywhere. 2008-12-23 Phoenix | ||
85 | try: | ||
86 | sorted = sorted | ||
87 | except NameError: | ||
88 | def sorted(in_list): | ||
89 | "Return a list which is a sorted copy of in_list." | ||
90 | # Copy the source to be more functional and side-effect free. | ||
91 | out_list = copy.copy(in_list) | ||
92 | out_list.sort() | ||
93 | return out_list | ||
94 | |||
65 | class InstallFile(object): | 95 | class InstallFile(object): |
66 | "This is just a handy way to throw around details on a file in memory." | 96 | "This is just a handy way to throw around details on a file in memory." |
67 | def __init__(self, pkgname, url, md5sum, cache_dir, platform_path): | 97 | def __init__(self, pkgname, url, md5sum, cache_dir, platform_path): |
@@ -291,7 +321,7 @@ class Installer(object): | |||
291 | 321 | ||
292 | def list_installables(self): | 322 | def list_installables(self): |
293 | "Return a list of all known installables." | 323 | "Return a list of all known installables." |
294 | return self._installables.keys() | 324 | return sorted(self._installables.keys()) |
295 | 325 | ||
296 | def detail_installable(self, name): | 326 | def detail_installable(self, name): |
297 | "Return a installable definition detail" | 327 | "Return a installable definition detail" |
@@ -299,7 +329,7 @@ class Installer(object): | |||
299 | 329 | ||
300 | def list_licenses(self): | 330 | def list_licenses(self): |
301 | "Return a list of all known licenses." | 331 | "Return a list of all known licenses." |
302 | return self._licenses.keys() | 332 | return sorted(self._licenses.keys()) |
303 | 333 | ||
304 | def detail_license(self, name): | 334 | def detail_license(self, name): |
305 | "Return a license definition detail" | 335 | "Return a license definition detail" |
@@ -307,7 +337,7 @@ class Installer(object): | |||
307 | 337 | ||
308 | def list_installed(self): | 338 | def list_installed(self): |
309 | "Return a list of installed packages." | 339 | "Return a list of installed packages." |
310 | return self._installed.keys() | 340 | return sorted(self._installed.keys()) |
311 | 341 | ||
312 | def detail_installed(self, name): | 342 | def detail_installed(self, name): |
313 | "Return file list for specific installed package." | 343 | "Return file list for specific installed package." |
@@ -750,17 +780,6 @@ def _get_platform(): | |||
750 | # os/arch/compiler/compiler_version then we can replace the | 780 | # os/arch/compiler/compiler_version then we can replace the |
751 | # 'linux64' platform with 'linux/x86_64/gcc/4.1' | 781 | # 'linux64' platform with 'linux/x86_64/gcc/4.1' |
752 | this_platform = 'linux64' | 782 | this_platform = 'linux64' |
753 | else: | ||
754 | gcc_version = os.popen("g++ -dumpversion", 'r').read()[:-3] | ||
755 | if gcc_version == '4.1': | ||
756 | # the 'linux32' platform is a HACK until we can figure | ||
757 | # out how to make the install.py script accept a platform of | ||
758 | # the form os/arch/compiler/compiler_version for the download | ||
759 | # and extract stage | ||
760 | #this_platform = 'linux/i686/gcc/4.1' | ||
761 | # NOTE: disabled linux32 as it hasn't been tested well | ||
762 | #this_platform = 'linux32' | ||
763 | this_platform = this_platform | ||
764 | return this_platform | 783 | return this_platform |
765 | 784 | ||
766 | def _getuser(): | 785 | def _getuser(): |
@@ -832,13 +851,13 @@ darwin/universal/gcc/4.0 | |||
832 | parser.add_option( | 851 | parser.add_option( |
833 | '--install-manifest', | 852 | '--install-manifest', |
834 | type='string', | 853 | type='string', |
835 | default=join(base_dir, 'install.xml'), | 854 | default=os.path.join(base_dir, 'install.xml'), |
836 | dest='install_filename', | 855 | dest='install_filename', |
837 | help='The file used to describe what should be installed.') | 856 | help='The file used to describe what should be installed.') |
838 | parser.add_option( | 857 | parser.add_option( |
839 | '--installed-manifest', | 858 | '--installed-manifest', |
840 | type='string', | 859 | type='string', |
841 | default=join(base_dir, 'installed.xml'), | 860 | default=os.path.join(base_dir, 'installed.xml'), |
842 | dest='installed_filename', | 861 | dest='installed_filename', |
843 | help='The file used to record what is installed.') | 862 | help='The file used to record what is installed.') |
844 | parser.add_option( | 863 | 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 | |||
594 | // global x,y,z. Otherwise, use center of the AABB. | 594 | // global x,y,z. Otherwise, use center of the AABB. |
595 | // reliable | 595 | // reliable |
596 | { | 596 | { |
597 | PlacesReply Low 30 Trusted Zerocoded | 597 | PlacesReply Low 30 Trusted Zerocoded UDPDeprecated |
598 | { | 598 | { |
599 | AgentData Single | 599 | AgentData Single |
600 | { AgentID LLUUID } | 600 | { AgentID LLUUID } |
@@ -619,6 +619,7 @@ version 2.0 | |||
619 | { SnapshotID LLUUID } | 619 | { SnapshotID LLUUID } |
620 | { Dwell F32 } | 620 | { Dwell F32 } |
621 | { Price S32 } | 621 | { Price S32 } |
622 | //{ ProductSKU Variable 1 } | ||
622 | } | 623 | } |
623 | } | 624 | } |
624 | 625 | ||
@@ -723,6 +724,10 @@ version 2.0 | |||
723 | { Auction BOOL } | 724 | { Auction BOOL } |
724 | { Dwell F32 } | 725 | { Dwell F32 } |
725 | } | 726 | } |
727 | { | ||
728 | StatusData Variable | ||
729 | { Status U32 } | ||
730 | } | ||
726 | } | 731 | } |
727 | 732 | ||
728 | // DirPeopleReply | 733 | // DirPeopleReply |
@@ -767,6 +772,10 @@ version 2.0 | |||
767 | { UnixTime U32 } | 772 | { UnixTime U32 } |
768 | { EventFlags U32 } | 773 | { EventFlags U32 } |
769 | } | 774 | } |
775 | { | ||
776 | StatusData Variable | ||
777 | { Status U32 } | ||
778 | } | ||
770 | } | 779 | } |
771 | 780 | ||
772 | // DirGroupsReply | 781 | // DirGroupsReply |
@@ -852,6 +861,10 @@ version 2.0 | |||
852 | { ExpirationDate U32 } | 861 | { ExpirationDate U32 } |
853 | { PriceForListing S32 } | 862 | { PriceForListing S32 } |
854 | } | 863 | } |
864 | { | ||
865 | StatusData Variable | ||
866 | { Status U32 } | ||
867 | } | ||
855 | } | 868 | } |
856 | 869 | ||
857 | 870 | ||
@@ -1036,7 +1049,7 @@ version 2.0 | |||
1036 | // dataserver -> simulator -> viewer | 1049 | // dataserver -> simulator -> viewer |
1037 | // reliable | 1050 | // reliable |
1038 | { | 1051 | { |
1039 | DirLandReply Low 50 Trusted Zerocoded | 1052 | DirLandReply Low 50 Trusted Zerocoded UDPDeprecated |
1040 | { | 1053 | { |
1041 | AgentData Single | 1054 | AgentData Single |
1042 | { AgentID LLUUID } | 1055 | { AgentID LLUUID } |
@@ -1053,6 +1066,7 @@ version 2.0 | |||
1053 | { ForSale BOOL } | 1066 | { ForSale BOOL } |
1054 | { SalePrice S32 } | 1067 | { SalePrice S32 } |
1055 | { ActualArea S32 } | 1068 | { ActualArea S32 } |
1069 | //{ ProductSKU Variable 1 } | ||
1056 | } | 1070 | } |
1057 | } | 1071 | } |
1058 | 1072 | ||
@@ -1465,7 +1479,7 @@ version 2.0 | |||
1465 | } | 1479 | } |
1466 | } | 1480 | } |
1467 | 1481 | ||
1468 | // TeleportFailed somehwere->sim->viewer | 1482 | // TeleportFailed somewhere->sim->viewer |
1469 | // announce failure of teleport request | 1483 | // announce failure of teleport request |
1470 | { | 1484 | { |
1471 | TeleportFailed Low 74 Trusted Unencoded | 1485 | TeleportFailed Low 74 Trusted Unencoded |
@@ -1474,6 +1488,11 @@ version 2.0 | |||
1474 | { AgentID LLUUID } | 1488 | { AgentID LLUUID } |
1475 | { Reason Variable 1 } // string | 1489 | { Reason Variable 1 } // string |
1476 | } | 1490 | } |
1491 | { | ||
1492 | AlertInfo Variable | ||
1493 | { Message Variable 1 } // string id | ||
1494 | { ExtraParams Variable 1 } // llsd extra parameters | ||
1495 | } | ||
1477 | } | 1496 | } |
1478 | 1497 | ||
1479 | 1498 | ||
@@ -2589,6 +2608,10 @@ version 2.0 | |||
2589 | { East F32 } | 2608 | { East F32 } |
2590 | { North F32 } | 2609 | { North F32 } |
2591 | } | 2610 | } |
2611 | { | ||
2612 | ModifyBlockExtended Variable | ||
2613 | { BrushSize F32 } | ||
2614 | } | ||
2592 | } | 2615 | } |
2593 | 2616 | ||
2594 | 2617 | ||
@@ -2806,6 +2829,11 @@ version 2.0 | |||
2806 | AlertData Single | 2829 | AlertData Single |
2807 | { Message Variable 1 } | 2830 | { Message Variable 1 } |
2808 | } | 2831 | } |
2832 | { | ||
2833 | AlertInfo Variable | ||
2834 | { Message Variable 1 } | ||
2835 | { ExtraParams Variable 1 } | ||
2836 | } | ||
2809 | } | 2837 | } |
2810 | 2838 | ||
2811 | // Send an AlertMessage to the named agent. | 2839 | // Send an AlertMessage to the named agent. |
@@ -2942,6 +2970,14 @@ version 2.0 | |||
2942 | { UseEstateSun BOOL } | 2970 | { UseEstateSun BOOL } |
2943 | { SunHour F32 } // last value set by estate or region controls JC | 2971 | { SunHour F32 } // last value set by estate or region controls JC |
2944 | } | 2972 | } |
2973 | { | ||
2974 | RegionInfo2 Single | ||
2975 | { ProductSKU Variable 1 } // string | ||
2976 | { ProductName Variable 1 } // string | ||
2977 | { MaxAgents32 U32 } // Identical to RegionInfo.MaxAgents but allows greater range | ||
2978 | { HardMaxAgents U32 } | ||
2979 | { HardMaxObjects U32 } | ||
2980 | } | ||
2945 | } | 2981 | } |
2946 | 2982 | ||
2947 | // GodUpdateRegionInfo | 2983 | // GodUpdateRegionInfo |
@@ -3059,6 +3095,14 @@ version 2.0 | |||
3059 | RegionInfo2 Single | 3095 | RegionInfo2 Single |
3060 | { RegionID LLUUID } | 3096 | { RegionID LLUUID } |
3061 | } | 3097 | } |
3098 | { | ||
3099 | RegionInfo3 Single | ||
3100 | { CPUClassID S32 } | ||
3101 | { CPURatio S32 } | ||
3102 | { ColoName Variable 1 } // string | ||
3103 | { ProductSKU Variable 1 } // string | ||
3104 | { ProductName Variable 1 } // string | ||
3105 | } | ||
3062 | } | 3106 | } |
3063 | 3107 | ||
3064 | // RegionHandshakeReply | 3108 | // RegionHandshakeReply |
@@ -8701,7 +8745,7 @@ version 2.0 | |||
8701 | 8745 | ||
8702 | // spaceserver -> simulator | 8746 | // spaceserver -> simulator |
8703 | { | 8747 | { |
8704 | RpcScriptRequestInboundForward Low 416 Trusted Unencoded | 8748 | RpcScriptRequestInboundForward Low 416 Trusted Unencoded UDPDeprecated |
8705 | { | 8749 | { |
8706 | DataBlock Single | 8750 | DataBlock Single |
8707 | { RPCServerIP IPADDR } | 8751 | { RPCServerIP IPADDR } |
@@ -8854,3 +8898,39 @@ version 2.0 | |||
8854 | } | 8898 | } |
8855 | } | 8899 | } |
8856 | 8900 | ||
8901 | |||
8902 | // This message is sent from viewer -> simulator when the viewer wants | ||
8903 | // to rez an object out of inventory back to its position before it | ||
8904 | // last moved into the inventory | ||
8905 | { | ||
8906 | RezRestoreToWorld Low 425 NotTrusted Unencoded UDPDeprecated | ||
8907 | { | ||
8908 | AgentData Single | ||
8909 | { AgentID LLUUID } | ||
8910 | { SessionID LLUUID } | ||
8911 | } | ||
8912 | { | ||
8913 | InventoryData Single | ||
8914 | { ItemID LLUUID } | ||
8915 | { FolderID LLUUID } | ||
8916 | { CreatorID LLUUID } // permissions | ||
8917 | { OwnerID LLUUID } // permissions | ||
8918 | { GroupID LLUUID } // permissions | ||
8919 | { BaseMask U32 } // permissions | ||
8920 | { OwnerMask U32 } // permissions | ||
8921 | { GroupMask U32 } // permissions | ||
8922 | { EveryoneMask U32 } // permissions | ||
8923 | { NextOwnerMask U32 } // permissions | ||
8924 | { GroupOwned BOOL } // permissions | ||
8925 | { TransactionID LLUUID } | ||
8926 | { Type S8 } | ||
8927 | { InvType S8 } | ||
8928 | { Flags U32 } | ||
8929 | { SaleType U8 } | ||
8930 | { SalePrice S32 } | ||
8931 | { Name Variable 1 } | ||
8932 | { Description Variable 1 } | ||
8933 | { CreationDate S32 } | ||
8934 | { CRC U32 } | ||
8935 | } | ||
8936 | } | ||
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 | |||
19 | There are special exceptions to the terms and conditions of the GPL as | 19 | There are special exceptions to the terms and conditions of the GPL as |
20 | it is applied to this Source Code. View the full text of the exception | 20 | it is applied to this Source Code. View the full text of the exception |
21 | in the file doc/FLOSS-exception.txt in this software distribution, or | 21 | in the file doc/FLOSS-exception.txt in this software distribution, or |
22 | online at http://secondlifegrid.net/programs/open_source/licensing/flossexception | 22 | online at |
23 | http://secondlifegrid.net/programs/open_source/licensing/flossexception | ||
23 | 24 | ||
24 | By copying, modifying or distributing this software, you acknowledge | 25 | By copying, modifying or distributing this software, you acknowledge |
25 | that you have read and understood your obligations described above, | 26 | 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 | |||
18 | There are special exceptions to the terms and conditions of the GPL as | 18 | There are special exceptions to the terms and conditions of the GPL as |
19 | it is applied to this Source Code. View the full text of the exception | 19 | it is applied to this Source Code. View the full text of the exception |
20 | in the file doc/FLOSS-exception.txt in this software distribution, or | 20 | in the file doc/FLOSS-exception.txt in this software distribution, or |
21 | online at http://secondlifegrid.net/programs/open_source/licensing/flossexception | 21 | online at |
22 | http://secondlifegrid.net/programs/open_source/licensing/flossexception | ||
22 | 23 | ||
23 | By copying, modifying or distributing this software, you acknowledge | 24 | By copying, modifying or distributing this software, you acknowledge |
24 | that you have read and understood your obligations described above, | 25 | that you have read and understood your obligations described above, |
@@ -47,23 +48,26 @@ import os.path | |||
47 | # * it doesn't depend on the current directory | 48 | # * it doesn't depend on the current directory |
48 | # * it doesn't depend on another file being present. | 49 | # * it doesn't depend on another file being present. |
49 | 50 | ||
50 | root = os.path.abspath(__file__) | 51 | def add_indra_lib_path(): |
51 | # always insert the directory of the script in the search path | 52 | root = os.path.realpath(__file__) |
52 | dir = os.path.dirname(root) | 53 | # always insert the directory of the script in the search path |
53 | if dir not in sys.path: | 54 | dir = os.path.dirname(root) |
54 | sys.path.insert(0, dir) | 55 | if dir not in sys.path: |
55 | 56 | sys.path.insert(0, dir) | |
56 | # Now go look for indra/lib/python in the parent dies | 57 | |
57 | while root != os.path.sep: | 58 | # Now go look for indra/lib/python in the parent dies |
58 | root = os.path.dirname(root) | 59 | while root != os.path.sep: |
59 | dir = os.path.join(root, 'indra', 'lib', 'python') | 60 | root = os.path.dirname(root) |
60 | if os.path.isdir(dir): | 61 | dir = os.path.join(root, 'indra', 'lib', 'python') |
61 | if dir not in sys.path: | 62 | if os.path.isdir(dir): |
62 | sys.path.insert(0, dir) | 63 | if dir not in sys.path: |
63 | break | 64 | sys.path.insert(0, dir) |
64 | else: | 65 | break |
65 | print >>sys.stderr, "This script is not inside a valid installation." | 66 | else: |
66 | sys.exit(1) | 67 | print >>sys.stderr, "This script is not inside a valid installation." |
68 | sys.exit(1) | ||
69 | |||
70 | add_indra_lib_path() | ||
67 | 71 | ||
68 | import optparse | 72 | import optparse |
69 | import os | 73 | import os |