aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra
diff options
context:
space:
mode:
Diffstat (limited to 'linden/indra')
-rwxr-xr-xlinden/indra/develop.py6
-rw-r--r--linden/indra/newview/CMakeLists.txt89
-rw-r--r--linden/indra/newview/packaging/mac/ConfigureDMG.scpt110
-rw-r--r--linden/indra/newview/packaging/mac/GenerateInfoPlist.cmake39
-rw-r--r--linden/indra/newview/packaging/mac/Info.plist.in30
-rw-r--r--linden/indra/newview/packaging/mac/background.pngbin0 -> 19029 bytes
-rwxr-xr-xlinden/indra/newview/viewer_manifest.py41
7 files changed, 221 insertions, 94 deletions
diff --git a/linden/indra/develop.py b/linden/indra/develop.py
index e804374..094ce3b 100755
--- a/linden/indra/develop.py
+++ b/linden/indra/develop.py
@@ -121,7 +121,7 @@ class PlatformSetup(object):
121 opts=quote(opts), 121 opts=quote(opts),
122 standalone=self.standalone, 122 standalone=self.standalone,
123 unattended=self.unattended, 123 unattended=self.unattended,
124 type=self.build_type.upper(), 124 type=self.build_type,
125 ) 125 )
126 #if simple: 126 #if simple:
127 # return 'cmake %(opts)s %(dir)r' % args 127 # return 'cmake %(opts)s %(dir)r' % args
@@ -287,7 +287,7 @@ class LinuxSetup(UnixSetup):
287 opts=quote(opts), 287 opts=quote(opts),
288 standalone=self.standalone, 288 standalone=self.standalone,
289 unattended=self.unattended, 289 unattended=self.unattended,
290 type=self.build_type.upper(), 290 type=self.build_type,
291 project_name=self.project_name 291 project_name=self.project_name
292 ) 292 )
293 if not self.is_internal_tree(): 293 if not self.is_internal_tree():
@@ -419,7 +419,7 @@ class DarwinSetup(UnixSetup):
419 unattended=self.unattended, 419 unattended=self.unattended,
420 project_name=self.project_name, 420 project_name=self.project_name,
421 universal=self.universal, 421 universal=self.universal,
422 type=self.build_type.upper() 422 type=self.build_type
423 ) 423 )
424 if self.universal == 'ON': 424 if self.universal == 'ON':
425 args['universal'] = '-DCMAKE_OSX_ARCHITECTURES:STRING=\'i386\'' 425 args['universal'] = '-DCMAKE_OSX_ARCHITECTURES:STRING=\'i386\''
diff --git a/linden/indra/newview/CMakeLists.txt b/linden/indra/newview/CMakeLists.txt
index 313227c..65eacaa 100644
--- a/linden/indra/newview/CMakeLists.txt
+++ b/linden/indra/newview/CMakeLists.txt
@@ -1480,83 +1480,58 @@ endif (LINUX)
1480 1480
1481 1481
1482if (DARWIN) 1482if (DARWIN)
1483 set(product "Imprudence") 1483 set(product "${viewer_NAME}")
1484
1484 set_target_properties( 1485 set_target_properties(
1485 ${VIEWER_BINARY_NAME} 1486 ${VIEWER_BINARY_NAME}
1486 PROPERTIES 1487 PROPERTIES
1487 OUTPUT_NAME "${product}" 1488 OUTPUT_NAME "${product}"
1488 MACOSX_BUNDLE_INFO_STRING "info string - localize me"
1489 MACOSX_BUNDLE_ICON_FILE "viewer.icns"
1490 MACOSX_BUNDLE_GUI_IDENTIFIER "Imprudence"
1491 MACOSX_BUNDLE_LONG_VERSION_STRING "ververver"
1492 MACOSX_BUNDLE_BUNDLE_NAME "Imprudence"
1493 MACOSX_BUNDLE_SHORT_VERSION_STRING "asdf"
1494 MACOSX_BUNDLE_BUNDLE_VERSION "asdf"
1495 MACOSX_BUNDLE_COPYRIGHT "copyright linden lab 2007 - localize me and run me through a legal wringer"
1496 ) 1489 )
1490
1491 # Generate Info.plist from the template.
1492 add_custom_target(
1493 GenerateInfoPlist
1494 ALL
1495 COMMENT "Generating Info.plist..."
1496 VERBATIM
1497 DEPENDS
1498 ${CMAKE_CURRENT_SOURCE_DIR}/packaging/mac/GenerateInfoPlist.cmake
1499 ${CMAKE_CURRENT_SOURCE_DIR}/packaging/mac/Info.plist.in
1500 ${CMAKE_CURRENT_SOURCE_DIR}/viewerinfo.cpp
1501 COMMAND
1502 ${CMAKE_COMMAND}
1503 -DSOURCE_DIR=${CMAKE_SOURCE_DIR}
1504 -DBINARY_DIR=${CMAKE_BINARY_DIR}
1505 -P ${CMAKE_CURRENT_SOURCE_DIR}/packaging/mac/GenerateInfoPlist.cmake
1506 )
1507
1508 # Ensure that it's generated before the binary is built, so
1509 # that it will definitely be ready when viewer_manifest.py runs.
1510 add_dependencies(${VIEWER_BINARY_NAME} GenerateInfoPlist)
1511
1497 1512
1498 add_custom_command( 1513 add_custom_command(
1499 TARGET ${VIEWER_BINARY_NAME} POST_BUILD 1514 TARGET ${VIEWER_BINARY_NAME} POST_BUILD
1500 COMMAND ${PYTHON_EXECUTABLE} 1515 COMMAND ${PYTHON_EXECUTABLE}
1501 ARGS 1516 ARGS
1502 ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py 1517 ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
1503 --grid=${GRID}
1504 --actions=copy 1518 --actions=copy
1505 --configuration=${CMAKE_CFG_INTDIR}
1506 --source=${CMAKE_CURRENT_SOURCE_DIR}
1507 --artwork=${ARTWORK_DIR} 1519 --artwork=${ARTWORK_DIR}
1508 --build=${CMAKE_CURRENT_BINARY_DIR} 1520 --build=${CMAKE_CURRENT_BINARY_DIR}
1521 --buildtype=${CMAKE_BUILD_TYPE}
1522 --configuration=${CMAKE_CFG_INTDIR}
1509 --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app 1523 --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app
1524 --grid=${GRID}
1525 --source=${CMAKE_CURRENT_SOURCE_DIR}
1526 --standalone=${STANDALONE}
1510 DEPENDS ${VIEWER_BINARY_NAME} ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py 1527 DEPENDS ${VIEWER_BINARY_NAME} ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
1511 ) 1528 )
1512
1513 add_dependencies(${VIEWER_BINARY_NAME} SLPlugin media_plugin_quicktime media_plugin_webkit media_plugin_gstreamer010)
1514
1515 if (PACKAGE)
1516 add_custom_target(package ALL DEPENDS ${VIEWER_BINARY_NAME})
1517 add_dependencies(package mac-updater mac-crash-logger)
1518
1519 add_custom_command(
1520 TARGET package POST_BUILD
1521 COMMAND ${PYTHON_EXECUTABLE}
1522 ARGS
1523 ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
1524 --standalone=${STANDALONE}
1525 --buildtype=${CMAKE_BUILD_TYPE}
1526 --grid=${GRID}
1527 --configuration=${CMAKE_CFG_INTDIR}
1528 --channel=${VIEWER_CHANNEL}
1529 --login_channel=${VIEWER_LOGIN_CHANNEL}
1530 --source=${CMAKE_CURRENT_SOURCE_DIR}
1531 --artwork=${ARTWORK_DIR}
1532 --build=${CMAKE_CURRENT_BINARY_DIR}
1533 --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app
1534 --touch=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/.${product}.touched
1535 1529
1536 DEPENDS 1530 add_dependencies(${VIEWER_BINARY_NAME} SLPlugin media_plugin_quicktime media_plugin_webkit media_plugin_gstreamer010 mac-updater mac-crash-logger)
1537 ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
1538 )
1539 1531
1540 add_dependencies(${VIEWER_BINARY_NAME} SLPlugin media_plugin_quicktime media_plugin_webkit media_plugin_gstreamer010) 1532 add_package_target()
1541 add_custom_command( 1533 add_dependencies(package ${VIEWER_BINARY_NAME})
1542 TARGET package POST_BUILD
1543 COMMAND ${PYTHON_EXECUTABLE}
1544 ARGS
1545 ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
1546 --grid=${GRID}
1547 --configuration=${CMAKE_CFG_INTDIR}
1548 --channel=${VIEWER_CHANNEL}
1549 --login_channel=${VIEWER_LOGIN_CHANNEL}
1550 --source=${CMAKE_CURRENT_SOURCE_DIR}
1551 --artwork=${ARTWORK_DIR}
1552 --build=${CMAKE_CURRENT_BINARY_DIR}
1553 --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app
1554 --touch=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/.${product}.touched
1555 DEPENDS
1556 ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
1557 )
1558 1534
1559 endif (PACKAGE)
1560endif (DARWIN) 1535endif (DARWIN)
1561 1536
1562if (INSTALL) 1537if (INSTALL)
diff --git a/linden/indra/newview/packaging/mac/ConfigureDMG.scpt b/linden/indra/newview/packaging/mac/ConfigureDMG.scpt
new file mode 100644
index 0000000..198ab9e
--- /dev/null
+++ b/linden/indra/newview/packaging/mac/ConfigureDMG.scpt
@@ -0,0 +1,110 @@
1(*
2
3@file ConfigureDMG.scpt
4@author Jacek Antonelli
5@brief Script for configuring the Mac installer disk image.
6
7Copyright (c) 2011, Jacek Antonelli
8
9Permission is hereby granted, free of charge, to any person
10obtaining a copy of this software and associated documentation files
11(the "Software"), to deal in the Software without restriction,
12including without limitation the rights to use, copy, modify, merge,
13publish, distribute, sublicense, and/or sell copies of the Software,
14and to permit persons to whom the Software is furnished to do so,
15subject to the following conditions:
16
17The above copyright notice and this permission notice shall be
18included in all copies or substantial portions of the Software.
19
20THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
21EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
22MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
23NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
24BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
25ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
26CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
27SOFTWARE.
28
29-----
30
31This AppleScript script configures the view options and icon layout of
32the Mac installer disk image (DMG) as part of the packaging process.
33See also scripts/package.py, which executes this script.
34
35This script takes two required positional command line arguments:
36
37 1: the name of the mounted volume (e.g. for "/Volumes/Imprudence Installer",
38 the volume name is "Imprudence Installer").
39 2: the name of the application file (e.g. "Imprudence.app").
40
41Example usage:
42
43 osascript ConfigureDMG.scpt "Imprudence Installer" "Imprudence.app"
44
45Some preparation is necessary before running this script:
46
47 * The target disk image must be currently attached as a volume, with
48 the volume name specified by the first command line argument.
49 * The volume must contain the application file, with the file
50 name specified by the second command line argument.
51 * The volume must contain the "background.png" image file.
52 * The volume must not contain a file or folder named "Applications".
53 * It might be necessary to "Enable access for assistive devices"
54 in System Preferences > Universal Access.
55
56*)
57
58on run argv
59
60 -- Read the first positional argument, the volume name.
61 set volumeName to item 1 of argv
62
63 -- Read the second positional argument, the app name.
64 set appName to item 2 of argv
65
66 tell application "Finder" to tell disk volumeName
67 -- Open the volume in a Finder window.
68 open
69 set theWindow to the container window
70
71 -- Tweak some options.
72 set current view of theWindow to icon view
73 set toolbar visible of theWindow to false
74 set statusbar visible of theWindow to false
75
76 -- Set window to position {150,150}, size {+600,+420}.
77 set bounds of theWindow to {150, 150, 750, 570}
78
79 -- Tweak some more options.
80 set viewOptions to the icon view options of theWindow
81 set arrangement of viewOptions to not arranged
82 set icon size of viewOptions to 128
83
84 -- Make sure background.png is visible, so Finder can see it.
85 set bgPicPath to the quoted form of (the POSIX path of (it as alias) & "background.png")
86 do shell script ("SetFile -a v " & bgPicPath)
87 update without registering applications
88
89 -- Use background.png as the background picture.
90 set background picture of viewOptions to file "background.png"
91
92 -- Now set background.png to invisible, so the end user won't see it.
93 do shell script ("SetFile -a V " & bgPicPath)
94
95 -- Position the application file.
96 set position of item appName of theWindow to {138, 260}
97
98 -- Create and position an alias to the Applications folder.
99 set appAlias to make new alias file at theWindow to POSIX file "/Applications"
100 set name of appAlias to "Applications"
101 set position of appAlias to {470, 260}
102
103 -- Visually update the window so all the changes take effect.
104 update without registering applications
105
106 -- Pause briefly so we can admire the results.
107 delay 2
108 end tell
109
110end run
diff --git a/linden/indra/newview/packaging/mac/GenerateInfoPlist.cmake b/linden/indra/newview/packaging/mac/GenerateInfoPlist.cmake
new file mode 100644
index 0000000..ecbec34
--- /dev/null
+++ b/linden/indra/newview/packaging/mac/GenerateInfoPlist.cmake
@@ -0,0 +1,39 @@
1#
2# Generate the Info.plist file from the template.
3# Only @-style "@VARIABLES@" are substituted in the template (not "${VARIABLES}").
4#
5# This script is needed because CMake has no other way to perform
6# configure_file() as a build-time custom command. :(
7#
8# When running this script, you must define (-D) SOURCE_DIR and
9# BINARY_DIR to refer to indra and the build directory respectively.
10# (Equivalent to CMAKE_SOURCE_DIR and CMAKE_BINARY_DIR in
11# CMakeLists.txt )
12#
13
14if (NOT SOURCE_DIR)
15 message( FATAL_ERROR "You forgot to define SOURCE_DIR!" )
16endif (NOT SOURCE_DIR)
17
18if (NOT BINARY_DIR)
19 message( FATAL_ERROR "You forgot to define BINARY_DIR!" )
20endif (NOT BINARY_DIR)
21
22set(SCRIPTS_DIR "${SOURCE_DIR}/../scripts")
23set(CMAKE_MODULE_PATH "${SOURCE_DIR}/cmake/" "${CMAKE_ROOT/Modules}")
24
25include(BuildVersion)
26build_version(viewer)
27
28SET( BUNDLE_NAME "${viewer_NAME}" )
29SET( EXECUTABLE "${viewer_NAME}" )
30set( BUNDLE_VERSION "${viewer_VERSION}" )
31set( SHORT_VERSION_STRING "${viewer_NAME} ${viewer_VERSION}" )
32set( ICON_FILE "viewer.icns" )
33set( IDENTIFIER "${viewer_BUNDLE_ID}" )
34set( SIGNATURE "impr" )
35
36configure_file(
37 ${SOURCE_DIR}/newview/packaging/mac/Info.plist.in
38 ${BINARY_DIR}/newview/packaging/mac/Info.plist
39 @ONLY)
diff --git a/linden/indra/newview/packaging/mac/Info.plist.in b/linden/indra/newview/packaging/mac/Info.plist.in
index b3045c9..78cc6b7 100644
--- a/linden/indra/newview/packaging/mac/Info.plist.in
+++ b/linden/indra/newview/packaging/mac/Info.plist.in
@@ -2,22 +2,20 @@
2<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> 2<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3<plist version="1.0"> 3<plist version="1.0">
4<dict> 4<dict>
5 <key>CFBundleDevelopmentRegion</key> 5 <key>CFBundleName</key>
6 <string>English</string> 6 <string>@BUNDLE_NAME@</string>
7 <key>CFBundleExecutable</key> 7 <key>CFBundleExecutable</key>
8 <string>Imprudence</string> 8 <string>@EXECUTABLE@</string>
9 <key>CFBundleVersion</key>
10 <string>@BUNDLE_VERSION@</string>
11 <key>CFBundleShortVersionString</key>
12 <string>@SHORT_VERSION_STRING@</string>
9 <key>CFBundleIconFile</key> 13 <key>CFBundleIconFile</key>
10 <string>viewer.icns</string> 14 <string>@ICON_FILE@</string>
11 <key>CFBundleIdentifier</key> 15 <key>CFBundleIdentifier</key>
12 <string>org.imprudenceviewer.viewer</string> 16 <string>@IDENTIFIER@</string>
13 <key>CFBundleInfoDictionaryVersion</key>
14 <string>6.0</string>
15 <key>CFBundleName</key>
16 <string>Imprudence</string>
17 <key>CFBundlePackageType</key>
18 <string>APPL</string>
19 <key>CFBundleSignature</key> 17 <key>CFBundleSignature</key>
20 <string>????</string> 18 <string>@SIGNATURE@</string>
21 <key>CFBundleURLTypes</key> 19 <key>CFBundleURLTypes</key>
22 <array> 20 <array>
23 <dict> 21 <dict>
@@ -31,8 +29,12 @@
31 <true/> 29 <true/>
32 </dict> 30 </dict>
33 </array> 31 </array>
34 <key>CFBundleVersion</key> 32 <key>CFBundleDevelopmentRegion</key>
35 <string>1.4.0 beta 1</string> 33 <string>English</string>
34 <key>CFBundleInfoDictionaryVersion</key>
35 <string>6.0</string>
36 <key>CFBundlePackageType</key>
37 <string>APPL</string>
36 <key>CSResourcesFileMapped</key> 38 <key>CSResourcesFileMapped</key>
37 <true/> 39 <true/>
38</dict> 40</dict>
diff --git a/linden/indra/newview/packaging/mac/background.png b/linden/indra/newview/packaging/mac/background.png
new file mode 100644
index 0000000..9b0b0b2
--- /dev/null
+++ b/linden/indra/newview/packaging/mac/background.png
Binary files differ
diff --git a/linden/indra/newview/viewer_manifest.py b/linden/indra/newview/viewer_manifest.py
index 0f129dd..5e1e816 100755
--- a/linden/indra/newview/viewer_manifest.py
+++ b/linden/indra/newview/viewer_manifest.py
@@ -585,7 +585,8 @@ class DarwinManifest(ViewerManifest):
585 585
586 if self.prefix(src="", dst="Contents"): # everything goes in Contents 586 if self.prefix(src="", dst="Contents"): # everything goes in Contents
587 587
588 self.path("Info-Imprudence.plist", dst="Info.plist") 588 # Info.plist goes directly in Contents
589 self.path("packaging/mac/Info.plist", dst="Info.plist")
589 590
590 # copy additional libs in <bundle>/Contents/MacOS/ 591 # copy additional libs in <bundle>/Contents/MacOS/
591 if (not self.standalone()) and self.prefix(src="../../libraries/universal-darwin/lib_release", dst="MacOS/"): 592 if (not self.standalone()) and self.prefix(src="../../libraries/universal-darwin/lib_release", dst="MacOS/"):
@@ -653,27 +654,27 @@ class DarwinManifest(ViewerManifest):
653 self.gather_documents() 654 self.gather_documents()
654 655
655 self.path("featuretable_mac.txt") 656 self.path("featuretable_mac.txt")
656 self.path("SecondLife.nib")
657
658 self.path("viewer.icns") 657 self.path("viewer.icns")
659 658
660 # Translations 659 if self.prefix(src="packaging/mac", dst=""):
661 self.path("English.lproj") 660 self.path("SecondLife.nib")
662 self.path("German.lproj") 661 self.path("English.lproj")
663 self.path("Japanese.lproj") 662 self.path("German.lproj")
664 self.path("Korean.lproj") 663 self.path("Japanese.lproj")
665 self.path("da.lproj") 664 self.path("Korean.lproj")
666 self.path("es.lproj") 665 self.path("da.lproj")
667 self.path("fr.lproj") 666 self.path("es.lproj")
668 self.path("hu.lproj") 667 self.path("fr.lproj")
669 self.path("it.lproj") 668 self.path("hu.lproj")
670 self.path("nl.lproj") 669 self.path("it.lproj")
671 self.path("pl.lproj") 670 self.path("nl.lproj")
672 self.path("pt.lproj") 671 self.path("pl.lproj")
673 self.path("ru.lproj") 672 self.path("pt.lproj")
674 self.path("tr.lproj") 673 self.path("ru.lproj")
675 self.path("uk.lproj") 674 self.path("tr.lproj")
676 self.path("zh-Hans.lproj") 675 self.path("uk.lproj")
676 self.path("zh-Hans.lproj")
677 self.end_prefix("packaging/mac")
677 678
678 679
679 # if (not self.standalone()) and self.prefix(src="../../libraries/universal-darwin/lib_release/gstreamer-plugins", dst="lib/gstreamer-plugins"): 680 # if (not self.standalone()) and self.prefix(src="../../libraries/universal-darwin/lib_release/gstreamer-plugins", dst="lib/gstreamer-plugins"):