summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/CMakeLists.txt1429
-rw-r--r--indra/newview/ViewerInstall.cmake28
-rw-r--r--indra/newview/installers/windows/installer_template.nsi12
-rw-r--r--indra/newview/llappviewer.cpp8
-rw-r--r--indra/newview/llappviewerlinux.cpp30
-rw-r--r--indra/newview/llappviewermacosx.cpp7
-rw-r--r--indra/newview/lleventinfo.cpp6
-rw-r--r--indra/newview/lleventinfo.h4
-rw-r--r--indra/newview/lleventnotifier.cpp2
-rw-r--r--indra/newview/lleventnotifier.h4
-rw-r--r--indra/newview/llfeaturemanager.cpp4
-rw-r--r--indra/newview/llfloatercamera.cpp2
-rw-r--r--indra/newview/llfloaterchat.cpp2
-rw-r--r--indra/newview/llfloaterpreference.cpp14
-rw-r--r--indra/newview/llfloaterproperties.cpp2
-rw-r--r--indra/newview/llfolderview.cpp43
-rw-r--r--indra/newview/llfolderview.h18
-rw-r--r--indra/newview/llinventorybridge.cpp4
-rw-r--r--indra/newview/llinventorybridge.h4
-rw-r--r--indra/newview/lllogchat.cpp2
-rw-r--r--indra/newview/llmutelist.cpp2
-rw-r--r--indra/newview/llpanelgrouplandmoney.cpp2
-rw-r--r--indra/newview/llstartup.cpp6
-rw-r--r--indra/newview/llstatusbar.cpp2
-rw-r--r--indra/newview/lltexturecache.cpp8
-rw-r--r--indra/newview/lltooldraganddrop.cpp2
-rw-r--r--indra/newview/llurldispatcher.cpp2
-rw-r--r--indra/newview/llviewerinventory.cpp4
-rw-r--r--indra/newview/llviewerinventory.h2
-rw-r--r--indra/newview/llviewerjoystick.h2
-rw-r--r--indra/newview/llviewermenu.cpp2
-rw-r--r--indra/newview/llviewermessage.cpp4
-rw-r--r--indra/newview/llviewerregion.cpp44
-rw-r--r--indra/newview/llviewerregion.h1
-rw-r--r--indra/newview/llviewerstats.cpp6
-rw-r--r--indra/newview/llviewertexteditor.cpp2
-rw-r--r--indra/newview/llviewerwindow.cpp2
-rw-r--r--indra/newview/llviewerwindow.h2
-rw-r--r--indra/newview/llvoavatar.cpp2
-rw-r--r--indra/newview/llvoiceclient.cpp22
-rw-r--r--indra/newview/llwindebug.cpp4
-rw-r--r--indra/newview/res/resource.h2
-rw-r--r--indra/newview/res/viewerRes.rc288
-rwxr-xr-xindra/newview/viewer_manifest.py1024
44 files changed, 2449 insertions, 613 deletions
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt
new file mode 100644
index 0000000000..1ce41c044b
--- /dev/null
+++ b/indra/newview/CMakeLists.txt
@@ -0,0 +1,1429 @@
+# -*- cmake -*-
+
+project(viewer)
+
+include(00-Common)
+include(Boost)
+include(BuildVersion)
+include(DirectX)
+include(ELFIO)
+include(FMOD)
+include(FindOpenGL)
+include(LLAudio)
+include(LLCharacter)
+include(LLCommon)
+include(LLImage)
+include(LLImageJ2COJ)
+include(LLInventory)
+include(LLMath)
+include(LLMedia)
+include(LLMessage)
+include(LLPrimitive)
+include(LLRender)
+include(LLUI)
+include(LLVFS)
+include(LLWindow)
+include(LLXML)
+include(LScript)
+include(Linking)
+include(Mozlib)
+include(NDOF)
+include(Smartheap)
+include(TemplateCheck)
+include(UI)
+include(UnixInstall)
+include(LLKDU)
+
+include_directories(
+ ${ELFIO_INCLUDE_DIR}
+ ${LLAUDIO_INCLUDE_DIRS}
+ ${LLCHARACTER_INCLUDE_DIRS}
+ ${LLCOMMON_INCLUDE_DIRS}
+ ${LLIMAGE_INCLUDE_DIRS}
+ ${LLINVENTORY_INCLUDE_DIRS}
+ ${LLMATH_INCLUDE_DIRS}
+ ${LLMEDIA_INCLUDE_DIRS}
+ ${LLMESSAGE_INCLUDE_DIRS}
+ ${LLPRIMITIVE_INCLUDE_DIRS}
+ ${LLRENDER_INCLUDE_DIRS}
+ ${LLUI_INCLUDE_DIRS}
+ ${LLVFS_INCLUDE_DIRS}
+ ${LLWINDOW_INCLUDE_DIRS}
+ ${LLXML_INCLUDE_DIRS}
+ ${LSCRIPT_INCLUDE_DIRS}
+ ${LSCRIPT_INCLUDE_DIRS}/lscript_compile
+ )
+
+set(viewer_SOURCE_FILES
+ llagent.cpp
+ llagentdata.cpp
+ llagentlanguage.cpp
+ llagentpilot.cpp
+ llanimstatelabels.cpp
+ llappviewer.cpp
+ llassetuploadresponders.cpp
+ llaudiosourcevo.cpp
+ llbbox.cpp
+ llbox.cpp
+ llcallbacklist.cpp
+ llcallingcard.cpp
+ llcaphttpsender.cpp
+ llchatbar.cpp
+ llclassifiedinfo.cpp
+ llclassifiedstatsresponder.cpp
+ llcloud.cpp
+ llcolorscheme.cpp
+ llcolorswatch.cpp
+ llcommandhandler.cpp
+ llcommandlineparser.cpp
+ llcompass.cpp
+ llcompilequeue.cpp
+ llconfirmationmanager.cpp
+ llconsole.cpp
+ llcontainerview.cpp
+ llcubemap.cpp
+ llcurrencyuimanager.cpp
+ llcylinder.cpp
+ lldebugmessagebox.cpp
+ lldebugview.cpp
+ lldelayedgestureerror.cpp
+ lldirpicker.cpp
+ lldrawable.cpp
+ lldrawpoolalpha.cpp
+ lldrawpoolavatar.cpp
+ lldrawpoolbump.cpp
+ lldrawpool.cpp
+ lldrawpoolground.cpp
+ lldrawpoolsimple.cpp
+ lldrawpoolsky.cpp
+ lldrawpoolterrain.cpp
+ lldrawpooltree.cpp
+ lldrawpoolwater.cpp
+ lldrawpoolwlsky.cpp
+ lldriverparam.cpp
+ lldynamictexture.cpp
+ llemote.cpp
+ lleventinfo.cpp
+ lleventnotifier.cpp
+ lleventpoll.cpp
+ llface.cpp
+ llfasttimerview.cpp
+ llfeaturemanager.cpp
+ llfilepicker.cpp
+ llfirstuse.cpp
+ llflexibleobject.cpp
+ llfloaterabout.cpp
+ llfloateractivespeakers.cpp
+ llfloateranimpreview.cpp
+ llfloaterauction.cpp
+ llfloateravatarinfo.cpp
+ llfloateravatarpicker.cpp
+ llfloateravatartextures.cpp
+ llfloaterbuildoptions.cpp
+ llfloaterbump.cpp
+ llfloaterbuycontents.cpp
+ llfloaterbuy.cpp
+ llfloaterbuycurrency.cpp
+ llfloaterbuyland.cpp
+ llfloatercamera.cpp
+ llfloaterchat.cpp
+ llfloaterchatterbox.cpp
+ llfloaterclassified.cpp
+ llfloaterclothing.cpp
+ llfloatercolorpicker.cpp
+ llfloatercustomize.cpp
+ llfloaterdaycycle.cpp
+ llfloaterdirectory.cpp
+ llfloatereditui.cpp
+ llfloaterenvsettings.cpp
+ llfloaterevent.cpp
+ llfloaterfriends.cpp
+ llfloatergesture.cpp
+ llfloatergodtools.cpp
+ llfloatergroupinfo.cpp
+ llfloatergroupinvite.cpp
+ llfloatergroups.cpp
+ llfloaterhardwaresettings.cpp
+ llfloaterhtml.cpp
+ llfloaterhtmlhelp.cpp
+ llfloaterhud.cpp
+ llfloaterimagepreview.cpp
+ llfloaterinspect.cpp
+ llfloaterjoystick.cpp
+ llfloaterlagmeter.cpp
+ llfloaterland.cpp
+ llfloaterlandholdings.cpp
+ llfloaterlandmark.cpp
+ llfloatermap.cpp
+ llfloatermute.cpp
+ llfloaternamedesc.cpp
+ llfloaternewim.cpp
+ llfloateropenobject.cpp
+ llfloaterparcel.cpp
+ llfloaterpermissionsmgr.cpp
+ llfloaterpostcard.cpp
+ llfloaterpostprocess.cpp
+ llfloaterpreference.cpp
+ llfloaterproperties.cpp
+ llfloaterregioninfo.cpp
+ llfloaterreleasemsg.cpp
+ llfloaterreporter.cpp
+ llfloaterscriptdebug.cpp
+ llfloatersellland.cpp
+ llfloatersettingsdebug.cpp
+ llfloatersnapshot.cpp
+ llfloaterstats.cpp
+ llfloatertelehub.cpp
+ llfloatertest.cpp
+ llfloatertools.cpp
+ llfloatertopobjects.cpp
+ llfloatertos.cpp
+ llfloaterurldisplay.cpp
+ llfloaterurlentry.cpp
+ llfloatervoicedevicesettings.cpp
+ llfloaterwater.cpp
+ llfloaterwindlight.cpp
+ llfloaterworldmap.cpp
+ llfolderview.cpp
+ llfollowcam.cpp
+ llframestats.cpp
+ llframestatview.cpp
+ llgenepool.cpp
+ llgesturemgr.cpp
+ llgivemoney.cpp
+ llglsandbox.cpp
+ llglslshader.cpp
+ llgroupmgr.cpp
+ llgroupnotify.cpp
+ llhippo.cpp
+ llhoverview.cpp
+ llhudeffectbeam.cpp
+ llhudeffect.cpp
+ llhudeffectlookat.cpp
+ llhudeffectpointat.cpp
+ llhudeffecttrail.cpp
+ llhudicon.cpp
+ llhudmanager.cpp
+ llhudobject.cpp
+ llhudrender.cpp
+ llhudtext.cpp
+ llhudview.cpp
+ llimpanel.cpp
+ llimview.cpp
+ llinventoryactions.cpp
+ llinventorybridge.cpp
+ llinventoryclipboard.cpp
+ llinventorymodel.cpp
+ llinventoryview.cpp
+ lljoystickbutton.cpp
+ lllandmarklist.cpp
+ lllogchat.cpp
+ llmanip.cpp
+ llmaniprotate.cpp
+ llmanipscale.cpp
+ llmaniptranslate.cpp
+ llmapresponders.cpp
+ llmediaremotectrl.cpp
+ llmemoryview.cpp
+ llmenucommands.cpp
+ llmimetypes.cpp
+ llmorphview.cpp
+ llmoveview.cpp
+ llmutelist.cpp
+ llnamebox.cpp
+ llnameeditor.cpp
+ llnamelistctrl.cpp
+ llnetmap.cpp
+ llnotify.cpp
+ lloverlaybar.cpp
+ llpanelaudioprefs.cpp
+ llpanelaudiovolume.cpp
+ llpanelavatar.cpp
+ llpanelclassified.cpp
+ llpanelcontents.cpp
+ llpaneldebug.cpp
+ llpaneldirbrowser.cpp
+ llpaneldirclassified.cpp
+ llpaneldirevents.cpp
+ llpaneldirfind.cpp
+ llpaneldirgroups.cpp
+ llpaneldirland.cpp
+ llpaneldirpeople.cpp
+ llpaneldirplaces.cpp
+ llpaneldirpopular.cpp
+ llpaneldisplay.cpp
+ llpanelevent.cpp
+ llpanelface.cpp
+ llpanelgeneral.cpp
+ llpanelgroup.cpp
+ llpanelgroupgeneral.cpp
+ llpanelgroupinvite.cpp
+ llpanelgrouplandmoney.cpp
+ llpanelgroupnotices.cpp
+ llpanelgrouproles.cpp
+ llpanelgroupvoting.cpp
+ llpanelinput.cpp
+ llpanelinventory.cpp
+ llpanelland.cpp
+ llpanellandmedia.cpp
+ llpanellandobjects.cpp
+ llpanellandoptions.cpp
+ llpanellogin.cpp
+ llpanelmorph.cpp
+ llpanelmsgs.cpp
+ llpanelnetwork.cpp
+ llpanelobject.cpp
+ llpanelpermissions.cpp
+ llpanelpick.cpp
+ llpanelplace.cpp
+ llpanelvolume.cpp
+ llpanelweb.cpp
+ llparcelselection.cpp
+ llpatchvertexarray.cpp
+ llpolymesh.cpp
+ llpolymorph.cpp
+ llpostprocess.cpp
+ llprefschat.cpp
+ llprefsim.cpp
+ llprefsvoice.cpp
+ llpreviewanim.cpp
+ llpreview.cpp
+ llpreviewgesture.cpp
+ llpreviewlandmark.cpp
+ llpreviewnotecard.cpp
+ llpreviewscript.cpp
+ llpreviewsound.cpp
+ llpreviewtexture.cpp
+ llprogressview.cpp
+ llregionposition.cpp
+ llrendersphere.cpp
+ llremoteparcelrequest.cpp
+ llsavedsettingsglue.cpp
+ llselectmgr.cpp
+ llsky.cpp
+ llspatialpartition.cpp
+ llsprite.cpp
+ llsrv.cpp
+ llstartup.cpp
+ llstatbar.cpp
+ llstatgraph.cpp
+ llstatusbar.cpp
+ llstatview.cpp
+ llstylemap.cpp
+ llsurface.cpp
+ llsurfacepatch.cpp
+ lltexlayer.cpp
+ lltexturecache.cpp
+ lltexturectrl.cpp
+ lltexturefetch.cpp
+ lltextureview.cpp
+ lltoolbar.cpp
+ lltoolbrush.cpp
+ lltoolcomp.cpp
+ lltool.cpp
+ lltooldraganddrop.cpp
+ lltoolface.cpp
+ lltoolfocus.cpp
+ lltoolgrab.cpp
+ lltoolgun.cpp
+ lltoolindividual.cpp
+ lltoolmgr.cpp
+ lltoolmorph.cpp
+ lltoolobjpicker.cpp
+ lltoolpie.cpp
+ lltoolpipette.cpp
+ lltoolplacer.cpp
+ lltoolselect.cpp
+ lltoolselectland.cpp
+ lltoolselectrect.cpp
+ lltoolview.cpp
+ lltracker.cpp
+ lltrans.cpp
+ lluploaddialog.cpp
+ llurl.cpp
+ llurldispatcher.cpp
+ llurlhistory.cpp
+ llurlsimstring.cpp
+ llurlwhitelist.cpp
+ lluserauth.cpp
+ llvectorperfoptions.cpp
+ llvelocitybar.cpp
+ llviewchildren.cpp
+ llviewerassetstorage.cpp
+ llvieweraudio.cpp
+ llviewercamera.cpp
+ llviewercontrol.cpp
+ llviewerdisplay.cpp
+ llviewergenericmessage.cpp
+ llviewergesture.cpp
+ llviewerimage.cpp
+ llviewerimagelist.cpp
+ llviewerinventory.cpp
+ llviewerjointattachment.cpp
+ llviewerjoint.cpp
+ llviewerjointmesh.cpp
+ llviewerjointmesh_sse2.cpp
+ llviewerjointmesh_sse.cpp
+ llviewerjointmesh_vec.cpp
+ llviewerjoystick.cpp
+ llviewerkeyboard.cpp
+ llviewerlayer.cpp
+ llviewermedia.cpp
+ llviewermenu.cpp
+ llviewermenufile.cpp
+ llviewermessage.cpp
+ llviewernetwork.cpp
+ llviewerobject.cpp
+ llviewerobjectlist.cpp
+ llviewerparcelmedia.cpp
+ llviewerparcelmediaautoplay.cpp
+ llviewerparcelmgr.cpp
+ llviewerparceloverlay.cpp
+ llviewerpartsim.cpp
+ llviewerpartsource.cpp
+ llviewerprecompiledheaders.cpp
+ llviewerregion.cpp
+ llviewerstats.cpp
+ llviewertexteditor.cpp
+ llviewertextureanim.cpp
+ llviewerthrottle.cpp
+ llviewervisualparam.cpp
+ llviewerwindow.cpp
+ llvlcomposition.cpp
+ llvlmanager.cpp
+ llvoavatar.cpp
+ llvocache.cpp
+ llvoclouds.cpp
+ llvograss.cpp
+ llvoground.cpp
+ llvoiceclient.cpp
+ llvoiceremotectrl.cpp
+ llvoicevisualizer.cpp
+ llvoinventorylistener.cpp
+ llvopartgroup.cpp
+ llvosky.cpp
+ llvosurfacepatch.cpp
+ llvotextbubble.cpp
+ llvotree.cpp
+ llvovolume.cpp
+ llvowater.cpp
+ llvowlsky.cpp
+ llwatchdog.cpp
+ llwaterparammanager.cpp
+ llwaterparamset.cpp
+ llwearable.cpp
+ llwearablelist.cpp
+ llweb.cpp
+ llwebbrowserctrl.cpp
+ llwind.cpp
+ llwlanimator.cpp
+ llwldaycycle.cpp
+ llwlparammanager.cpp
+ llwlparamset.cpp
+ llworld.cpp
+ llworldmap.cpp
+ llworldmapview.cpp
+ llxmlrpctransaction.cpp
+ noise.cpp
+ pipeline.cpp
+ )
+
+if (LINUX)
+ # We can't set these flags for Darwin, because they get passed to
+ # the PPC compiler. Ugh.
+
+ set_source_files_properties(
+ llviewerjointmesh_sse.cpp
+ PROPERTIES COMPILE_FLAGS "-msse -mfpmath=sse"
+ )
+ set_source_files_properties(
+ llviewerjointmesh_sse2.cpp
+ PROPERTIES COMPILE_FLAGS "-msse2 -mfpmath=sse"
+ )
+endif (LINUX)
+
+set(viewer_HEADER_FILES
+ CMakeLists.txt
+ ViewerInstall.cmake
+
+ llagent.h
+ llagentdata.h
+ llagentlanguage.h
+ llagentpilot.h
+ llanimstatelabels.h
+ llappearance.h
+ llappviewer.h
+ llassetuploadresponders.h
+ llaudiosourcevo.h
+ llbbox.h
+ llbox.h
+ llcallbacklist.h
+ llcallingcard.h
+ llcaphttpsender.h
+ llchatbar.h
+ llclassifiedinfo.h
+ llclassifiedstatsresponder.h
+ llcloud.h
+ llcolorscheme.h
+ llcolorswatch.h
+ llcommandhandler.h
+ llcommandlineparser.h
+ llcompass.h
+ llcompilequeue.h
+ llconfirmationmanager.h
+ llconsole.h
+ llcontainerview.h
+ llcubemap.h
+ llcurrencyuimanager.h
+ llcylinder.h
+ lldebugmessagebox.h
+ lldebugview.h
+ lldelayedgestureerror.h
+ lldirpicker.h
+ lldrawable.h
+ lldrawpool.h
+ lldrawpoolalpha.h
+ lldrawpoolavatar.h
+ lldrawpoolbump.h
+ lldrawpoolclouds.h
+ lldrawpoolground.h
+ lldrawpoolsimple.h
+ lldrawpoolsky.h
+ lldrawpoolterrain.h
+ lldrawpooltree.h
+ lldrawpoolwater.h
+ lldrawpoolwlsky.h
+ lldriverparam.h
+ lldynamictexture.h
+ llemote.h
+ lleventinfo.h
+ lleventnotifier.h
+ lleventpoll.h
+ llface.h
+ llfasttimerview.h
+ llfeaturemanager.h
+ llfilepicker.h
+ llfirstuse.h
+ llflexibleobject.h
+ llfloaterabout.h
+ llfloateractivespeakers.h
+ llfloateranimpreview.h
+ llfloaterauction.h
+ llfloateravatarinfo.h
+ llfloateravatarpicker.h
+ llfloateravatartextures.h
+ llfloaterbuildoptions.h
+ llfloaterbump.h
+ llfloaterbuy.h
+ llfloaterbuycontents.h
+ llfloaterbuycurrency.h
+ llfloaterbuyland.h
+ llfloatercamera.h
+ llfloaterchat.h
+ llfloaterchatterbox.h
+ llfloaterclassified.h
+ llfloaterclothing.h
+ llfloatercolorpicker.h
+ llfloatercustomize.h
+ llfloaterdaycycle.h
+ llfloaterdirectory.h
+ llfloatereditui.h
+ llfloaterenvsettings.h
+ llfloaterevent.h
+ llfloaterfriends.h
+ llfloatergesture.h
+ llfloatergodtools.h
+ llfloatergroupinfo.h
+ llfloatergroupinvite.h
+ llfloatergroups.h
+ llfloaterhardwaresettings.h
+ llfloaterhtml.h
+ llfloaterhtmlhelp.h
+ llfloaterhud.h
+ llfloaterimagepreview.h
+ llfloaterinspect.h
+ llfloaterjoystick.h
+ llfloaterlagmeter.h
+ llfloaterland.h
+ llfloaterlandholdings.h
+ llfloaterlandmark.h
+ llfloatermap.h
+ llfloatermute.h
+ llfloaternamedesc.h
+ llfloaternewim.h
+ llfloateropenobject.h
+ llfloaterparcel.h
+ llfloaterpermissionsmgr.h
+ llfloaterpostcard.h
+ llfloaterpostprocess.h
+ llfloaterpreference.h
+ llfloaterproperties.h
+ llfloaterregioninfo.h
+ llfloaterreleasemsg.h
+ llfloaterreporter.h
+ llfloaterscriptdebug.h
+ llfloatersellland.h
+ llfloatersettingsdebug.h
+ llfloatersnapshot.h
+ llfloaterstats.h
+ llfloatertelehub.h
+ llfloatertest.h
+ llfloatertools.h
+ llfloatertopobjects.h
+ llfloatertos.h
+ llfloaterurldisplay.h
+ llfloaterurlentry.h
+ llfloatervoicedevicesettings.h
+ llfloaterwater.h
+ llfloaterwindlight.h
+ llfloaterworldmap.h
+ llfolderview.h
+ llfollowcam.h
+ llframestats.h
+ llframestatview.h
+ llgenepool.h
+ llgesturemgr.h
+ llgivemoney.h
+ llglslshader.h
+ llgroupmgr.h
+ llgroupnotify.h
+ llhippo.h
+ llhoverview.h
+ llhudeffect.h
+ llhudeffectbeam.h
+ llhudeffectlookat.h
+ llhudeffectpointat.h
+ llhudeffecttrail.h
+ llhudicon.h
+ llhudmanager.h
+ llhudobject.h
+ llhudrender.h
+ llhudtext.h
+ llhudview.h
+ llimpanel.h
+ llimview.h
+ llinventorybridge.h
+ llinventoryclipboard.h
+ llinventorymodel.h
+ llinventoryview.h
+ lljoystickbutton.h
+ lllandmarklist.h
+ lllightconstants.h
+ lllogchat.h
+ llmanip.h
+ llmaniprotate.h
+ llmanipscale.h
+ llmaniptranslate.h
+ llmapresponders.h
+ llmediaremotectrl.h
+ llmemoryview.h
+ llmenucommands.h
+ llmimetypes.h
+ llmorphview.h
+ llmoveview.h
+ llmutelist.h
+ llnamebox.h
+ llnameeditor.h
+ llnamelistctrl.h
+ llnetmap.h
+ llnotify.h
+ lloverlaybar.h
+ llpanelaudioprefs.h
+ llpanelaudiovolume.h
+ llpanelavatar.h
+ llpanelclassified.h
+ llpanelcontents.h
+ llpaneldebug.h
+ llpaneldirbrowser.h
+ llpaneldirclassified.h
+ llpaneldirevents.h
+ llpaneldirfind.h
+ llpaneldirgroups.h
+ llpaneldirland.h
+ llpaneldirpeople.h
+ llpaneldirplaces.h
+ llpaneldirpopular.h
+ llpaneldisplay.h
+ llpanelevent.h
+ llpanelface.h
+ llpanelgeneral.h
+ llpanelgroup.h
+ llpanelgroupgeneral.h
+ llpanelgroupinvite.h
+ llpanelgrouplandmoney.h
+ llpanelgroupnotices.h
+ llpanelgrouproles.h
+ llpanelgroupvoting.h
+ llpanelinput.h
+ llpanelinventory.h
+ llpanelland.h
+ llpanellandmedia.h
+ llpanellandobjects.h
+ llpanellandoptions.h
+ llpanelLCD.h
+ llpanellogin.h
+ llpanelmorph.h
+ llpanelmsgs.h
+ llpanelnetwork.h
+ llpanelobject.h
+ llpanelpermissions.h
+ llpanelpick.h
+ llpanelplace.h
+ llpanelvolume.h
+ llpanelweb.h
+ llparcelselection.h
+ llpatchvertexarray.h
+ llpostprocess.h
+ llpolymesh.h
+ llpolymorph.h
+ llprefschat.h
+ llprefsim.h
+ llprefsvoice.h
+ llpreview.h
+ llpreviewanim.h
+ llpreviewgesture.h
+ llpreviewlandmark.h
+ llpreviewnotecard.h
+ llpreviewscript.h
+ llpreviewsound.h
+ llpreviewtexture.h
+ llprogressview.h
+ llregionposition.h
+ llremoteparcelrequest.h
+ llrendersphere.h
+ llresourcedata.h
+ llsavedsettingsglue.h
+ llselectmgr.h
+ llsky.h
+ llspatialpartition.h
+ llsprite.h
+ llsrv.h
+ llstartup.h
+ llstatbar.h
+ llstatgraph.h
+ llstatusbar.h
+ llstatview.h
+ llstylemap.h
+ llsurface.h
+ llsurfacepatch.h
+ lltable.h
+ lltexlayer.h
+ lltexturecache.h
+ lltexturectrl.h
+ lltexturefetch.h
+ lltextureview.h
+ lltool.h
+ lltoolbar.h
+ lltoolbrush.h
+ lltoolcomp.h
+ lltooldraganddrop.h
+ lltoolface.h
+ lltoolfocus.h
+ lltoolgrab.h
+ lltoolgun.h
+ lltoolindividual.h
+ lltoolmgr.h
+ lltoolmorph.h
+ lltoolobjpicker.h
+ lltoolpie.h
+ lltoolpipette.h
+ lltoolplacer.h
+ lltoolselect.h
+ lltoolselectland.h
+ lltoolselectrect.h
+ lltoolview.h
+ lltracker.h
+ lltrans.h
+ lluiconstants.h
+ lluploaddialog.h
+ llurl.h
+ llurldispatcher.h
+ llurlhistory.h
+ llurlsimstring.h
+ llurlwhitelist.h
+ lluserauth.h
+ llvectorperfoptions.h
+ llvelocitybar.h
+ llviewchildren.h
+ llviewerassetstorage.h
+ llvieweraudio.h
+ llviewerbuild.h
+ llviewercamera.h
+ llviewercontrol.h
+ llviewerdisplay.h
+ llviewergenericmessage.h
+ llviewergesture.h
+ llviewerimage.h
+ llviewerimagelist.h
+ llviewerinventory.h
+ llviewerjoint.h
+ llviewerjointattachment.h
+ llviewerjointmesh.h
+ llviewerjoystick.h
+ llviewerkeyboard.h
+ llviewerlayer.h
+ llviewermedia.h
+ llviewermenu.h
+ llviewermenufile.h
+ llviewermessage.h
+ llviewernetwork.h
+ llviewerobject.h
+ llviewerobjectlist.h
+ llviewerparcelmedia.h
+ llviewerparcelmediaautoplay.h
+ llviewerparcelmgr.h
+ llviewerparceloverlay.h
+ llviewerpartsim.h
+ llviewerpartsource.h
+ llviewerprecompiledheaders.h
+ llviewerregion.h
+ llviewerstats.h
+ llviewertexteditor.h
+ llviewertextureanim.h
+ llviewerthrottle.h
+ llviewervisualparam.h
+ llviewerwindow.h
+ llvlcomposition.h
+ llvlmanager.h
+ llvoavatar.h
+ llvocache.h
+ llvoclouds.h
+ llvograss.h
+ llvoground.h
+ llvoiceclient.h
+ llvoiceremotectrl.h
+ llvoicevisualizer.h
+ llvoinventorylistener.h
+ llvopartgroup.h
+ llvosky.h
+ llvosurfacepatch.h
+ llvotextbubble.h
+ llvotree.h
+ llvotreenew.h
+ llvovolume.h
+ llvowater.h
+ llvowlsky.h
+ llwatchdog.h
+ llwaterparammanager.h
+ llwaterparamset.h
+ llwearable.h
+ llwearablelist.h
+ llweb.h
+ llwebbrowserctrl.h
+ llwind.h
+ llwindebug.h
+ llwlanimator.h
+ llwldaycycle.h
+ llwlparammanager.h
+ llwlparamset.h
+ llworld.h
+ llworldmap.h
+ llworldmapview.h
+ llxmlrpctransaction.h
+ macmain.h
+ noise.h
+ pipeline.h
+ randgauss.h
+ VertexCache.h
+ VorbisFramework.h
+ )
+
+source_group("CMake Rules" FILES ViewerInstall.cmake)
+
+if (DARWIN)
+ LIST(APPEND viewer_SOURCE_FILES llappviewermacosx.cpp)
+
+ find_library(AGL_LIBRARY AGL)
+ find_library(APPKIT_LIBRARY AppKit)
+ find_library(COCOA_LIBRARY Cocoa)
+ find_library(IOKIT_LIBRARY IOKit)
+
+ set(viewer_LIBRARIES
+ ${COCOA_LIBRARY}
+ ${AGL_LIBRARY}
+ ${IOKIT_LIBRARY}
+ )
+
+ # Add resource files to the project.
+ set(viewer_RESOURCE_FILES
+ secondlife.icns
+ macview.r
+ gpu_table.txt
+ Info-SecondLife.plist
+ SecondLife.nib/
+ # CMake doesn't seem to support Xcode language variants well just yet
+ English.lproj/InfoPlist.strings
+ English.lproj/language.txt
+ German.lproj/language.txt
+ Japanese.lproj/language.txt
+ Korean.lproj/language.txt
+ )
+ set_source_files_properties(
+ ${viewer_RESOURCE_FILES}
+ PROPERTIES
+ HEADER_FILE_ONLY TRUE
+ #MACOSX_PACKAGE_LOCATION Resources #don't do this! this tells cmake to copy the files.
+ )
+ SOURCE_GROUP("Resources" FILES ${viewer_RESOURCE_FILES})
+ list(APPEND viewer_SOURCE_FILES ${viewer_RESOURCE_FILES})
+endif (DARWIN)
+
+if (LINUX)
+ LIST(APPEND viewer_SOURCE_FILES llappviewerlinux.cpp)
+ LIST(APPEND CMAKE_EXE_LINKER_FLAGS -Wl,--as-needed)
+
+ set(viewer_LIBRARIES
+ Xinerama
+ )
+endif (LINUX)
+
+if (WINDOWS)
+ list(APPEND viewer_SOURCE_FILES
+ llappviewerwin32.cpp
+ llwindebug.cpp
+ )
+
+ list(APPEND viewer_HEADER_FILES
+ llappviewerwin32.h
+ llwindebug.h
+ )
+
+ # Add resource files to the project.
+ # viewerRes.rc is the only buildable file, but
+ # the rest are all dependencies of it.
+ set(viewer_RESOURCE_FILES
+ res/arrow.cur
+ res/arrowcop.cur
+ res/arrowcopmulti.cur
+ res/arrowdrag.cur
+ res/bitmap2.bmp
+ res/circleandline.cur
+ res/icon1.ico
+ res/install_icon.BMP
+ res/install_icon.ico
+ res/llarrow.cur
+ res/llarrowdrag.cur
+ res/llarrowdragmulti.cur
+ res/llarrowlocked.cur
+ res/llgrablocked.cur
+ res/llno.cur
+ res/llnolocked.cur
+ res/lltoolcamera.cur
+ res/lltoolcreate.cur
+ res/lltoolfocus.cur
+ res/lltoolgrab.cur
+ res/lltoolland.cur
+ res/lltoolpan.cur
+ res/lltoolpipette.cur
+ res/lltoolrotate.cur
+ res/lltoolscale.cur
+ res/lltooltranslate.cur
+ res/lltoolzoomin.cur
+ res/lltoolzoomout.cur
+ res/ll_icon.BMP
+ res/ll_icon.ico
+ res/loginbackground.bmp
+ res/resource.h
+ res/toolbuy.cur
+ res/toolopen.cur
+ res/toolpay.cur
+ res/toolpickobject.cur
+ res/toolpickobject2.cur
+ res/toolpickobject3.cur
+ res/toolpipette.cur
+ res/toolsit.cur
+ res/uninstall_icon.BMP
+ res/uninstall_icon.ico
+ )
+
+ set_source_files_properties(${viewer_RESOURCE_FILES}
+ PROPERTIES HEADER_FILE_ONLY TRUE)
+
+ set(viewer_RESOURCE_FILES
+ res/viewerRes.rc
+ ${viewer_RESOURCE_FILES}
+ )
+
+ SOURCE_GROUP("Resource Files" FILES ${viewer_RESOURCE_FILES})
+
+ list(APPEND viewer_SOURCE_FILES ${viewer_RESOURCE_FILES})
+
+ find_library(DINPUT_LIBRARY dinput8 ${DIRECTX_LIBRARY_DIR})
+ find_library(DXGUID_LIBRARY dxguid ${DIRECTX_LIBRARY_DIR})
+ mark_as_advanced(
+ DINPUT_LIBRARY
+ DXGUID_LIBRARY
+ )
+
+ set(viewer_LIBRARIES
+ advapi32
+ comdlg32
+ ${DINPUT_LIBRARY}
+ ${DXGUID_LIBRARY}
+ fmodvc
+ gdi32
+ kernel32
+ odbc32
+ odbccp32
+ ole32
+ oleaut32
+ opengl32
+ shell32
+ user32
+ Vfw32
+ winspool
+ )
+
+ find_library(INTEL_MEMOPS_LIBRARY
+ NAMES ll_intel_memops
+ PATHS
+ optimized ${ARCH_PREBUILT_DIRS_RELEASE}
+ debug ${ARCH_PREBUILT_DIRS_DEBUG}
+ )
+ mark_as_advanced(INTEL_MEMOPS_LIBRARY)
+
+ if (INTEL_MEMOPS_LIBRARY)
+ list(APPEND viewer_LIBRARIES ${INTEL_MEMOPS_LIBRARY})
+ endif (INTEL_MEMOPS_LIBRARY)
+endif (WINDOWS)
+
+# Add the xui files. This is handy for searching for xui elements
+# from within the IDE
+set(viewer_XUI_FILES
+ skins/xui/en-us/alerts.xml
+ skins/xui/en-us/floater_about_land.xml
+ skins/xui/en-us/floater_about.xml
+ skins/xui/en-us/floater_active_speakers.xml
+ skins/xui/en-us/floater_animation_preview.xml
+ skins/xui/en-us/floater_auction.xml
+ skins/xui/en-us/floater_audio_volume.xml
+ skins/xui/en-us/floater_avatar_picker.xml
+ skins/xui/en-us/floater_avatar_textures.xml
+ skins/xui/en-us/floater_build_options.xml
+ skins/xui/en-us/floater_bumps.xml
+ skins/xui/en-us/floater_buy_contents.xml
+ skins/xui/en-us/floater_buy_currency.xml
+ skins/xui/en-us/floater_buy_land.xml
+ skins/xui/en-us/floater_buy_object.xml
+ skins/xui/en-us/floater_camera.xml
+ skins/xui/en-us/floater_chat_history.xml
+ skins/xui/en-us/floater_chatterbox.xml
+ skins/xui/en-us/floater_choose_group.xml
+ skins/xui/en-us/floater_clothing.xml
+ skins/xui/en-us/floater_color_picker.xml
+ skins/xui/en-us/floater_critical.xml
+ skins/xui/en-us/floater_customize.xml
+ skins/xui/en-us/floater_day_cycle_options.xml
+ skins/xui/en-us/floater_device_settings.xml
+ skins/xui/en-us/floater_directory.xml
+ skins/xui/en-us/floater_env_settings.xml
+ skins/xui/en-us/floater_gesture.xml
+ skins/xui/en-us/floater_god_tools.xml
+ skins/xui/en-us/floater_group_info.xml
+ skins/xui/en-us/floater_hardware_settings.xml
+ skins/xui/en-us/floater_html.xml
+ skins/xui/en-us/floater_hud.xml
+ skins/xui/en-us/floater_image_preview.xml
+ skins/xui/en-us/floater_import.xml
+ skins/xui/en-us/floater_im.xml
+ skins/xui/en-us/floater_inspect.xml
+ skins/xui/en-us/floater_instant_message_ad_hoc.xml
+ skins/xui/en-us/floater_instant_message_group.xml
+ skins/xui/en-us/floater_instant_message.xml
+ skins/xui/en-us/floater_inventory_item_properties.xml
+ skins/xui/en-us/floater_inventory_view_finder.xml
+ skins/xui/en-us/floater_inventory.xml
+ skins/xui/en-us/floater_joystick.xml
+ skins/xui/en-us/floater_lagmeter.xml
+ skins/xui/en-us/floater_land_holdings.xml
+ skins/xui/en-us/floater_landmark_ctrl.xml
+ skins/xui/en-us/floater_live_lsleditor.xml
+ skins/xui/en-us/floater_lsl_guide.xml
+ skins/xui/en-us/floater_media_browser.xml
+ skins/xui/en-us/floater_moveview.xml
+ skins/xui/en-us/floater_mute_object.xml
+ skins/xui/en-us/floater_mute.xml
+ skins/xui/en-us/floater_my_friends.xml
+ skins/xui/en-us/floater_name_description.xml
+ skins/xui/en-us/floater_new_im.xml
+ skins/xui/en-us/floater_new_outfit_dialog.xml
+ skins/xui/en-us/floater_openobject.xml
+ skins/xui/en-us/floater_pay_object.xml
+ skins/xui/en-us/floater_pay.xml
+ skins/xui/en-us/floater_postcard.xml
+ skins/xui/en-us/floater_post_process.xml
+ skins/xui/en-us/floater_preferences.xml
+ skins/xui/en-us/floater_preview_animation.xml
+ skins/xui/en-us/floater_preview_classified.xml
+ skins/xui/en-us/floater_preview_embedded_texture.xml
+ skins/xui/en-us/floater_preview_event.xml
+ skins/xui/en-us/floater_preview_existing_landmark.xml
+ skins/xui/en-us/floater_preview_gesture.xml
+ skins/xui/en-us/floater_preview_notecard_keep_discard.xml
+ skins/xui/en-us/floater_preview_notecard.xml
+ skins/xui/en-us/floater_preview_sound.xml
+ skins/xui/en-us/floater_preview_texture_keep_discard.xml
+ skins/xui/en-us/floater_preview_texture.xml
+ skins/xui/en-us/floater_preview_url.xml
+ skins/xui/en-us/floater_price_for_listing.xml
+ skins/xui/en-us/floater_profile.xml
+ skins/xui/en-us/floater_region_info.xml
+ skins/xui/en-us/floater_report_abuse.xml
+ skins/xui/en-us/floater_report_bug.xml
+ skins/xui/en-us/floater_script_debug.xml
+ skins/xui/en-us/floater_script_ed_panel.xml
+ skins/xui/en-us/floater_script_preview.xml
+ skins/xui/en-us/floater_script_queue.xml
+ skins/xui/en-us/floater_script_search.xml
+ skins/xui/en-us/floater_select_key.xml
+ skins/xui/en-us/floater_sell_land.xml
+ skins/xui/en-us/floater_settings_debug.xml
+ skins/xui/en-us/floater_sim_release_message.xml
+ skins/xui/en-us/floater_snapshot.xml
+ skins/xui/en-us/floater_sound_preview.xml
+ skins/xui/en-us/floater_telehub.xml
+ skins/xui/en-us/floater_test.xml
+ skins/xui/en-us/floater_texture_ctrl.xml
+ skins/xui/en-us/floater_tools.xml
+ skins/xui/en-us/floater_top_objects.xml
+ skins/xui/en-us/floater_tos.xml
+ skins/xui/en-us/floater_url_entry.xml
+ skins/xui/en-us/floater_voice_wizard.xml
+ skins/xui/en-us/floater_water.xml
+ skins/xui/en-us/floater_wearable_save_as.xml
+ skins/xui/en-us/floater_windlight_options.xml
+ skins/xui/en-us/floater_world_map.xml
+ skins/xui/en-us/menu_inventory.xml
+ skins/xui/en-us/menu_login.xml
+ skins/xui/en-us/menu_pie_attachment.xml
+ skins/xui/en-us/menu_pie_avatar.xml
+ skins/xui/en-us/menu_pie_land.xml
+ skins/xui/en-us/menu_pie_object.xml
+ skins/xui/en-us/menu_pie_self.xml
+ skins/xui/en-us/menu_slurl.xml
+ skins/xui/en-us/menu_viewer.xml
+ skins/xui/en-us/mime_types.xml
+ skins/xui/en-us/notify.xml
+ skins/xui/en-us/panel_audio_device.xml
+ skins/xui/en-us/panel_audio.xml
+ skins/xui/en-us/panel_avatar_classified.xml
+ skins/xui/en-us/panel_avatar_pick.xml
+ skins/xui/en-us/panel_avatar.xml
+ skins/xui/en-us/panel_bars.xml
+ skins/xui/en-us/panel_bg_tab.xml
+ skins/xui/en-us/panel_bg_toolbar.xml
+ skins/xui/en-us/panel_chat_bar.xml
+ skins/xui/en-us/panel_classified.xml
+ skins/xui/en-us/panel_event.xml
+ skins/xui/en-us/panel_friends.xml
+ skins/xui/en-us/panel_group_finder.xml
+ skins/xui/en-us/panel_group_general.xml
+ skins/xui/en-us/panel_group_invite.xml
+ skins/xui/en-us/panel_group_land_money.xml
+ skins/xui/en-us/panel_group_notices.xml
+ skins/xui/en-us/panel_group_roles.xml
+ skins/xui/en-us/panel_groups.xml
+ skins/xui/en-us/panel_group_voting.xml
+ skins/xui/en-us/panel_group.xml
+ skins/xui/en-us/panel_land_covenant.xml
+ skins/xui/en-us/panel_login.xml
+ skins/xui/en-us/panel_master_volume.xml
+ skins/xui/en-us/panel_media_controls.xml
+ skins/xui/en-us/panel_media_remote_expanded.xml
+ skins/xui/en-us/panel_media_remote.xml
+ skins/xui/en-us/panel_overlaybar.xml
+ skins/xui/en-us/panel_place_small.xml
+ skins/xui/en-us/panel_place.xml
+ skins/xui/en-us/panel_preferences_audio.xml
+ skins/xui/en-us/panel_preferences_chat.xml
+ skins/xui/en-us/panel_preferences_general.xml
+ skins/xui/en-us/panel_preferences_graphics1.xml
+ skins/xui/en-us/panel_preferences_im.xml
+ skins/xui/en-us/panel_preferences_input.xml
+ skins/xui/en-us/panel_preferences_network.xml
+ skins/xui/en-us/panel_preferences_popups.xml
+ skins/xui/en-us/panel_preferences_voice.xml
+ skins/xui/en-us/panel_preferences_web.xml
+ skins/xui/en-us/panel_region_covenant.xml
+ skins/xui/en-us/panel_region_debug.xml
+ skins/xui/en-us/panel_region_estate.xml
+ skins/xui/en-us/panel_region_general.xml
+ skins/xui/en-us/panel_region_terrain.xml
+ skins/xui/en-us/panel_region_texture.xml
+ skins/xui/en-us/panel_scrolling_param.xml
+ skins/xui/en-us/panel_speaker_controls.xml
+ skins/xui/en-us/panel_status_bar.xml
+ skins/xui/en-us/panel_toolbar.xml
+ skins/xui/en-us/panel_top_pick.xml
+ skins/xui/en-us/panel_voice_controls.xml
+ skins/xui/en-us/panel_voice_enable.xml
+ skins/xui/en-us/panel_voice_options.xml
+ skins/xui/en-us/panel_voice_remote_expanded.xml
+ skins/xui/en-us/panel_voice_remote.xml
+ skins/xui/en-us/role_actions.xml
+ skins/xui/en-us/strings.xml
+ skins/xui/en-us/teleport_strings.xml
+ skins/xui/en-us/xui_version.xml
+ )
+
+source_group("XUI Files" FILES ${viewer_XUI_FILES})
+
+set_source_files_properties(${viewer_XUI_FILES}
+ PROPERTIES HEADER_FILE_ONLY TRUE)
+
+list(APPEND viewer_SOURCE_FILES ${viewer_XUI_FILES})
+
+if (FMOD)
+ set_source_files_properties(llstartup.cpp PROPERTIES COMPILE_FLAGS -DLL_FMOD)
+
+ if (NOT WINDOWS)
+ set(fmodwrapper_SOURCE_FILES fmodwrapper.cpp)
+ add_library(fmodwrapper SHARED ${fmodwrapper_SOURCE_FILES})
+ set(fmodwrapper_needed_LIBRARIES ${FMOD_LIBRARY})
+ if (DARWIN)
+ list(APPEND fmodwrapper_needed_LIBRARIES ${CARBON_LIBRARY})
+ set_target_properties(
+ fmodwrapper
+ PROPERTIES
+ BUILD_WITH_INSTALL_RPATH 1
+ INSTALL_NAME_DIR "@executable_path/../Resources"
+ )
+ endif (DARWIN)
+ set(FMODWRAPPER_LIBRARIES fmodwrapper)
+ list(APPEND viewer_LIBRARIES fmodwrapper)
+ target_link_libraries(fmodwrapper ${fmodwrapper_needed_LIBRARIES})
+ endif (NOT WINDOWS)
+endif (FMOD)
+
+list(APPEND viewer_SOURCE_FILES ${viewer_HEADER_FILES})
+
+set_source_files_properties(${viewer_HEADER_FILES}
+ PROPERTIES HEADER_FILE_ONLY TRUE)
+
+add_executable(secondlife-bin
+ WIN32
+ MACOSX_BUNDLE
+ ${viewer_SOURCE_FILES}
+ )
+check_message_template(secondlife-bin)
+
+if (LLKDU_LIBRARY)
+ add_dependencies(secondlife-bin ${LLKDU_LIBRARY})
+endif (LLKDU_LIBRARY)
+
+if (WINDOWS)
+ if(MSVC71)
+ set(release_flags "/MAP:Release/secondlife-bin.map /MAPINFO:LINES")
+ else(MSVC71)
+ set(release_flags "/MAP:Release/secondlife-bin.map")
+ endif(MSVC71)
+
+ set_target_properties(secondlife-bin
+ PROPERTIES
+ LINK_FLAGS "/debug /NODEFAULTLIB:MSVCRT /SUBSYSTEM:WINDOWS"
+ LINK_FLAGS_DEBUG "/NODEFAULTLIB:LIBCMT /NODEFAULTLIB:MSVCRTD"
+ LINK_FLAGS_RELEASE ${release_flags}
+ )
+
+ # sets the 'working directory' for debugging from visual studio.
+ if (NOT UNATTENDED)
+ add_custom_command(
+ TARGET secondlife-bin PRE_BUILD
+ COMMAND ${CMAKE_SOURCE_DIR}/tools/vstool/vstool.exe
+ ARGS
+ --solution
+ ${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}.sln
+ --workingdir
+ secondlife-bin
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ COMMENT "Setting the secondlife-bin working directory for debugging."
+ )
+ endif (NOT UNATTENDED)
+
+ add_custom_command(
+ TARGET secondlife-bin PRE_BUILD
+ COMMAND ${CMAKE_COMMAND}
+ ARGS
+ -E
+ copy_if_different
+ ${CMAKE_CURRENT_SOURCE_DIR}/../../scripts/messages/message_template.msg
+ ${CMAKE_CURRENT_SOURCE_DIR}/app_settings/message_template.msg
+ COMMENT "Copying message_template.msg to the runtime folder."
+ )
+
+ add_custom_command(
+ TARGET secondlife-bin POST_BUILD
+ COMMAND ${PYTHON_EXECUTABLE}
+ ARGS
+ "${CMAKE_CURRENT_SOURCE_DIR}/postbuild_win32.py"
+ "${CMAKE_COMMAND} -E copy_if_different"
+ "${CMAKE_CFG_INTDIR}"
+ "${CMAKE_CURRENT_BINARY_DIR}"
+ DEPENDS secondlife-bin
+ COMMENT "Copying pre-built binaries to development folder."
+ )
+
+ if (EXISTS ${CMAKE_SOURCE_DIR}/copy_win_scripts)
+ add_dependencies(secondlife-bin copy_win_scripts)
+ endif (EXISTS ${CMAKE_SOURCE_DIR}/copy_win_scripts)
+
+ add_custom_target(package ALL DEPENDS ${CMAKE_CFG_INTDIR}/touched.bat)
+ add_custom_command(
+ OUTPUT ${CMAKE_CFG_INTDIR}/touched.bat
+ COMMAND ${PYTHON_EXECUTABLE}
+ ARGS
+ ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
+ --configuration=${CMAKE_CFG_INTDIR}
+ --channel=${VIEWER_CHANNEL}
+ --source=${CMAKE_CURRENT_SOURCE_DIR}
+ --artwork=${ARTWORK_DIR}
+ --build=${CMAKE_CURRENT_BINARY_DIR}
+ --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}
+ --touch=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/touched.bat
+ DEPENDS secondlife-bin ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
+ )
+ add_dependencies(package windows-updater windows-crash-logger)
+endif (WINDOWS)
+
+target_link_libraries(secondlife-bin
+ ${LLAUDIO_LIBRARIES}
+ ${LLCHARACTER_LIBRARIES}
+ ${LLIMAGE_LIBRARIES}
+ ${LLIMAGEJ2COJ_LIBRARIES}
+ ${LLINVENTORY_LIBRARIES}
+ ${LLMEDIA_LIBRARIES}
+ ${LLMESSAGE_LIBRARIES}
+ ${LLPRIMITIVE_LIBRARIES}
+ ${LLRENDER_LIBRARIES}
+ ${FREETYPE_LIBRARIES}
+ ${LLUI_LIBRARIES}
+ ${LLVFS_LIBRARIES}
+ ${LLWINDOW_LIBRARIES}
+ ${LLXML_LIBRARIES}
+ ${LSCRIPT_LIBRARIES}
+ ${LLMATH_LIBRARIES}
+ ${LLCOMMON_LIBRARIES}
+ ${viewer_LIBRARIES}
+ ${BOOST_PROGRAM_OPTIONS_LIBRARY}
+ ${BOOST_REGEX_LIBRARY}
+ ${BOOST_SIGNALS_LIBRARY}
+ ${OPENGL_LIBRARIES}
+ ${FMODWRAPPER_LIBRARIES}
+ ${OPENGL_LIBRARIES}
+ ${MOZLIB_LIBRARIES}
+ ${SDL_LIBRARY}
+ ${SMARTHEAP_LIBRARY}
+ ${UI_LIBRARIES}
+ ${NDOF_LIBRARY}
+ ${QUICKTIME_LIBRARY}
+ ${WINDOWS_LIBRARIES}
+ ${XMLRPCEPI_LIBRARIES}
+ ${ZLIB_LIBRARIES}
+ ${ELFIO_LIBRARIES}
+ )
+
+build_version(viewer)
+
+set(ARTWORK_DIR ${CMAKE_CURRENT_SOURCE_DIR} CACHE PATH
+ "Path to artwork files.")
+
+set(VIEWER_CHANNEL "Developer" CACHE STRING
+ "The name of the channel to use.")
+
+if (LINUX)
+ add_custom_command(
+ OUTPUT secondlife-stripped-globalsyms
+ COMMAND strip
+ ARGS --strip-debug -o secondlife-stripped-globalsyms secondlife-bin
+ DEPENDS secondlife-bin
+ )
+
+ add_custom_command(
+ OUTPUT secondlife-stripped
+ COMMAND objcopy
+ ARGS
+ --keep-global-symbols
+ ${CMAKE_CURRENT_SOURCE_DIR}/linux_tools/exposed-symbols.txt
+ secondlife-stripped-globalsyms
+ secondlife-stripped
+ DEPENDS
+ secondlife-stripped-globalsyms
+ ${CMAKE_CURRENT_SOURCE_DIR}/linux_tools/exposed-symbols.txt
+ )
+
+ set(product SecondLife-${ARCH}-${viewer_VERSION})
+
+ add_custom_command(
+ OUTPUT ${product}.tar.bz2
+ COMMAND ${PYTHON_EXECUTABLE}
+ ARGS
+ ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
+ --grid=agni
+ --channel=${VIEWER_CHANNEL}
+ --installer_name=${product}
+ --arch=${ARCH}
+ --source=${CMAKE_CURRENT_SOURCE_DIR}
+ --artwork=${ARTWORK_DIR}
+ --build=${CMAKE_CURRENT_BINARY_DIR}
+ --dest=${CMAKE_CURRENT_BINARY_DIR}/packaged
+ --touch=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/.${product}.touched
+ DEPENDS secondlife-stripped ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
+ )
+
+ if (NOT INSTALL)
+ add_custom_target(package ALL DEPENDS ${product}.tar.bz2)
+ add_dependencies(package linux-crash-logger-stripped)
+ endif (NOT INSTALL)
+endif (LINUX)
+
+if (DARWIN)
+ set(product "Second Life")
+ set_target_properties(
+ secondlife-bin
+ PROPERTIES
+ OUTPUT_NAME "${product}"
+ MACOSX_BUNDLE_INFO_STRING "info string - localize me"
+ MACOSX_BUNDLE_ICON_FILE "secondlife.icns"
+ MACOSX_BUNDLE_GUI_IDENTIFIER "Second Life"
+ MACOSX_BUNDLE_LONG_VERSION_STRING "ververver"
+ MACOSX_BUNDLE_BUNDLE_NAME "Second Life"
+ MACOSX_BUNDLE_SHORT_VERSION_STRING "asdf"
+ MACOSX_BUNDLE_BUNDLE_VERSION "asdf"
+ MACOSX_BUNDLE_COPYRIGHT "copyright linden lab 2007 - localize me and run me through a legal wringer"
+ )
+
+ add_custom_command(
+ TARGET secondlife-bin POST_BUILD
+ COMMAND ${PYTHON_EXECUTABLE}
+ ARGS
+ ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
+ --actions=copy
+ --configuration=${CMAKE_CFG_INTDIR}
+ --source=${CMAKE_CURRENT_SOURCE_DIR}
+ --artwork=${ARTWORK_DIR}
+ --build=${CMAKE_CURRENT_BINARY_DIR}
+ --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app
+ DEPENDS secondlife-bin ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
+ )
+
+ add_custom_command(
+ OUTPUT ${CMAKE_CFG_INTDIR}/.${product}.touched
+ COMMAND ${PYTHON_EXECUTABLE}
+ ARGS
+ ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
+ --configuration=${CMAKE_CFG_INTDIR}
+ --channel=${VIEWER_CHANNEL}
+ --source=${CMAKE_CURRENT_SOURCE_DIR}
+ --artwork=${ARTWORK_DIR}
+ --build=${CMAKE_CURRENT_BINARY_DIR}
+ --dest=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${product}.app
+ --touch=${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/.${product}.touched
+ DEPENDS secondlife-bin ${CMAKE_CURRENT_SOURCE_DIR}/viewer_manifest.py
+ )
+
+ add_custom_target(package DEPENDS "${CMAKE_CFG_INTDIR}/.${product}.touched")
+endif (DARWIN)
+
+if (INSTALL)
+ include(${CMAKE_CURRENT_SOURCE_DIR}/ViewerInstall.cmake)
+endif (INSTALL)
diff --git a/indra/newview/ViewerInstall.cmake b/indra/newview/ViewerInstall.cmake
new file mode 100644
index 0000000000..55069ad2b5
--- /dev/null
+++ b/indra/newview/ViewerInstall.cmake
@@ -0,0 +1,28 @@
+install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/secondlife-bin
+ DESTINATION ${APP_BINARY_DIR}
+ )
+
+install(DIRECTORY skins app_settings linux_tools
+ DESTINATION ${APP_SHARE_DIR}
+ PATTERN ".svn" EXCLUDE
+ )
+
+find_file(IS_ARTWORK_PRESENT NAMES avatar_lad.xml
+ PATHS ${VIEWER_DIR}/newview/character)
+
+if (IS_ARTWORK_PRESENT)
+ install(DIRECTORY res res-sdl character
+ DESTINATION ${APP_SHARE_DIR}
+ PATTERN ".svn" EXCLUDE
+ )
+else (IS_ARTWORK_PRESENT)
+ message(STATUS "WARNING: Artwork is not present, and will not be installed")
+endif (IS_ARTWORK_PRESENT)
+
+install(FILES featuretable_linux.txt featuretable_solaris.txt gpu_table.txt
+ DESTINATION ${APP_SHARE_DIR}
+ )
+
+install(FILES ${SCRIPTS_DIR}/messages/message_template.msg
+ DESTINATION ${APP_SHARE_DIR}/app_settings
+ )
diff --git a/indra/newview/installers/windows/installer_template.nsi b/indra/newview/installers/windows/installer_template.nsi
index 836780d140..fb2fa23400 100644
--- a/indra/newview/installers/windows/installer_template.nsi
+++ b/indra/newview/installers/windows/installer_template.nsi
@@ -37,10 +37,10 @@ XPStyle on ; add an XP manifest to the installer
;; (these files are in the same place as the nsi template but the python script generates a new nsi file in the
;; application directory so we have to add a path to these include files)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-!include "installers\windows\lang_de.nsi"
-!include "installers\windows\lang_en-us.nsi"
-!include "installers\windows\lang_ja.nsi"
-!include "installers\windows\lang_ko.nsi"
+!include "%%SOURCE%%\installers\windows\lang_de.nsi"
+!include "%%SOURCE%%\installers\windows\lang_en-us.nsi"
+!include "%%SOURCE%%\installers\windows\lang_ja.nsi"
+!include "%%SOURCE%%\installers\windows\lang_ko.nsi"
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Tweak for different servers/builds (this placeholder is replaced by viewer_manifest.py)
@@ -51,8 +51,8 @@ Name ${INSTNAME}
SubCaption 0 $(LicenseSubTitleSetup) ; override "license agreement" text
BrandingText " " ; bottom of window text
-Icon res\install_icon.ico ; our custom icon
-UninstallIcon res\uninstall_icon.ico ; our custom icon
+Icon %%SOURCE%%\res\install_icon.ico ; our custom icon
+UninstallIcon %%SOURCE%%\res\uninstall_icon.ico ; our custom icon
WindowIcon on ; show our icon in left corner
BGGradient off ; no big background window
CRCCheck on ; make sure CRC is OK
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp
index 2c9dec3801..a6173f45df 100644
--- a/indra/newview/llappviewer.cpp
+++ b/indra/newview/llappviewer.cpp
@@ -791,12 +791,12 @@ bool LLAppViewer::init()
//
initWindow();
- #if LL_WINDOWS && LL_LCD_COMPILE
+#if LL_LCD_COMPILE
// start up an LCD window on a logitech keyboard, if there is one
HINSTANCE hInstance = GetModuleHandle(NULL);
gLcdScreen = new LLLCD(hInstance);
CreateLCDDebugWindows();
- #endif
+#endif
gGLManager.getGLInfo(gDebugInfo);
gGLManager.printGLInfoString();
@@ -983,7 +983,7 @@ bool LLAppViewer::mainLoop()
LLFloaterSnapshot::update(); // take snapshots
-#if LL_WINDOWS && LL_LCD_COMPILE
+#if LL_LCD_COMPILE
// update LCD Screen
gLcdScreen->UpdateDisplay();
#endif
@@ -1239,7 +1239,7 @@ bool LLAppViewer::cleanup()
// gDXHardware.cleanup();
//#endif // LL_WINDOWS
-#if LL_WINDOWS && LL_LCD_COMPILE
+#if LL_LCD_COMPILE
// shut down the LCD window on a logitech keyboard, if there is one
delete gLcdScreen;
gLcdScreen = NULL;
diff --git a/indra/newview/llappviewerlinux.cpp b/indra/newview/llappviewerlinux.cpp
index 753ea1bc6c..cb44e2b1de 100644
--- a/indra/newview/llappviewerlinux.cpp
+++ b/indra/newview/llappviewerlinux.cpp
@@ -45,14 +45,7 @@
#if LL_LINUX
# include <dlfcn.h> // RTLD_LAZY
-# include <execinfo.h> // backtrace - glibc only
-# ifndef LL_ELFBIN
-# define LL_ELFBIN 1
-# endif // LL_ELFBIN
-# if LL_ELFBIN
-# include <cxxabi.h> // for symbol demangling
-# include "ELFIO.h" // for better backtraces
-# endif // LL_ELFBIN
+# include <execinfo.h> // backtrace - glibc only
#elif LL_SOLARIS
# include <sys/types.h>
# include <unistd.h>
@@ -60,6 +53,13 @@
# include <ucontext.h>
#endif
+#ifdef LL_ELFBIN
+# ifdef __GNUC__
+# include <cxxabi.h> // for symbol demangling
+# endif
+# include "ELFIO/ELFIO.h" // for better backtraces
+#endif
+
namespace
{
int gArgC = 0;
@@ -338,25 +338,25 @@ void LLAppViewerLinux::handleCrashReporting()
if (CRASH_BEHAVIOR_NEVER_SEND != LLAppViewer::instance()->getCrashBehavior())
{
// launch the actual crash logger
- char* ask_dialog = "-dialog";
+ const char* ask_dialog = "-dialog";
if (CRASH_BEHAVIOR_ASK != LLAppViewer::instance()->getCrashBehavior())
ask_dialog = ""; // omit '-dialog' option
std::string cmd =gDirUtilp->getAppRODataDir();
cmd += gDirUtilp->getDirDelimiter();
cmd += "linux-crash-logger.bin";
- char* const cmdargv[] =
- {(char*)cmd.c_str(),
+ const char * cmdargv[] =
+ {cmd.c_str(),
ask_dialog,
- (char*)"-user",
+ "-user",
(char*)gGridName.c_str(),
- (char*)"-name",
- (char*)LLAppViewer::instance()->getSecondLifeTitle().c_str(),
+ "-name",
+ LLAppViewer::instance()->getSecondLifeTitle().c_str(),
NULL};
fflush(NULL);
pid_t pid = fork();
if (pid == 0)
{ // child
- execv(cmd.c_str(), cmdargv); /* Flawfinder: ignore */
+ execv(cmd.c_str(), (char* const*) cmdargv); /* Flawfinder: ignore */
llwarns << "execv failure when trying to start " << cmd << llendl;
_exit(1); // avoid atexit()
}
diff --git a/indra/newview/llappviewermacosx.cpp b/indra/newview/llappviewermacosx.cpp
index f21bdc4243..c1e6888478 100644
--- a/indra/newview/llappviewermacosx.cpp
+++ b/indra/newview/llappviewermacosx.cpp
@@ -65,7 +65,12 @@ int main( int argc, char **argv )
#endif
// Set the working dir to <bundle>/Contents/Resources
- (void) chdir(gDirUtilp->getAppRODataDir().c_str());
+ if (chdir(gDirUtilp->getAppRODataDir().c_str()) == -1)
+ {
+ llwarns << "Could not change directory to "
+ << gDirUtilp->getAppRODataDir() << ": " << strerror(errno)
+ << llendl;
+ }
LLAppViewerMacOSX* viewer_app_ptr = new LLAppViewerMacOSX();
diff --git a/indra/newview/lleventinfo.cpp b/indra/newview/lleventinfo.cpp
index 0e69891731..91401a048b 100644
--- a/indra/newview/lleventinfo.cpp
+++ b/indra/newview/lleventinfo.cpp
@@ -41,7 +41,7 @@ LLEventInfo::cat_map LLEventInfo::sCategories;
LLEventInfo::LLEventInfo(F32 global_x, F32 global_y,
const char* name,
U32 id,
- S32 unix_time,
+ time_t unix_time,
U32 event_flags)
: mName( name ),
mID( id ),
@@ -91,7 +91,9 @@ void LLEventInfo::unpack(LLMessageSystem *msg)
msg->getU32("EventData","Duration",duration);
mDuration = duration;
- msg->getU32("EventData", "DateUTC", mUnixTime);
+ U32 date;
+ msg->getU32("EventData", "DateUTC", date);
+ mUnixTime = date;
msg->getString("EventData", "Desc", MAX_DESC_LENGTH, buffer);
mDesc = buffer;
diff --git a/indra/newview/lleventinfo.h b/indra/newview/lleventinfo.h
index 6d76b0c74d..4d0687f81c 100644
--- a/indra/newview/lleventinfo.h
+++ b/indra/newview/lleventinfo.h
@@ -44,7 +44,7 @@ class LLEventInfo
{
public:
LLEventInfo() {}
- LLEventInfo(F32 global_x, F32 global_y, const char* name, U32 id, S32 unix_time, U32 event_flags);
+ LLEventInfo(F32 global_x, F32 global_y, const char* name, U32 id, time_t unix_time, U32 event_flags);
void unpack(LLMessageSystem *msg);
@@ -60,7 +60,7 @@ public:
LLUUID mRunByID;
LLString mSimName;
LLVector3d mPosGlobal;
- U32 mUnixTime; // seconds from 1970
+ time_t mUnixTime; // seconds from 1970
BOOL mHasCover;
U32 mCover;
U32 mEventFlags;
diff --git a/indra/newview/lleventnotifier.cpp b/indra/newview/lleventnotifier.cpp
index d7fe6777e2..3d2bbcd1f5 100644
--- a/indra/newview/lleventnotifier.cpp
+++ b/indra/newview/lleventnotifier.cpp
@@ -68,7 +68,7 @@ void LLEventNotifier::update()
// Check our notifications again and send out updates
// if they happen.
- U32 alert_time = time_corrected() + 5 * 60;
+ time_t alert_time = time_corrected() + 5 * 60;
en_map::iterator iter;
for (iter = mEventNotifications.begin();
iter != mEventNotifications.end();)
diff --git a/indra/newview/lleventnotifier.h b/indra/newview/lleventnotifier.h
index 1801efeabf..bbd1facf31 100644
--- a/indra/newview/lleventnotifier.h
+++ b/indra/newview/lleventnotifier.h
@@ -75,14 +75,14 @@ public:
//void setEventName(std::string &event_name);
U32 getEventID() const { return mEventID; }
const std::string &getEventName() const { return mEventName; }
- U32 getEventDate() const { return mEventDate; }
+ time_t getEventDate() const { return mEventDate; }
const std::string &getEventDateStr() const { return mEventDateStr; }
LLVector3d getEventPosGlobal() const { return mEventPosGlobal; }
protected:
U32 mEventID; // EventID for this event
std::string mEventName;
std::string mEventDateStr;
- U32 mEventDate;
+ time_t mEventDate;
LLVector3d mEventPosGlobal;
};
diff --git a/indra/newview/llfeaturemanager.cpp b/indra/newview/llfeaturemanager.cpp
index 17e8429616..c24b4c13d9 100644
--- a/indra/newview/llfeaturemanager.cpp
+++ b/indra/newview/llfeaturemanager.cpp
@@ -225,7 +225,7 @@ BOOL LLFeatureManager::loadFeatureTables()
data_path += gDirUtilp->getDirDelimiter();
data_path += FEATURE_TABLE_FILENAME;
-
+ lldebugs << "Looking for feature table in " << data_path << llendl;
char name[MAX_STRING+1]; /*Flawfinder: ignore*/
@@ -252,7 +252,7 @@ BOOL LLFeatureManager::loadFeatureTables()
mTableVersion = version;
LLFeatureList *flp = NULL;
- while (!file.eof())
+ while (!file.eof() && file.good())
{
char buffer[MAX_STRING]; /*Flawfinder: ignore*/
name[0] = 0;
diff --git a/indra/newview/llfloatercamera.cpp b/indra/newview/llfloatercamera.cpp
index ab85a8c3c1..24b82c370a 100644
--- a/indra/newview/llfloatercamera.cpp
+++ b/indra/newview/llfloatercamera.cpp
@@ -116,4 +116,4 @@ void LLFloaterCamera::onClose(bool app_quitting)
{
gSavedSettings.setBOOL("ShowCameraControls", FALSE);
}
-} \ No newline at end of file
+}
diff --git a/indra/newview/llfloaterchat.cpp b/indra/newview/llfloaterchat.cpp
index 1d4801bd35..3aaa14ab73 100644
--- a/indra/newview/llfloaterchat.cpp
+++ b/indra/newview/llfloaterchat.cpp
@@ -355,7 +355,7 @@ void LLFloaterChat::addChat(const LLChat& chat,
chat.mChatType == CHAT_TYPE_DEBUG_MSG
&& !gSavedSettings.getBOOL("ScriptErrorsAsChat");
-#if LL_WINDOWS && LL_LCD_COMPILE
+#if LL_LCD_COMPILE
// add into LCD displays
if (!invisible_script_debug_chat)
{
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp
index e66d545409..f78da984a9 100644
--- a/indra/newview/llfloaterpreference.cpp
+++ b/indra/newview/llfloaterpreference.cpp
@@ -75,14 +75,6 @@
#include "llscrollcontainer.h"
#include "llfloaterhardwaresettings.h"
-#if LL_WINDOWS
-// for Logitech LCD keyboards / speakers
-#ifndef LL_LOGITECH_LCD_H
-#include "lllogitechlcd.h"
-#endif
-extern LLLCD *gLcdScreen;
-#endif
-
const S32 PREF_BORDER = 4;
const S32 PREF_PAD = 5;
const S32 PREF_BUTTON_WIDTH = 70;
@@ -174,7 +166,7 @@ LLPreferenceCore::LLPreferenceCore(LLTabContainer* tab_container, LLButton * def
mTabContainer->addTabPanel(mPrefsIM->getPanel(), mPrefsIM->getPanel()->getLabel(), FALSE, onTabChanged, mTabContainer);
mPrefsIM->getPanel()->setDefaultBtn(default_btn);
-#if LL_WINDOWS && LL_LCD_COMPILE
+#if LL_LCD_COMPILE
// only add this option if we actually have a logitech keyboard / speaker set
if (gLcdScreen->Enabled())
@@ -264,7 +256,7 @@ void LLPreferenceCore::apply()
LLFloaterHardwareSettings::instance()->apply();
mWebPanel->apply();
-#if LL_WINDOWS && LL_LCD_COMPILE
+#if LL_LCD_COMPILE
// only add this option if we actually have a logitech keyboard / speaker set
if (gLcdScreen->Enabled())
{
@@ -291,7 +283,7 @@ void LLPreferenceCore::cancel()
LLFloaterHardwareSettings::instance()->cancel();
mWebPanel->cancel();
-#if LL_WINDOWS && LL_LCD_COMPILE
+#if LL_LCD_COMPILE
// only add this option if we actually have a logitech keyboard / speaker set
if (gLcdScreen->Enabled())
{
diff --git a/indra/newview/llfloaterproperties.cpp b/indra/newview/llfloaterproperties.cpp
index 09888ebab0..21ed153920 100644
--- a/indra/newview/llfloaterproperties.cpp
+++ b/indra/newview/llfloaterproperties.cpp
@@ -373,7 +373,7 @@ void LLFloaterProperties::refreshFromItem(LLInventoryItem* item)
//////////////////
// *TODO: Localize / translate this
- time_t time_utc = (time_t)item->getCreationDate();
+ time_t time_utc = item->getCreationDate();
if (0 == time_utc)
{
childSetText("LabelAcquiredDate",getString("unknown"));
diff --git a/indra/newview/llfolderview.cpp b/indra/newview/llfolderview.cpp
index 075ed81a53..c26a8dfc55 100644
--- a/indra/newview/llfolderview.cpp
+++ b/indra/newview/llfolderview.cpp
@@ -283,7 +283,7 @@ void LLFolderViewItem::refresh()
const char* label = mListener->getDisplayName().c_str();
mLabel = label ? label : "";
setIcon(mListener->getIcon());
- U32 creation_date = mListener->getCreationDate();
+ time_t creation_date = mListener->getCreationDate();
if (mCreationDate != creation_date)
{
mCreationDate = mListener->getCreationDate();
@@ -1745,7 +1745,7 @@ void LLFolderViewFolder::sortBy(U32 order)
if (order & LLInventoryFilter::SO_DATE)
{
- U32 latest = 0;
+ time_t latest = 0;
if (!mItems.empty())
{
@@ -2203,9 +2203,9 @@ void LLFolderViewFolder::draw()
mExpanderHighlighted = FALSE;
}
-U32 LLFolderViewFolder::getCreationDate() const
+time_t LLFolderViewFolder::getCreationDate() const
{
- return llmax<U32>(mCreationDate, mSubtreeCreationDate);
+ return llmax<time_t>(mCreationDate, mSubtreeCreationDate);
}
@@ -4400,8 +4400,8 @@ bool LLInventorySort::operator()(LLFolderViewItem* a, LLFolderViewItem* b)
{
// BUG: This is very very slow. The getCreationDate() is log n in number
// of inventory items.
- U32 first_create = a->getCreationDate();
- U32 second_create = b->getCreationDate();
+ time_t first_create = a->getCreationDate();
+ time_t second_create = b->getCreationDate();
if (first_create == second_create)
{
return (LLString::compareDict(a->getLabel(), b->getLabel()) < 0);
@@ -4495,8 +4495,8 @@ LLInventoryFilter::LLInventoryFilter(const LLString& name) :
mNeedTextRebuild(TRUE)
{
mFilterOps.mFilterTypes = 0xffffffff;
- mFilterOps.mMinDate = 0;
- mFilterOps.mMaxDate = U32_MAX;
+ mFilterOps.mMinDate = time_min();
+ mFilterOps.mMaxDate = time_max();
mFilterOps.mHoursAgo = 0;
mFilterOps.mShowFolderState = SHOW_NON_EMPTY_FOLDERS;
mFilterOps.mPermissions = PERM_NONE;
@@ -4524,10 +4524,10 @@ LLInventoryFilter::~LLInventoryFilter()
BOOL LLInventoryFilter::check(LLFolderViewItem* item)
{
- U32 earliest;
+ time_t earliest;
earliest = time_corrected() - mFilterOps.mHoursAgo * 3600;
- if (mFilterOps.mMinDate && mFilterOps.mMinDate < earliest)
+ if (mFilterOps.mMinDate > time_min() && mFilterOps.mMinDate < earliest)
{
earliest = mFilterOps.mMinDate;
}
@@ -4570,8 +4570,8 @@ BOOL LLInventoryFilter::isActive()
return mFilterOps.mFilterTypes != 0xffffffff
|| mFilterSubString.size()
|| mFilterOps.mPermissions != PERM_NONE
- || mFilterOps.mMinDate != 0
- || mFilterOps.mMaxDate != U32_MAX
+ || mFilterOps.mMinDate != time_min()
+ || mFilterOps.mMaxDate != time_max()
|| mFilterOps.mHoursAgo != 0;
}
@@ -4667,7 +4667,7 @@ void LLInventoryFilter::setFilterPermissions(PermissionMask perms)
}
}
-void LLInventoryFilter::setDateRange(U32 min_date, U32 max_date)
+void LLInventoryFilter::setDateRange(time_t min_date, time_t max_date)
{
mFilterOps.mHoursAgo = 0;
if (mFilterOps.mMinDate != min_date)
@@ -4686,19 +4686,20 @@ void LLInventoryFilter::setDateRangeLastLogoff(BOOL sl)
{
if (sl && !isSinceLogoff())
{
- setDateRange(mLastLogoff, U32_MAX);
+ setDateRange(mLastLogoff, time_max());
setModified();
}
if (!sl && isSinceLogoff())
{
- setDateRange(0, U32_MAX);
+ setDateRange(0, time_max());
setModified();
}
}
BOOL LLInventoryFilter::isSinceLogoff()
{
- return (mFilterOps.mMinDate == mLastLogoff) && (mFilterOps.mMaxDate == U32_MAX);
+ return (mFilterOps.mMinDate == mLastLogoff) &&
+ (mFilterOps.mMaxDate == time_max());
}
void LLInventoryFilter::setHoursAgo(U32 hours)
@@ -4706,11 +4707,11 @@ void LLInventoryFilter::setHoursAgo(U32 hours)
if (mFilterOps.mHoursAgo != hours)
{
// *NOTE: need to cache last filter time, in case filter goes stale
- BOOL less_restrictive = (mFilterOps.mMinDate == 0 && mFilterOps.mMaxDate == U32_MAX && hours > mFilterOps.mHoursAgo);
- BOOL more_restrictive = (mFilterOps.mMinDate == 0 && mFilterOps.mMaxDate == U32_MAX && hours <= mFilterOps.mHoursAgo);
+ BOOL less_restrictive = (mFilterOps.mMinDate == time_min() && mFilterOps.mMaxDate == time_max() && hours > mFilterOps.mHoursAgo);
+ BOOL more_restrictive = (mFilterOps.mMinDate == time_min() && mFilterOps.mMaxDate == time_max() && hours <= mFilterOps.mHoursAgo);
mFilterOps.mHoursAgo = hours;
- mFilterOps.mMinDate = 0;
- mFilterOps.mMaxDate = U32_MAX;
+ mFilterOps.mMinDate = time_min();
+ mFilterOps.mMaxDate = time_max();
if (less_restrictive)
{
setModified(FILTER_LESS_RESTRICTIVE);
@@ -5011,7 +5012,7 @@ void LLInventoryFilter::fromLLSD(LLSD& data)
if(data.has("min_date") && data.has("max_date"))
{
- setDateRange((U32)data["min_date"].asInteger(), (U32)data["max_date"].asInteger());
+ setDateRange(data["min_date"].asInteger(), data["max_date"].asInteger());
}
if(data.has("hours_ago"))
diff --git a/indra/newview/llfolderview.h b/indra/newview/llfolderview.h
index f8380fc47e..8a04cc9b9c 100644
--- a/indra/newview/llfolderview.h
+++ b/indra/newview/llfolderview.h
@@ -79,7 +79,7 @@ public:
virtual const LLString& getName() const = 0;
virtual const LLString& getDisplayName() const = 0;
virtual const LLUUID& getUUID() const = 0;
- virtual U32 getCreationDate() const = 0; // UTC seconds
+ virtual time_t getCreationDate() const = 0; // UTC seconds
virtual PermissionMask getPermissionMask() const = 0;
virtual LLUIImagePtr getIcon() const = 0;
virtual LLFontGL::StyleFlags getLabelStyle() const = 0;
@@ -198,10 +198,10 @@ public:
void setFilterPermissions(PermissionMask perms);
PermissionMask getFilterPermissions() const { return mFilterOps.mPermissions; }
- void setDateRange(U32 min_date, U32 max_date);
+ void setDateRange(time_t min_date, time_t max_date);
void setDateRangeLastLogoff(BOOL sl);
- U32 getMinDate() const { return mFilterOps.mMinDate; }
- U32 getMaxDate() const { return mFilterOps.mMaxDate; }
+ time_t getMinDate() const { return mFilterOps.mMinDate; }
+ time_t getMaxDate() const { return mFilterOps.mMaxDate; }
void setHoursAgo(U32 hours);
U32 getHoursAgo() const { return mFilterOps.mHoursAgo; }
@@ -246,8 +246,8 @@ protected:
struct filter_ops
{
U32 mFilterTypes;
- U32 mMinDate;
- U32 mMaxDate;
+ time_t mMinDate;
+ time_t mMaxDate;
U32 mHoursAgo;
EFolderShow mShowFolderState;
PermissionMask mPermissions;
@@ -464,7 +464,7 @@ public:
const char* getLabel() const { return mLabel.c_str(); }
// Used for sorting, like getLabel() above.
- virtual U32 getCreationDate() const { return mCreationDate; }
+ virtual time_t getCreationDate() const { return mCreationDate; }
LLFolderViewFolder* getParentFolder( void ) { return mParentFolder; }
const LLFolderViewFolder* getParentFolder( void ) const { return mParentFolder; }
@@ -555,7 +555,7 @@ protected:
F32 mCurHeight;
F32 mTargetHeight;
F32 mAutoOpenCountdown;
- U32 mSubtreeCreationDate;
+ time_t mSubtreeCreationDate;
ETrash mAmTrash;
S32 mLastArrangeGeneration;
S32 mLastCalculatedWidth;
@@ -702,7 +702,7 @@ public:
LLString& tooltip_msg);
virtual void draw();
- U32 getCreationDate() const;
+ time_t getCreationDate() const;
bool isTrash();
};
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 729165a2a4..e948b64459 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -180,7 +180,7 @@ PermissionMask LLInvFVBridge::getPermissionMask() const
}
// Folders don't have creation dates.
-U32 LLInvFVBridge::getCreationDate() const
+time_t LLInvFVBridge::getCreationDate() const
{
return 0;
}
@@ -894,7 +894,7 @@ LLString LLItemBridge::getLabelSuffix() const
return suffix;
}
-U32 LLItemBridge::getCreationDate() const
+time_t LLItemBridge::getCreationDate() const
{
LLViewerInventoryItem* item = getItem();
if (item)
diff --git a/indra/newview/llinventorybridge.h b/indra/newview/llinventorybridge.h
index 9fbdd09c40..2646dab96c 100644
--- a/indra/newview/llinventorybridge.h
+++ b/indra/newview/llinventorybridge.h
@@ -164,7 +164,7 @@ public:
virtual const LLString& getName() const;
virtual const LLString& getDisplayName() const;
virtual PermissionMask getPermissionMask() const;
- virtual U32 getCreationDate() const;
+ virtual time_t getCreationDate() const;
virtual LLFontGL::StyleFlags getLabelStyle() const
{
return LLFontGL::NORMAL;
@@ -239,7 +239,7 @@ public:
virtual const LLString& getDisplayName() const;
virtual LLString getLabelSuffix() const;
virtual PermissionMask getPermissionMask() const;
- virtual U32 getCreationDate() const;
+ virtual time_t getCreationDate() const;
virtual BOOL isItemRenameable() const;
virtual BOOL renameItem(const LLString& new_name);
virtual BOOL removeItem();
diff --git a/indra/newview/lllogchat.cpp b/indra/newview/lllogchat.cpp
index 91e6ef1e05..76a4ec99b1 100644
--- a/indra/newview/lllogchat.cpp
+++ b/indra/newview/lllogchat.cpp
@@ -47,7 +47,7 @@ LLString LLLogChat::makeLogFileName(LLString filename)
LLString LLLogChat::timestamp(bool withdate)
{
- U32 utc_time;
+ time_t utc_time;
utc_time = time_corrected();
// There's only one internal tm buffer.
diff --git a/indra/newview/llmutelist.cpp b/indra/newview/llmutelist.cpp
index 71c93c3542..e9a5648b7b 100644
--- a/indra/newview/llmutelist.cpp
+++ b/indra/newview/llmutelist.cpp
@@ -445,7 +445,7 @@ void LLMuteList::updateRemove(const LLMute& mute)
void notify_automute_callback(const LLUUID& agent_id, const char* first_name, const char* last_name, BOOL is_group, void* user_data)
{
- U32 temp_data = (U32)user_data;
+ U32 temp_data = (U32) (uintptr_t) user_data;
LLMuteList::EAutoReason reason = (LLMuteList::EAutoReason)temp_data;
LLUIString auto_message;
diff --git a/indra/newview/llpanelgrouplandmoney.cpp b/indra/newview/llpanelgrouplandmoney.cpp
index 4ec8c0763b..fdeb3368e8 100644
--- a/indra/newview/llpanelgrouplandmoney.cpp
+++ b/indra/newview/llpanelgrouplandmoney.cpp
@@ -1229,7 +1229,7 @@ void LLGroupMoneySalesTabEventHandler::processReply(LLMessageSystem* msg,
if (amount != 0)
{
- char* verb;
+ const char* verb;
switch(type)
{
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp
index c493e8f049..724b61481b 100644
--- a/indra/newview/llstartup.cpp
+++ b/indra/newview/llstartup.cpp
@@ -41,8 +41,8 @@
#include "audioengine.h"
-#if LL_FMOD
-#include "audioengine_fmod.h"
+#ifdef LL_FMOD
+# include "audioengine_fmod.h"
#endif
#include "llares.h"
@@ -545,7 +545,7 @@ BOOL idle_startup()
if (FALSE == gSavedSettings.getBOOL("NoAudio"))
{
-#if LL_FMOD
+#ifdef LL_FMOD
gAudiop = (LLAudioEngine *) new LLAudioEngine_FMOD();
#else
gAudiop = NULL;
diff --git a/indra/newview/llstatusbar.cpp b/indra/newview/llstatusbar.cpp
index 6697b06659..0f65510844 100644
--- a/indra/newview/llstatusbar.cpp
+++ b/indra/newview/llstatusbar.cpp
@@ -255,7 +255,7 @@ void LLStatusBar::refresh()
// Get current UTC time, adjusted for the user's clock
// being off.
- U32 utc_time;
+ time_t utc_time;
utc_time = time_corrected();
// There's only one internal tm buffer.
diff --git a/indra/newview/lltexturecache.cpp b/indra/newview/lltexturecache.cpp
index 534d19874c..86ef9e95cf 100644
--- a/indra/newview/lltexturecache.cpp
+++ b/indra/newview/lltexturecache.cpp
@@ -1056,12 +1056,10 @@ struct lru_data
typedef const lru_data* lru_data_ptr;
bool operator()(const lru_data_ptr& a, const lru_data_ptr& b) const
{
- if (a->time > b->time)
- return true;
- else if (b->time > a->time)
- return false;
+ if(a->time == b->time)
+ return (a->index < b->index);
else
- return a->index < b->index;
+ return (a->time >= b->time);
}
};
};
diff --git a/indra/newview/lltooldraganddrop.cpp b/indra/newview/lltooldraganddrop.cpp
index 8574448dce..47ed30a34b 100644
--- a/indra/newview/lltooldraganddrop.cpp
+++ b/indra/newview/lltooldraganddrop.cpp
@@ -1546,7 +1546,7 @@ void LLToolDragAndDrop::dropInventory(LLViewerObject* hit_obj,
}
LLPointer<LLViewerInventoryItem> new_item = new LLViewerInventoryItem(item);
- S32 creation_date = time_corrected();
+ time_t creation_date = time_corrected();
new_item->setCreationDate(creation_date);
if(!item->getPermissions().allowCopyBy(gAgent.getID()))
diff --git a/indra/newview/llurldispatcher.cpp b/indra/newview/llurldispatcher.cpp
index abe0034dc8..f103b9b0bf 100644
--- a/indra/newview/llurldispatcher.cpp
+++ b/indra/newview/llurldispatcher.cpp
@@ -163,11 +163,13 @@ bool LLURLDispatcherImpl::dispatchRightClick(const std::string& url)
// static
bool LLURLDispatcherImpl::dispatchHelp(const std::string& url, BOOL right_mouse)
{
+#if LL_LIBXUL_ENABLED
if (matchPrefix(url, SLURL_SL_HELP_PREFIX))
{
gViewerHtmlHelp.show();
return true;
}
+#endif
return false;
}
diff --git a/indra/newview/llviewerinventory.cpp b/indra/newview/llviewerinventory.cpp
index 097b3b1a9d..a3929de5f3 100644
--- a/indra/newview/llviewerinventory.cpp
+++ b/indra/newview/llviewerinventory.cpp
@@ -68,7 +68,7 @@ LLViewerInventoryItem::LLViewerInventoryItem(const LLUUID& uuid,
const LLString& desc,
const LLSaleInfo& sale_info,
U32 flags,
- S32 creation_date_utc) :
+ time_t creation_date_utc) :
LLInventoryItem(uuid, parent_uuid, perm, asset_uuid, type, inv_type,
name, desc, sale_info, flags, creation_date_utc),
mIsComplete(TRUE)
@@ -290,7 +290,7 @@ bool LLViewerInventoryItem::exportFileLocal(LLFILE* fp) const
const char* inv_type_str = LLInventoryType::lookup(mInventoryType);
if(inv_type_str) fprintf(fp, "\t\tinv_type\t%s\n", inv_type_str);
fprintf(fp, "\t\tname\t%s|\n", mName.c_str());
- fprintf(fp, "\t\tcreation_date\t%d\n", mCreationDate);
+ fprintf(fp, "\t\tcreation_date\t%d\n", (S32) mCreationDate);
fprintf(fp,"\t}\n");
return true;
}
diff --git a/indra/newview/llviewerinventory.h b/indra/newview/llviewerinventory.h
index 30e5afdad1..102239099f 100644
--- a/indra/newview/llviewerinventory.h
+++ b/indra/newview/llviewerinventory.h
@@ -62,7 +62,7 @@ public:
const LLString& desc,
const LLSaleInfo& sale_info,
U32 flags,
- S32 creation_date_utc);
+ time_t creation_date_utc);
// construct a viewer inventory item which has the minimal amount
// of information to use in the UI.
diff --git a/indra/newview/llviewerjoystick.h b/indra/newview/llviewerjoystick.h
index 625debb923..82549cb2dd 100644
--- a/indra/newview/llviewerjoystick.h
+++ b/indra/newview/llviewerjoystick.h
@@ -34,8 +34,6 @@
#include "stdtypes.h"
-#define LIB_NDOF (LL_WINDOWS || LL_DARWIN)
-
#if LIB_NDOF
#include "ndofdev_external.h"
#else
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index fd2a906edd..060b69db74 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -6982,7 +6982,7 @@ void handle_grab_texture(void* data)
PERM_NONE,
PERM_NONE,
next_owner_perm);
- S32 creation_date_now = time_corrected();
+ time_t creation_date_now = time_corrected();
LLPointer<LLViewerInventoryItem> item
= new LLViewerInventoryItem(item_id,
folder_id,
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 391a5ad5cb..477f6c35c1 100644
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -4576,7 +4576,7 @@ void container_inventory_arrived(LLViewerObject* object,
LLInventoryItem* item = (LLInventoryItem*)(obj);
LLUUID item_id;
item_id.generate();
- S32 creation_date_utc = time_corrected();
+ time_t creation_date_utc = time_corrected();
LLPointer<LLViewerInventoryItem> new_item
= new LLViewerInventoryItem(item_id,
cat_id,
@@ -4616,7 +4616,7 @@ void container_inventory_arrived(LLViewerObject* object,
LLUUID item_id;
item_id.generate();
- S32 creation_date_utc = time_corrected();
+ time_t creation_date_utc = time_corrected();
LLPointer<LLViewerInventoryItem> new_item
= new LLViewerInventoryItem(item_id, category,
item->getPermissions(),
diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp
index 632526c061..f5ea73f1fc 100644
--- a/indra/newview/llviewerregion.cpp
+++ b/indra/newview/llviewerregion.cpp
@@ -478,7 +478,7 @@ std::string LLViewerRegion::regionFlagsToString(U32 flags)
}
// *TODO:Translate
-char* SIM_ACCESS_STR[] = { "Free Trial",
+const char* SIM_ACCESS_STR[] = { "Free Trial",
"PG",
"Mature",
"Offline",
@@ -1309,8 +1309,9 @@ class BaseCapabilitiesComplete : public LLHTTPClient::Responder
{
LOG_CLASS(BaseCapabilitiesComplete);
public:
- BaseCapabilitiesComplete(LLViewerRegion* region)
- : mRegion(region)
+ BaseCapabilitiesComplete(LLViewerRegion* region, LLSD requestedCaps)
+ : mRegion(region),
+ mRequestedCaps(requestedCaps)
{ }
void error(U32 statusNum, const std::string& reason)
@@ -1326,8 +1327,16 @@ public:
void result(const LLSD& content)
{
LLSD::map_const_iterator iter;
+
for(iter = content.beginMap(); iter != content.endMap(); ++iter)
{
+ if (iter->second.asString().empty())
+ {
+ llwarns << "BaseCapabilitiesComplete::result EMPTY capability "
+ << iter->first << llendl;
+ continue;
+ }
+
mRegion->setCapability(iter->first, iter->second);
LL_DEBUGS2("AppInit", "Capabilities") << "got capability for "
<< iter->first << LL_ENDL;
@@ -1340,6 +1349,21 @@ public:
}
}
+ LLSD::array_const_iterator fail;
+ for (fail = mRequestedCaps.beginArray();
+ fail != mRequestedCaps.endArray();
+ ++fail)
+ {
+ std::string cap = fail->asString();
+
+ if (mRegion->getCapability(cap).empty() &&
+ !LLViewerRegion::isSpecialCapabilityName(cap))
+ {
+ llwarns << "BaseCapabilitiesComplete::result FAILED to get "
+ << "capability " << cap << llendl;
+ }
+ }
+
if (STATE_SEED_GRANTED_WAIT == LLStartUp::getStartupState())
{
LLStartUp::setStartupState( STATE_SEED_CAP_GRANTED );
@@ -1347,14 +1371,16 @@ public:
}
static boost::intrusive_ptr<BaseCapabilitiesComplete> build(
- LLViewerRegion* region)
+ LLViewerRegion* region,
+ LLSD requestedCaps)
{
return boost::intrusive_ptr<BaseCapabilitiesComplete>(
- new BaseCapabilitiesComplete(region));
+ new BaseCapabilitiesComplete(region, requestedCaps));
}
private:
LLViewerRegion* mRegion;
+ LLSD mRequestedCaps;
};
@@ -1409,7 +1435,8 @@ void LLViewerRegion::setSeedCapability(const std::string& url)
llinfos << "posting to seed " << url << llendl;
- LLHTTPClient::post(url, capabilityNames, BaseCapabilitiesComplete::build(this));
+ LLHTTPClient::post(url, capabilityNames,
+ BaseCapabilitiesComplete::build(this, capabilityNames));
}
void LLViewerRegion::setCapability(const std::string& name, const std::string& url)
@@ -1430,6 +1457,11 @@ void LLViewerRegion::setCapability(const std::string& name, const std::string& u
}
}
+bool LLViewerRegion::isSpecialCapabilityName(const std::string &name)
+{
+ return name == "EventQueueGet" || name == "UntrustedSimulatorMessage";
+}
+
std::string LLViewerRegion::getCapability(const std::string& name) const
{
CapabilityMap::const_iterator iter = mCapabilities.find(name);
diff --git a/indra/newview/llviewerregion.h b/indra/newview/llviewerregion.h
index 6625e3bdf6..dedeb43523 100644
--- a/indra/newview/llviewerregion.h
+++ b/indra/newview/llviewerregion.h
@@ -212,6 +212,7 @@ public:
void setSeedCapability(const std::string& url);
void setCapability(const std::string& name, const std::string& url);
std::string getCapability(const std::string& name) const;
+ static bool isSpecialCapabilityName(const std::string &name);
void logActiveCapabilities() const;
const LLHost &getHost() const { return mHost; }
diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp
index c97c3d6952..ab0ef9df4a 100644
--- a/indra/newview/llviewerstats.cpp
+++ b/indra/newview/llviewerstats.cpp
@@ -56,8 +56,8 @@
#include "llviewerwindow.h" // *TODO: remove, only used for width/height
#include "llworld.h"
#include "llfeaturemanager.h"
-#if LL_WINDOWS && LL_LCD_COMPILE
- #include "lllcd.h"
+#if LL_LCD_COMPILE
+#include "lllcd.h"
#endif
@@ -597,7 +597,7 @@ void update_statistics(U32 frame_count)
LLViewerImageList::sTextureBits = 0;
LLViewerImageList::sTexturePackets = 0;
-#if LL_WINDOWS && LL_LCD_COMPILE
+#if LL_LCD_COMPILE
bool LCDenabled = gLcdScreen->Enabled();
LLViewerStats::getInstance()->setStat(LLViewerStats::ST_LOGITECH_LCD, LCDenabled);
#else
diff --git a/indra/newview/llviewertexteditor.cpp b/indra/newview/llviewertexteditor.cpp
index 771f6615cf..aba7d4dac4 100644
--- a/indra/newview/llviewertexteditor.cpp
+++ b/indra/newview/llviewertexteditor.cpp
@@ -1244,7 +1244,7 @@ LLString LLViewerTextEditor::getEmbeddedText()
LLString LLViewerTextEditor::appendTime(bool prepend_newline)
{
- U32 utc_time;
+ time_t utc_time;
utc_time = time_corrected();
// There's only one internal tm buffer.
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index 5d3487517b..8f675e66e7 100644
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -1491,7 +1491,7 @@ BOOL LLViewerWindow::handleDeviceChange(LLWindow *window)
// Classes
//
LLViewerWindow::LLViewerWindow(
- char* title, char* name,
+ const char* title, const char* name,
S32 x, S32 y,
S32 width, S32 height,
BOOL fullscreen, BOOL ignore_pixel_depth)
diff --git a/indra/newview/llviewerwindow.h b/indra/newview/llviewerwindow.h
index 08b90f05d7..78afaf6cdf 100644
--- a/indra/newview/llviewerwindow.h
+++ b/indra/newview/llviewerwindow.h
@@ -68,7 +68,7 @@ public:
//
// CREATORS
//
- LLViewerWindow(char* title, char* name, S32 x, S32 y, S32 width, S32 height, BOOL fullscreen, BOOL ignore_pixel_depth);
+ LLViewerWindow(const char* title, const char* name, S32 x, S32 y, S32 width, S32 height, BOOL fullscreen, BOOL ignore_pixel_depth);
virtual ~LLViewerWindow();
void initGLDefaults();
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index 8762c4fef8..91c70bd315 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -9030,7 +9030,7 @@ void LLVOAvatar::dumpLocalTextures()
{
llinfos << "Local Textures:" << llendl;
- char* names[] = {
+ const char* names[] = {
"Shirt ",
"UpperTatoo",
"Pants ",
diff --git a/indra/newview/llvoiceclient.cpp b/indra/newview/llvoiceclient.cpp
index 21ba12324c..4d4808cdff 100644
--- a/indra/newview/llvoiceclient.cpp
+++ b/indra/newview/llvoiceclient.cpp
@@ -39,7 +39,11 @@
#include "llvoavatar.h"
#include "llbufferstream.h"
#include "llfile.h"
-#include "expat/expat.h"
+#ifdef LL_STANDALONE
+# include "expat.h"
+#else
+# include "expat/expat.h"
+#endif
#include "llcallbacklist.h"
#include "llviewerregion.h"
#include "llviewernetwork.h" // for gGridChoice
@@ -58,10 +62,10 @@
#include "llviewerwindow.h"
// for base64 decoding
-#include "apr-1/apr_base64.h"
+#include "apr_base64.h"
// for SHA1 hash
-#include "apr-1/apr_sha1.h"
+#include "apr_sha1.h"
// If we are connecting to agni AND the user's last name is "Linden", join this channel instead of looking up the sim name.
// If we are connecting to agni and the user's last name is NOT "Linden", disable voice.
@@ -1265,12 +1269,18 @@ void LLVoiceClient::stateMachine()
if(true)
{
// Launch the voice daemon
- std::string exe_path = gDirUtilp->getAppRODataDir();
+
+ // *FIX:Mani - Using the executable dir instead
+ // of mAppRODataDir, the working directory from which the app
+ // is launched.
+ //std::string exe_path = gDirUtilp->getAppRODataDir();
+ std::string exe_path = gDirUtilp->getExecutableDir();
exe_path += gDirUtilp->getDirDelimiter();
#if LL_WINDOWS
exe_path += "SLVoice.exe";
+#elif LL_DARWIN
+ exe_path += "../Resources/SLVoice";
#else
- // This will be the same for mac and linux
exe_path += "SLVoice";
#endif
// See if the vivox executable exists
@@ -1363,7 +1373,7 @@ void LLVoiceClient::stateMachine()
}
else
{
- LL_INFOS("Voice") << exe_path << "not found." << LL_ENDL
+ LL_INFOS("Voice") << exe_path << "not found." << LL_ENDL;
}
}
else
diff --git a/indra/newview/llwindebug.cpp b/indra/newview/llwindebug.cpp
index ca7c0f26a4..bf6fcd6ccc 100644
--- a/indra/newview/llwindebug.cpp
+++ b/indra/newview/llwindebug.cpp
@@ -31,8 +31,6 @@
#include "llviewerprecompiledheaders.h"
-#ifdef LL_WINDOWS
-
#include <tchar.h>
#include <tlhelp32.h>
#include "llwindebug.h"
@@ -740,5 +738,3 @@ void LLWinDebug::generateCrashStacks(struct _EXCEPTION_POINTERS *exception_infop
LLSDSerialize::toPrettyXML(info, out_file);
out_file.close();
}
-
-#endif
diff --git a/indra/newview/res/resource.h b/indra/newview/res/resource.h
index 4f2e88f7f2..2268e81e83 100644
--- a/indra/newview/res/resource.h
+++ b/indra/newview/res/resource.h
@@ -30,7 +30,7 @@
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
-// Used by newViewRes.rc
+// Used by viewerRes.rc
//
#define IDREMOVE 3
#define IDI_LL_ICON 103
diff --git a/indra/newview/res/viewerRes.rc b/indra/newview/res/viewerRes.rc
new file mode 100644
index 0000000000..20a572c8e0
--- /dev/null
+++ b/indra/newview/res/viewerRes.rc
@@ -0,0 +1,288 @@
+// Microsoft Visual C++ generated resource script.
+//
+#include "resource.h"
+
+#ifdef IDC_STATIC
+#undef IDC_STATIC
+#endif
+#define IDC_STATIC (-1)
+#include "winresrc.h"
+
+#define APSTUDIO_READONLY_SYMBOLS
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 2 resource.
+//
+// Commented out because it only compiles if you have MFC installed.
+//#include "winres.h"
+
+/////////////////////////////////////////////////////////////////////////////
+#undef APSTUDIO_READONLY_SYMBOLS
+
+/////////////////////////////////////////////////////////////////////////////
+// English (U.S.) resources
+
+#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
+#ifdef _WIN32
+LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
+#pragma code_page(1252)
+#endif //_WIN32
+
+#ifdef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// TEXTINCLUDE
+//
+
+1 TEXTINCLUDE
+BEGIN
+ "resource.h\0"
+END
+
+2 TEXTINCLUDE
+BEGIN
+ "#include ""winres.h""\r\n"
+ "\0"
+END
+
+3 TEXTINCLUDE
+BEGIN
+ "\r\n"
+ "\0"
+END
+
+#endif // APSTUDIO_INVOKED
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Icon
+//
+
+// Icon with lowest ID value placed first to ensure application icon
+// remains consistent on all systems.
+IDI_LL_ICON ICON "ll_icon.ico"
+IDI_INSTALL_ICON ICON "install_icon.ico"
+IDI_LCD_LL_ICON ICON "icon1.ico"
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Dialog
+//
+
+CONNECTBOX DIALOGEX 32, 32, 187, 246
+STYLE DS_SETFONT | DS_SETFOREGROUND | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP |
+ WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+FONT 8, "MS Sans Serif", 0, 0, 0x0
+BEGIN
+ CONTROL 149,IDC_STATIC,"Static",SS_BITMAP,0,0,187,246
+ EDITTEXT IDC_EDIT_FIRSTNAME,9,180,80,13,ES_AUTOHSCROLL
+ EDITTEXT IDC_EDIT_LASTNAME,98,180,80,13,ES_AUTOHSCROLL
+ EDITTEXT IDC_EDIT_PASSWORD,9,210,80,13,ES_PASSWORD |
+ ES_AUTOHSCROLL
+ CONTROL "Remember password",IDC_REMEMBER_PASSWORD,"Button",
+ BS_AUTOCHECKBOX | WS_TABSTOP,9,229,80,10
+ DEFPUSHBUTTON "Connect...",IDOK,98,210,80,13
+ CONTROL "Full screen",IDC_FULL_SCREEN,"Button",BS_AUTOCHECKBOX |
+ WS_TABSTOP,100,229,50,10
+ COMBOBOX IDC_COMBO_SERVER,98,6,84,30,CBS_DROPDOWNLIST | CBS_SORT |
+ WS_VSCROLL | WS_TABSTOP
+END
+
+CONNECTBOXIP DIALOG 32, 32, 282, 174
+STYLE DS_SETFONT | DS_MODALFRAME | DS_SETFOREGROUND | DS_CENTER | WS_POPUP |
+ WS_VISIBLE
+FONT 8, "MS Sans Serif"
+BEGIN
+ LTEXT "First name:",IDC_STATIC_FIRSTNAME,152,24,36,10,NOT
+ WS_GROUP
+ EDITTEXT IDC_EDIT_FIRSTNAME,152,37,58,13,ES_AUTOHSCROLL
+ LTEXT "Last name:",IDC_STATIC_LASTNAME,218,24,38,10,NOT
+ WS_GROUP
+ EDITTEXT IDC_EDIT_LASTNAME,218,37,57,13,ES_AUTOHSCROLL
+ LTEXT "Password:",IDC_STATIC_PASSWORD,152,55,38,10
+ EDITTEXT IDC_EDIT_PASSWORD,152,71,123,13,ES_PASSWORD |
+ ES_AUTOHSCROLL
+ CONTROL "Remember password for next time",IDC_REMEMBER_PASSWORD,
+ "Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,84,123,10
+ LTEXT "Return to:",IDC_STATIC,152,97,32,8
+ CONTROL "Last location",IDC_RADIO_LAST,"Button",
+ BS_AUTORADIOBUTTON | WS_TABSTOP,152,109,56,10
+ CONTROL "Home",IDC_RADIO_HOME,"Button",BS_AUTORADIOBUTTON |
+ WS_TABSTOP,218,109,35,10
+ LTEXT "Server:",IDC_STATIC_SERVER,152,119,38,10,NOT WS_GROUP
+ COMBOBOX IDC_COMBO_SERVER,152,134,88,43,CBS_DROPDOWN | WS_VSCROLL |
+ WS_TABSTOP
+ PUSHBUTTON "Quit",IDCANCEL,152,152,50,14
+ DEFPUSHBUTTON "Connect...",IDOK,225,152,50,14
+ CONTROL 140,IDB_BITMAP1,"Static",SS_BITMAP,8,7,133,157
+ LTEXT "Connect to Second Life",IDC_STATIC,152,7,78,8
+END
+
+SPLASHSCREEN DIALOG 32, 32, 144, 34
+STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE
+FONT 8, "MS Sans Serif"
+BEGIN
+ ICON IDI_LL_ICON,IDC_STATIC,7,7,20,20
+ LTEXT "Loading Second Life...",666,36,13,91,8
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// DESIGNINFO
+//
+
+#ifdef APSTUDIO_INVOKED
+GUIDELINES DESIGNINFO
+BEGIN
+ "CONNECTBOX", DIALOG
+ BEGIN
+ LEFTMARGIN, 8
+ RIGHTMARGIN, 180
+ VERTGUIDE, 152
+ TOPMARGIN, 7
+ BOTTOMMARGIN, 239
+ HORZGUIDE, 44
+ HORZGUIDE, 57
+ HORZGUIDE, 123
+ END
+
+ "CONNECTBOXIP", DIALOG
+ BEGIN
+ LEFTMARGIN, 7
+ RIGHTMARGIN, 275
+ VERTGUIDE, 152
+ VERTGUIDE, 218
+ TOPMARGIN, 7
+ BOTTOMMARGIN, 166
+ HORZGUIDE, 12
+ HORZGUIDE, 17
+ HORZGUIDE, 24
+ HORZGUIDE, 50
+ HORZGUIDE, 55
+ HORZGUIDE, 84
+ HORZGUIDE, 105
+ HORZGUIDE, 119
+ END
+
+ "SPLASHSCREEN", DIALOG
+ BEGIN
+ LEFTMARGIN, 7
+ RIGHTMARGIN, 137
+ VERTGUIDE, 36
+ TOPMARGIN, 7
+ BOTTOMMARGIN, 27
+ END
+END
+#endif // APSTUDIO_INVOKED
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Menu
+//
+
+IDR_MENU1 MENU
+BEGIN
+ POPUP "testmenu"
+ BEGIN
+ MENUITEM "test", ID_TESTMENU_TEST
+ END
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Cursor
+//
+
+TOOLGRAB CURSOR "lltoolgrab.cur"
+TOOLLAND CURSOR "lltoolland.cur"
+TOOLZOOMIN CURSOR "lltoolzoomin.cur"
+TOOLCREATE CURSOR "lltoolcreate.cur"
+ARROWDRAG CURSOR "llarrowdrag.cur"
+ARROW CURSOR "llarrow.cur"
+NOLOCKED CURSOR "llnolocked.cur"
+ARROWLOCKED CURSOR "llarrowlocked.cur"
+GRABLOCKED CURSOR "llgrablocked.cur"
+TOOLROTATE CURSOR "lltoolrotate.cur"
+TOOLTRANSLATE CURSOR "lltooltranslate.cur"
+TOOLSCALE CURSOR "lltoolscale.cur"
+TOOLCAMERA CURSOR "lltoolcamera.cur"
+TOOLPAN CURSOR "lltoolpan.cur"
+TOOLFOCUS CURSOR "lltoolfocus.cur"
+TOOLPICKOBJECT3 CURSOR "toolpickobject3.cur"
+ARROWCOPY CURSOR "arrowcop.cur"
+ARROWDRAGMULTI CURSOR "llarrowdragmulti.cur"
+ARROWCOPYMULTI CURSOR "arrowcopmulti.cur"
+TOOLSIT CURSOR "toolsit.cur"
+TOOLBUY CURSOR "toolbuy.cur"
+TOOLPAY CURSOR "toolpay.cur"
+TOOLOPEN CURSOR "toolopen.cur"
+TOOLPIPETTE CURSOR "toolpipette.cur"
+TOOLPLAY CURSOR "toolplay.cur"
+TOOLPAUSE CURSOR "toolpause.cur"
+TOOLMEDIAOPEN CURSOR "toolmediaopen.cur"
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Version
+//
+
+VS_VERSION_INFO VERSIONINFO
+ FILEVERSION 1,19,1,83014
+ PRODUCTVERSION 1,19,1,83014
+ FILEFLAGSMASK 0x3fL
+#ifdef _DEBUG
+ FILEFLAGS 0x1L
+#else
+ FILEFLAGS 0x0L
+#endif
+ FILEOS 0x40004L
+ FILETYPE 0x1L
+ FILESUBTYPE 0x0L
+BEGIN
+ BLOCK "StringFileInfo"
+ BEGIN
+ BLOCK "040904b0"
+ BEGIN
+ VALUE "CompanyName", "Linden Lab"
+ VALUE "FileDescription", "Second Life"
+ VALUE "FileVersion", "1.19.1.83014"
+ VALUE "InternalName", "Second Life"
+ VALUE "LegalCopyright", "Copyright © 2001-2008, Linden Research, Inc."
+ VALUE "OriginalFilename", "SecondLife.exe"
+ VALUE "ProductName", "Second Life"
+ VALUE "ProductVersion", "1.19.1.83014"
+ END
+ END
+ BLOCK "VarFileInfo"
+ BEGIN
+ VALUE "Translation", 0x409, 1200
+ END
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Bitmap
+//
+
+IDB_BITMAP2 BITMAP "bitmap2.bmp"
+IDB_LOGIN BITMAP "loginbackground.bmp"
+#endif // English (U.S.) resources
+/////////////////////////////////////////////////////////////////////////////
+
+
+
+#ifndef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 3 resource.
+//
+
+
+/////////////////////////////////////////////////////////////////////////////
+#endif // not APSTUDIO_INVOKED
+
diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py
index 5d3658b96c..248dda83fb 100755
--- a/indra/newview/viewer_manifest.py
+++ b/indra/newview/viewer_manifest.py
@@ -6,7 +6,7 @@
#
# $LicenseInfo:firstyear=2006&license=viewergpl$
#
-# Copyright (c) 2006-2007, Linden Research, Inc.
+# Copyright (c) 2006-2008, Linden Research, Inc.
#
# Second Life Viewer Source Code
# The source code in this file ("Source Code") is provided by Linden Lab
@@ -14,12 +14,12 @@
# ("GPL"), unless you have obtained a separate licensing agreement
# ("Other License"), formally executed by you and Linden Lab. Terms of
# the GPL can be found in doc/GPL-license.txt in this distribution, or
-# online at http://secondlife.com/developers/opensource/gplv2
+# 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://secondlife.com/developers/opensource/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,
@@ -39,435 +39,476 @@ sys.path.append(os.path.join(viewer_dir, '../lib/python/indra/util'))
from llmanifest import LLManifest, main, proper_windows_path, path_ancestors
class ViewerManifest(LLManifest):
- def construct(self):
- super(ViewerManifest, self).construct()
- self.exclude("*.svn*")
- self.path(src="../../scripts/messages/message_template.msg", dst="app_settings/message_template.msg")
- self.path(src="../../etc/message.xml", dst="app_settings/message.xml")
-
- if self.prefix(src="app_settings"):
- self.exclude("logcontrol.xml")
- self.exclude("logcontrol-dev.xml")
- self.path("*.pem")
- self.path("*.ini")
- self.path("*.xml")
- self.path("*.vp")
- self.path("*.db2")
-
- # include the entire shaders directory recursively
- self.path("shaders")
- # ... and the entire windlight directory
- self.path("windlight")
- self.end_prefix("app_settings")
-
- if self.prefix(src="character"):
- self.path("*.llm")
- self.path("*.xml")
- self.path("*.tga")
- self.end_prefix("character")
-
-
- # Include our fonts
- if self.prefix(src="fonts"):
- self.path("*.ttf")
- self.path("*.txt")
- self.end_prefix("fonts")
-
- # XUI
- if self.prefix(src="skins"):
- # include the entire textures directory recursively
- self.path("textures")
- self.path("paths.xml")
- self.path("xui/*/*.xml")
- self.path('words.*.txt')
-
- # Local HTML files (e.g. loading screen)
- if self.prefix(src="html"):
- self.path("*.png")
- self.path("*/*/*.html")
- self.path("*/*/*.gif")
- self.end_prefix("html")
- self.end_prefix("skins")
-
- self.path("releasenotes.txt")
- self.path("lsl_guide.html")
- self.path("gpu_table.txt")
-
- def login_channel(self):
- """Channel reported for login and upgrade purposes ONLY; used for A/B testing"""
- # NOTE: Do not return the normal channel if login_channel is not specified, as
- # some code may branch depending on whether or not this is present
- return self.args.get('login_channel')
-
- def channel(self):
- return self.args['channel']
- def channel_unique(self):
- return self.channel().replace("Second Life", "").strip()
- def channel_oneword(self):
- return "".join(self.channel_unique().split())
- def channel_lowerword(self):
- return self.channel_oneword().lower()
-
- def flags_list(self):
- """ Convenience function that returns the command-line flags for the grid"""
- channel_flags = ''
- grid_flags = ''
- if not self.default_grid():
- if self.default_channel():
- # beta grid viewer
- channel_flags = '--settings settings_beta.xml'
- grid_flags = "--grid %(grid)s --helperuri http://preview-%(grid)s.secondlife.com/helpers/" % {'grid':self.args['grid']}
-
- if not self.default_channel():
- # some channel on some grid
- channel_flags = '--settings settings_%s.xml --channel "%s"' % (self.channel_lowerword(), self.channel())
- elif self.login_channel():
- # Report a special channel during login, but use default channel elsewhere
- channel_flags = '--channel "%s"' % (self.login_channel())
+ def construct(self):
+ super(ViewerManifest, self).construct()
+ self.exclude("*.svn*")
+ self.path(src="../../scripts/messages/message_template.msg", dst="app_settings/message_template.msg")
+ self.path(src="../../etc/message.xml", dst="app_settings/message.xml")
+
+ if self.prefix(src="app_settings"):
+ self.exclude("logcontrol.xml")
+ self.exclude("logcontrol-dev.xml")
+ self.path("*.pem")
+ self.path("*.ini")
+ self.path("*.xml")
+ self.path("*.vp")
+ self.path("*.db2")
+
+ # include the entire shaders directory recursively
+ self.path("shaders")
+ # ... and the entire windlight directory
+ self.path("windlight")
+ self.end_prefix("app_settings")
+
+ if self.prefix(src="character"):
+ self.path("*.llm")
+ self.path("*.xml")
+ self.path("*.tga")
+ self.end_prefix("character")
+
+
+ # Include our fonts
+ if self.prefix(src="fonts"):
+ self.path("*.ttf")
+ self.path("*.txt")
+ self.end_prefix("fonts")
+
+ # XUI
+ if self.prefix(src="skins"):
+ # include the entire textures directory recursively
+ self.path("textures")
+ self.path("paths.xml")
+ self.path("xui/*/*.xml")
+ self.path('words.*.txt')
+
+ # Local HTML files (e.g. loading screen)
+ if self.prefix(src="html"):
+ self.path("*.png")
+ self.path("*/*/*.html")
+ self.path("*/*/*.gif")
+ self.end_prefix("html")
+ self.end_prefix("skins")
+
+ self.path("releasenotes.txt")
+ self.path("lsl_guide.html")
+ self.path("gpu_table.txt")
+
+ def login_channel(self):
+ """Channel reported for login and upgrade purposes ONLY;
+ used for A/B testing"""
+ # NOTE: Do not return the normal channel if login_channel
+ # is not specified, as some code may branch depending on
+ # whether or not this is present
+ return self.args.get('login_channel')
+
+ def channel(self):
+ return self.args['channel']
+ def channel_unique(self):
+ return self.channel().replace("Second Life", "").strip()
+ def channel_oneword(self):
+ return "".join(self.channel_unique().split())
+ def channel_lowerword(self):
+ return self.channel_oneword().lower()
+
+ def flags_list(self):
+ """ Convenience function that returns the command-line flags
+ for the grid"""
+ channel_flags = ''
+ grid_flags = ''
+ if not self.default_grid():
+ if self.default_channel():
+ # beta grid viewer
+ channel_flags = '--settings settings_beta.xml'
+ grid_flags = "--grid %(grid)s --helperuri http://preview-%(grid)s.secondlife.com/helpers/" % {'grid':self.args['grid']}
+
+ if not self.default_channel():
+ # some channel on some grid
+ channel_flags = '--settings settings_%s.xml --channel "%s"' % (self.channel_lowerword(), self.channel())
+ elif self.login_channel():
+ # Report a special channel during login, but use default
+ channel_flags = '--channel "%s"' % (self.login_channel())
- return " ".join((channel_flags, grid_flags)).strip()
+ return " ".join((channel_flags, grid_flags)).strip()
class WindowsManifest(ViewerManifest):
- def final_exe(self):
- if self.default_channel():
- if self.default_grid():
- return "SecondLife.exe"
- else:
- return "SecondLifePreview.exe"
- else:
- return ''.join(self.channel().split()) + '.exe'
-
-
- def construct(self):
- super(WindowsManifest, self).construct()
- # the final exe is complicated because we're not sure where it's coming from,
- # nor do we have a fixed name for the executable
- self.path(self.find_existing_file('ReleaseForDownload/Secondlife.exe', 'Secondlife.exe', 'ReleaseNoOpt/newview_noopt.exe'), dst=self.final_exe())
- # need to get the kdu dll from any of the build directories as well
- self.path(self.find_existing_file('ReleaseForDownload/llkdu.dll', 'llkdu.dll', '../../libraries/i686-win32/lib_release/llkdu.dll'), dst='llkdu.dll')
- self.path(src="licenses-win32.txt", dst="licenses.txt")
-
- self.path("featuretable.txt")
-
- # For use in crash reporting (generates minidumps)
- self.path("dbghelp.dll")
-
- # For using FMOD for sound... DJS
- self.path("fmod.dll")
-
- # For textures
- if self.prefix(src="../../libraries/i686-win32/lib_release", dst=""):
- self.path("openjpeg.dll")
- self.end_prefix()
-
- # Mozilla appears to force a dependency on these files so we need to ship it (CP)
- self.path("msvcr71.dll")
- self.path("msvcp71.dll")
-
- # Mozilla runtime DLLs (CP)
- if self.prefix(src="../../libraries/i686-win32/lib_release", dst=""):
- self.path("freebl3.dll")
- self.path("gksvggdiplus.dll")
- self.path("js3250.dll")
- self.path("nspr4.dll")
- self.path("nss3.dll")
- self.path("nssckbi.dll")
- self.path("plc4.dll")
- self.path("plds4.dll")
- self.path("smime3.dll")
- self.path("softokn3.dll")
- self.path("ssl3.dll")
- self.path("xpcom.dll")
- self.path("xul.dll")
- self.end_prefix()
-
- # Mozilla runtime misc files (CP)
- if self.prefix(src="app_settings/mozilla"):
- self.path("chrome/*.*")
- self.path("components/*.*")
- self.path("greprefs/*.*")
- self.path("plugins/*.*")
- self.path("res/*.*")
- self.path("res/*/*")
- self.end_prefix()
-
- # Vivox runtimes
- if self.prefix(src="vivox-runtime/i686-win32", dst=""):
- self.path("SLVoice.exe")
- self.path("SLVoiceAgent.exe")
- self.path("libeay32.dll")
- self.path("srtp.dll")
- self.path("ssleay32.dll")
- self.path("tntk.dll")
- self.path("alut.dll")
- self.path("vivoxsdk.dll")
- self.path("ortp.dll")
- self.path("wrap_oal.dll")
- self.end_prefix()
-
- # pull in the crash logger and updater from other projects
- self.path(src="../win_crash_logger/win_crash_logger.exe", dst="win_crash_logger.exe")
- self.path(src="../win_updater/updater.exe", dst="updater.exe")
-
- def nsi_file_commands(self, install=True):
- def wpath(path):
- if(path.endswith('/') or path.endswith(os.path.sep)):
- path = path[:-1]
- path = path.replace('/', '\\')
- return path
-
- result = ""
- dest_files = [pair[1] for pair in self.file_list if pair[0] and os.path.isfile(pair[1])]
- # sort deepest hierarchy first
- dest_files.sort(lambda a,b: cmp(a.count(os.path.sep),b.count(os.path.sep)) or cmp(a,b))
- dest_files.reverse()
- out_path = None
- for pkg_file in dest_files:
- rel_file = os.path.normpath(pkg_file.replace(self.get_dst_prefix()+os.path.sep,''))
- installed_dir = wpath(os.path.join('$INSTDIR', os.path.dirname(rel_file)))
- pkg_file = wpath(os.path.normpath(pkg_file))
- if installed_dir != out_path:
- if(install):
- out_path = installed_dir
- result += 'SetOutPath ' + out_path + '\n'
- if(install):
- result += 'File ' + pkg_file + '\n'
- else:
- result += 'Delete ' + wpath(os.path.join('$INSTDIR', rel_file)) + '\n'
- # at the end of a delete, just rmdir all the directories
- if(not install):
- deleted_file_dirs = [os.path.dirname(pair[1].replace(self.get_dst_prefix()+os.path.sep,'')) for pair in self.file_list]
- # find all ancestors so that we don't skip any dirs that happened to have no non-dir children
- deleted_dirs = []
- for d in deleted_file_dirs:
- deleted_dirs.extend(path_ancestors(d))
- # sort deepest hierarchy first
- deleted_dirs.sort(lambda a,b: cmp(a.count(os.path.sep),b.count(os.path.sep)) or cmp(a,b))
- deleted_dirs.reverse()
- prev = None
- for d in deleted_dirs:
- if d != prev: # skip duplicates
- result += 'RMDir ' + wpath(os.path.join('$INSTDIR', os.path.normpath(d))) + '\n'
- prev = d
-
- return result
-
- def package_finish(self):
- # a standard map of strings for replacing in the templates
- substitution_strings = {
- 'version' : '.'.join(self.args['version']),
- 'version_short' : '.'.join(self.args['version'][:-1]),
- 'version_dashes' : '-'.join(self.args['version']),
- 'final_exe' : self.final_exe(),
- 'grid':self.args['grid'],
- 'grid_caps':self.args['grid'].upper(),
- # escape quotes becase NSIS doesn't handle them well
- 'flags':self.flags_list().replace('"', '$\\"'),
- 'channel':self.channel(),
- 'channel_oneword':self.channel_oneword(),
- 'channel_unique':self.channel_unique(),
- }
-
- version_vars = """
- !define INSTEXE "%(final_exe)s"
- !define VERSION "%(version_short)s"
- !define VERSION_LONG "%(version)s"
- !define VERSION_DASHES "%(version_dashes)s"
- """ % substitution_strings
- if self.default_channel():
- if self.default_grid():
- # release viewer
- installer_file = "Second_Life_%(version_dashes)s_Setup.exe"
- grid_vars_template = """
- OutFile "%(installer_file)s"
- !define INSTFLAGS "%(flags)s"
- !define INSTNAME "SecondLife"
- !define SHORTCUT "Second Life"
- !define URLNAME "secondlife"
- Caption "Second Life ${VERSION}"
- """
- else:
- # beta grid viewer
- installer_file = "Second_Life_%(version_dashes)s_(%(grid_caps)s)_Setup.exe"
- grid_vars_template = """
- OutFile "%(installer_file)s"
- !define INSTFLAGS "%(flags)s"
- !define INSTNAME "SecondLife%(grid_caps)s"
- !define SHORTCUT "Second Life (%(grid_caps)s)"
- !define URLNAME "secondlife%(grid)s"
- !define UNINSTALL_SETTINGS 1
- Caption "Second Life %(grid)s ${VERSION}"
- """
- else:
- # some other channel on some grid
- installer_file = "Second_Life_%(version_dashes)s_%(channel_oneword)s_Setup.exe"
- grid_vars_template = """
- OutFile "%(installer_file)s"
- !define INSTFLAGS "%(flags)s"
- !define INSTNAME "SecondLife%(channel_oneword)s"
- !define SHORTCUT "%(channel)s"
- !define URLNAME "secondlife"
- !define UNINSTALL_SETTINGS 1
- Caption "%(channel)s ${VERSION}"
- """
- if(self.args.has_key('installer_name')):
- installer_file = self.args['installer_name']
- else:
- installer_file = installer_file % substitution_strings
- substitution_strings['installer_file'] = installer_file
-
- tempfile = "../secondlife_setup_tmp.nsi"
- # the following replaces strings in the nsi template
- # it also does python-style % substitution
- self.replace_in("installers/windows/installer_template.nsi", tempfile, {
- "%%VERSION%%":version_vars,
- "%%GRID_VARS%%":grid_vars_template % substitution_strings,
- "%%INSTALL_FILES%%":self.nsi_file_commands(True),
- "%%DELETE_FILES%%":self.nsi_file_commands(False)})
-
- NSIS_path = 'C:\\Program Files\\NSIS\\makensis.exe'
- self.run_command('"' + proper_windows_path(NSIS_path) + '" ' + self.dst_path_of(tempfile))
- # self.remove(self.dst_path_of(tempfile))
- self.created_path(installer_file)
+ def final_exe(self):
+ if self.default_channel():
+ if self.default_grid():
+ return "SecondLife.exe"
+ else:
+ return "SecondLifePreview.exe"
+ else:
+ return ''.join(self.channel().split()) + '.exe'
+
+
+ def construct(self):
+ super(WindowsManifest, self).construct()
+ # the final exe is complicated because we're not sure where it's coming from,
+ # nor do we have a fixed name for the executable
+ self.path(self.find_existing_file('debug/secondlife-bin.exe', 'release/secondlife-bin.exe', 'relwithdebinfo/secondlife-bin.exe'), dst=self.final_exe())
+ # need to get the kdu dll from any of the build directories as well
+ self.path(self.find_existing_file(
+ # *FIX:Mani we need to add support for packaging specific targets.
+ #'../llkdu/debug/llkdu.dll',
+ '../llkdu/release/llkdu.dll',
+ '../llkdu/relwithdebinfo/llkdu.dll',
+ '../../libraries/i686-win32/lib/release/llkdu.dll'),
+ dst='llkdu.dll')
+ self.path(src="licenses-win32.txt", dst="licenses.txt")
+
+ self.path("featuretable.txt")
+
+ # For use in crash reporting (generates minidumps)
+ self.path("dbghelp.dll")
+
+ # For using FMOD for sound... DJS
+ self.path("fmod.dll")
+
+ # For textures
+ if self.prefix(src="../../libraries/i686-win32/lib/release", dst=""):
+ self.path("openjpeg.dll")
+ self.end_prefix()
+
+ # Mozilla appears to force a dependency on these files so we need to ship it (CP)
+ self.path("msvcr71.dll")
+ self.path("msvcp71.dll")
+
+ # Mozilla runtime DLLs (CP)
+ if self.prefix(src="../../libraries/i686-win32/lib/release", dst=""):
+ self.path("freebl3.dll")
+ self.path("gksvggdiplus.dll")
+ self.path("js3250.dll")
+ self.path("nspr4.dll")
+ self.path("nss3.dll")
+ self.path("nssckbi.dll")
+ self.path("plc4.dll")
+ self.path("plds4.dll")
+ self.path("smime3.dll")
+ self.path("softokn3.dll")
+ self.path("ssl3.dll")
+ self.path("xpcom.dll")
+ self.path("xul.dll")
+ self.end_prefix()
+
+ # Mozilla runtime misc files (CP)
+ if self.prefix(src="app_settings/mozilla"):
+ self.path("chrome/*.*")
+ self.path("components/*.*")
+ self.path("greprefs/*.*")
+ self.path("plugins/*.*")
+ self.path("res/*.*")
+ self.path("res/*/*")
+ self.end_prefix()
+
+ # Vivox runtimes
+ if self.prefix(src="vivox-runtime/i686-win32", dst=""):
+ self.path("SLVoice.exe")
+ self.path("SLVoiceAgent.exe")
+ self.path("libeay32.dll")
+ self.path("srtp.dll")
+ self.path("ssleay32.dll")
+ self.path("tntk.dll")
+ self.path("alut.dll")
+ self.path("vivoxsdk.dll")
+ self.path("ortp.dll")
+ self.path("wrap_oal.dll")
+ self.end_prefix()
+
+ # pull in the crash logger and updater from other projects
+ self.path(src=self.find_existing_file(
+ "../win_crash_logger/debug/windows-crash-logger.exe",
+ "../win_crash_logger/release/windows-crash-logger.exe",
+ "../win_crash_logger/relwithdebinfo/windows-crash-logger.exe"),
+ dst="win_crash_logger.exe")
+ self.path(src=self.find_existing_file(
+ "../win_updater/debug/windows-updater.exe",
+ "../win_updater/release/windows-updater.exe",
+ "../win_updater/relwithdebinfo/windows-updater.exe"),
+ dst="updater.exe")
+
+ def nsi_file_commands(self, install=True):
+ def wpath(path):
+ if path.endswith('/') or path.endswith(os.path.sep):
+ path = path[:-1]
+ path = path.replace('/', '\\')
+ return path
+
+ result = ""
+ dest_files = [pair[1] for pair in self.file_list if pair[0] and os.path.isfile(pair[1])]
+ # sort deepest hierarchy first
+ dest_files.sort(lambda a,b: cmp(a.count(os.path.sep),b.count(os.path.sep)) or cmp(a,b))
+ dest_files.reverse()
+ out_path = None
+ for pkg_file in dest_files:
+ rel_file = os.path.normpath(pkg_file.replace(self.get_dst_prefix()+os.path.sep,''))
+ installed_dir = wpath(os.path.join('$INSTDIR', os.path.dirname(rel_file)))
+ pkg_file = wpath(os.path.normpath(pkg_file))
+ if installed_dir != out_path:
+ if install:
+ out_path = installed_dir
+ result += 'SetOutPath ' + out_path + '\n'
+ if install:
+ result += 'File ' + pkg_file + '\n'
+ else:
+ result += 'Delete ' + wpath(os.path.join('$INSTDIR', rel_file)) + '\n'
+ # at the end of a delete, just rmdir all the directories
+ if not install:
+ deleted_file_dirs = [os.path.dirname(pair[1].replace(self.get_dst_prefix()+os.path.sep,'')) for pair in self.file_list]
+ # find all ancestors so that we don't skip any dirs that happened to have no non-dir children
+ deleted_dirs = []
+ for d in deleted_file_dirs:
+ deleted_dirs.extend(path_ancestors(d))
+ # sort deepest hierarchy first
+ deleted_dirs.sort(lambda a,b: cmp(a.count(os.path.sep),b.count(os.path.sep)) or cmp(a,b))
+ deleted_dirs.reverse()
+ prev = None
+ for d in deleted_dirs:
+ if d != prev: # skip duplicates
+ result += 'RMDir ' + wpath(os.path.join('$INSTDIR', os.path.normpath(d))) + '\n'
+ prev = d
+
+ return result
+
+ def package_finish(self):
+ # a standard map of strings for replacing in the templates
+ substitution_strings = {
+ 'version' : '.'.join(self.args['version']),
+ 'version_short' : '.'.join(self.args['version'][:-1]),
+ 'version_dashes' : '-'.join(self.args['version']),
+ 'final_exe' : self.final_exe(),
+ 'grid':self.args['grid'],
+ 'grid_caps':self.args['grid'].upper(),
+ # escape quotes becase NSIS doesn't handle them well
+ 'flags':self.flags_list().replace('"', '$\\"'),
+ 'channel':self.channel(),
+ 'channel_oneword':self.channel_oneword(),
+ 'channel_unique':self.channel_unique(),
+ }
+
+ version_vars = """
+ !define INSTEXE "%(final_exe)s"
+ !define VERSION "%(version_short)s"
+ !define VERSION_LONG "%(version)s"
+ !define VERSION_DASHES "%(version_dashes)s"
+ """ % substitution_strings
+ if self.default_channel():
+ if self.default_grid():
+ # release viewer
+ installer_file = "Second_Life_%(version_dashes)s_Setup.exe"
+ grid_vars_template = """
+ OutFile "%(installer_file)s"
+ !define INSTFLAGS "%(flags)s"
+ !define INSTNAME "SecondLife"
+ !define SHORTCUT "Second Life"
+ !define URLNAME "secondlife"
+ Caption "Second Life ${VERSION}"
+ """
+ else:
+ # beta grid viewer
+ installer_file = "Second_Life_%(version_dashes)s_(%(grid_caps)s)_Setup.exe"
+ grid_vars_template = """
+ OutFile "%(installer_file)s"
+ !define INSTFLAGS "%(flags)s"
+ !define INSTNAME "SecondLife%(grid_caps)s"
+ !define SHORTCUT "Second Life (%(grid_caps)s)"
+ !define URLNAME "secondlife%(grid)s"
+ !define UNINSTALL_SETTINGS 1
+ Caption "Second Life %(grid)s ${VERSION}"
+ """
+ else:
+ # some other channel on some grid
+ installer_file = "Second_Life_%(version_dashes)s_%(channel_oneword)s_Setup.exe"
+ grid_vars_template = """
+ OutFile "%(installer_file)s"
+ !define INSTFLAGS "%(flags)s"
+ !define INSTNAME "SecondLife%(channel_oneword)s"
+ !define SHORTCUT "%(channel)s"
+ !define URLNAME "secondlife"
+ !define UNINSTALL_SETTINGS 1
+ Caption "%(channel)s ${VERSION}"
+ """
+ if 'installer_name' in self.args:
+ installer_file = self.args['installer_name']
+ else:
+ installer_file = installer_file % substitution_strings
+ substitution_strings['installer_file'] = installer_file
+
+ tempfile = "secondlife_setup_tmp.nsi"
+ # the following replaces strings in the nsi template
+ # it also does python-style % substitution
+ self.replace_in("installers/windows/installer_template.nsi", tempfile, {
+ "%%VERSION%%":version_vars,
+ "%%SOURCE%%":self.get_src_prefix(),
+ "%%GRID_VARS%%":grid_vars_template % substitution_strings,
+ "%%INSTALL_FILES%%":self.nsi_file_commands(True),
+ "%%DELETE_FILES%%":self.nsi_file_commands(False)})
+
+ NSIS_path = 'C:\\Program Files\\NSIS\\makensis.exe'
+ self.run_command('"' + proper_windows_path(NSIS_path) + '" ' + self.dst_path_of(tempfile))
+ # self.remove(self.dst_path_of(tempfile))
+ self.created_path(self.dst_path_of(installer_file))
+ self.package_file = installer_file
class DarwinManifest(ViewerManifest):
- def construct(self):
- # copy over the build result (this is a no-op if run within the xcode script)
- self.path("build/" + self.args['configuration'] + "/Second Life.app", dst="")
-
- if self.prefix(src="", dst="Contents"): # everything goes in Contents
- # Expand the tar file containing the assorted mozilla bits into
- # <bundle>/Contents/MacOS/
- self.contents_of_tar('mozilla-universal-darwin.tgz', 'MacOS')
-
- # copy additional libs in <bundle>/Contents/MacOS/
- self.path("../../libraries/universal-darwin/lib_release/libndofdev.dylib", dst="MacOS/libndofdev.dylib")
-
- # replace the default theme with our custom theme (so scrollbars work).
- if self.prefix(src="mozilla-theme", dst="MacOS/chrome"):
- self.path("classic.jar")
- self.path("classic.manifest")
- self.end_prefix("MacOS/chrome")
-
- # most everything goes in the Resources directory
- if self.prefix(src="", dst="Resources"):
- super(DarwinManifest, self).construct()
-
- if self.prefix("cursors_mac"):
- self.path("*.tif")
- self.end_prefix("cursors_mac")
-
- self.path("licenses-mac.txt", dst="licenses.txt")
- self.path("featuretable_mac.txt")
- self.path("secondlife.icns")
-
- # llkdu dynamic library
- self.path("../../libraries/universal-darwin/lib_release/libllkdu.dylib", "libllkdu.dylib")
-
- # command line arguments for connecting to the proper grid
- self.put_in_file(self.flags_list(), 'arguments.txt')
-
- self.end_prefix("Resources")
-
- self.end_prefix("Contents")
-
- # NOTE: the -S argument to strip causes it to keep enough info for
- # annotated backtraces (i.e. function names in the crash log). 'strip' with no
- # arguments yields a slightly smaller binary but makes crash logs mostly useless.
- # This may be desirable for the final release. Or not.
- if("package" in self.args['actions'] or
- "unpacked" in self.args['actions']):
- self.run_command('strip -S "%(viewer_binary)s"' %
- { 'viewer_binary' : self.dst_path_of('Contents/MacOS/Second Life')})
-
-
- def package_finish(self):
- channel_standin = 'Second Life' # hah, our default channel is not usable on its own
- if not self.default_channel():
- channel_standin = self.channel()
-
- imagename="SecondLife_" + '_'.join(self.args['version'])
- if self.default_channel():
- if not self.default_grid():
- # beta case
- imagename = imagename + '_' + self.args['grid'].upper()
- else:
- # first look, etc
- imagename = imagename + '_' + self.channel_oneword().upper()
-
- sparsename = imagename + ".sparseimage"
- finalname = imagename + ".dmg"
- # make sure we don't have stale files laying about
- self.remove(sparsename, finalname)
-
- self.run_command('hdiutil create "%(sparse)s" -volname "%(channel)s" -fs HFS+ -type SPARSE -megabytes 300 -layout SPUD' % {
- 'sparse':sparsename,
- 'channel':channel_standin})
-
- # mount the image and get the name of the mount point and device node
- hdi_output = self.run_command('hdiutil attach -private "' + sparsename + '"')
- devfile = re.search("/dev/disk([0-9]+)[^s]", hdi_output).group(0).strip()
- volpath = re.search('HFS\s+(.+)', hdi_output).group(1).strip()
-
- # Copy everything in to the mounted .dmg
- if self.default_channel() and not self.default_grid():
- app_name = "Second Life " + self.args['grid']
- else:
- app_name = channel_standin.strip()
-
- for s,d in {self.get_dst_prefix():app_name + ".app",
- "lsl_guide.html":"Linden Scripting Language Guide.html",
- "releasenotes.txt":"Release Notes.txt",
- "installers/darwin/mac_image_hidden":".hidden",
- "installers/darwin/mac_image_background.tga":"background.tga",
- "installers/darwin/mac_image_DS_Store":".DS_Store"}.items():
- print "Copying to dmg", s, d
- self.copy_action(self.src_path_of(s), os.path.join(volpath, d))
-
- # Unmount the image
- self.run_command('hdiutil detach -force "' + devfile + '"')
-
- print "Converting temp disk image to final disk image"
- self.run_command('hdiutil convert "%(sparse)s" -format UDZO -imagekey zlib-level=9 -o "%(final)s"' % {'sparse':sparsename, 'final':finalname})
- # get rid of the temp file
- self.remove(sparsename)
+ def construct(self):
+ # copy over the build result (this is a no-op if run within the xcode script)
+ self.path(self.args['configuration'] + "/Second Life.app", dst="")
+
+ if self.prefix(src="", dst="Contents"): # everything goes in Contents
+ # Expand the tar file containing the assorted mozilla bits into
+ # <bundle>/Contents/MacOS/
+ self.contents_of_tar(self.args['source']+'/mozilla-universal-darwin.tgz', 'MacOS')
+
+ self.path("Info-SecondLife.plist", dst="Info.plist")
+
+ # copy additional libs in <bundle>/Contents/MacOS/
+ self.path("../../libraries/universal-darwin/lib_release/libndofdev.dylib", dst="MacOS/libndofdev.dylib")
+
+ # replace the default theme with our custom theme (so scrollbars work).
+ if self.prefix(src="mozilla-theme", dst="MacOS/chrome"):
+ self.path("classic.jar")
+ self.path("classic.manifest")
+ self.end_prefix("MacOS/chrome")
+
+ # most everything goes in the Resources directory
+ if self.prefix(src="", dst="Resources"):
+ super(DarwinManifest, self).construct()
+
+ if self.prefix("cursors_mac"):
+ self.path("*.tif")
+ self.end_prefix("cursors_mac")
+
+ self.path("licenses-mac.txt", dst="licenses.txt")
+ self.path("featuretable_mac.txt")
+ self.path("secondlife.icns")
+
+ # Translations
+ self.path("English.lproj")
+ self.path("German.lproj")
+ self.path("Japanese.lproj")
+ self.path("Korean.lproj")
+
+ # SLVoice and vivox lols
+ self.path("vivox-runtime/universal-darwin/libalut.dylib", "libalut.dylib")
+ self.path("vivox-runtime/universal-darwin/libopenal.dylib", "libopenal.dylib")
+ self.path("vivox-runtime/universal-darwin/libortp.dylib", "libortp.dylib")
+ self.path("vivox-runtime/universal-darwin/libvivoxsdk.dylib", "libvivoxsdk.dylib")
+ self.path("vivox-runtime/universal-darwin/SLVoice", "SLVoice")
+ self.path("vivox-runtime/universal-darwin/SLVoiceAgent.app", "SLVoiceAgent.app")
+
+ # llkdu dynamic library
+ self.path("../../libraries/universal-darwin/lib_release/libllkdu.dylib", "libllkdu.dylib")
+
+ #libfmodwrapper.dylib
+ self.path(self.args['configuration'] + "/libfmodwrapper.dylib", "libfmodwrapper.dylib")
+
+ # command line arguments for connecting to the proper grid
+ self.put_in_file(self.flags_list(), 'arguments.txt')
+
+ self.end_prefix("Resources")
+
+ self.end_prefix("Contents")
+
+ # NOTE: the -S argument to strip causes it to keep enough info for
+ # annotated backtraces (i.e. function names in the crash log). 'strip' with no
+ # arguments yields a slightly smaller binary but makes crash logs mostly useless.
+ # This may be desirable for the final release. Or not.
+ if ("package" in self.args['actions'] or
+ "unpacked" in self.args['actions']):
+ self.run_command('strip -S "%(viewer_binary)s"' %
+ { 'viewer_binary' : self.dst_path_of('Contents/MacOS/Second Life')})
+
+
+ def package_finish(self):
+ channel_standin = 'Second Life' # hah, our default channel is not usable on its own
+ if not self.default_channel():
+ channel_standin = self.channel()
+
+ imagename="SecondLife_" + '_'.join(self.args['version'])
+ if self.default_channel():
+ if not self.default_grid():
+ # beta case
+ imagename = imagename + '_' + self.args['grid'].upper()
+ else:
+ # first look, etc
+ imagename = imagename + '_' + self.channel_oneword().upper()
+
+ sparsename = imagename + ".sparseimage"
+ finalname = imagename + ".dmg"
+ # make sure we don't have stale files laying about
+ self.remove(sparsename, finalname)
+
+ self.run_command('hdiutil create "%(sparse)s" -volname "%(channel)s" -fs HFS+ -type SPARSE -megabytes 300 -layout SPUD' % {
+ 'sparse':sparsename,
+ 'channel':channel_standin})
+
+ # mount the image and get the name of the mount point and device node
+ hdi_output = self.run_command('hdiutil attach -private "' + sparsename + '"')
+ devfile = re.search("/dev/disk([0-9]+)[^s]", hdi_output).group(0).strip()
+ volpath = re.search('HFS\s+(.+)', hdi_output).group(1).strip()
+
+ # Copy everything in to the mounted .dmg
+ if self.default_channel() and not self.default_grid():
+ app_name = "Second Life " + self.args['grid']
+ else:
+ app_name = channel_standin.strip()
+
+ for s,d in {self.get_dst_prefix():app_name + ".app",
+ "lsl_guide.html":"Linden Scripting Language Guide.html",
+ "releasenotes.txt":"Release Notes.txt",
+ "installers/darwin/mac_image_hidden":".hidden",
+ "installers/darwin/mac_image_background.tga":"background.tga",
+ "installers/darwin/mac_image_DS_Store":".DS_Store"}.items():
+ print "Copying to dmg", s, d
+ self.copy_action(self.src_path_of(s), os.path.join(volpath, d))
+
+ # Unmount the image
+ self.run_command('hdiutil detach -force "' + devfile + '"')
+
+ print "Converting temp disk image to final disk image"
+ self.run_command('hdiutil convert "%(sparse)s" -format UDZO -imagekey zlib-level=9 -o "%(final)s"' % {'sparse':sparsename, 'final':finalname})
+ # get rid of the temp file
+ self.package_file = finalname
+ self.remove(sparsename)
class LinuxManifest(ViewerManifest):
- def construct(self):
- super(LinuxManifest, self).construct()
- self.path("licenses-linux.txt","licenses.txt")
- self.path("res/ll_icon.png","secondlife_icon.png")
- if self.prefix("linux_tools", ""):
- self.path("client-readme.txt","README-linux.txt")
- self.path("client-readme-voice.txt","README-linux-voice.txt")
- self.path("wrapper.sh","secondlife")
- self.path("handle_secondlifeprotocol.sh")
- self.path("register_secondlifeprotocol.sh")
- self.end_prefix("linux_tools")
-
- # Create an appropriate gridargs.dat for this package, denoting required grid.
- self.put_in_file(self.flags_list(), 'gridargs.dat')
-
-
- def package_finish(self):
- # stripping all the libs removes a few megabytes from the end-user package
- for s,d in self.file_list:
- if re.search("lib/lib.+\.so.*", d):
- self.run_command('strip -S %s' % d)
- if re.search("app_settings/mozilla-runtime-.*/lib.+\.so.*", d):
- self.run_command('strip %s' % d)
-
- if(self.args.has_key('installer_name')):
- installer_name = self.args['installer_name']
- else:
- installer_name = '_'.join('SecondLife_', self.args.get('arch'), *self.args['version'])
- if self.default_channel():
- if not self.default_grid():
- installer_name += '_' + self.args['grid'].upper()
- else:
- installer_name += '_' + self.channel_oneword().upper()
+ def construct(self):
+ super(LinuxManifest, self).construct()
+ self.path("licenses-linux.txt","licenses.txt")
+ self.path("res/ll_icon.png","secondlife_icon.png")
+ if self.prefix("linux_tools", dst=""):
+ self.path("client-readme.txt","README-linux.txt")
+ self.path("client-readme-voice.txt","README-linux-voice.txt")
+ self.path("wrapper.sh","secondlife")
+ self.path("handle_secondlifeprotocol.sh")
+ self.path("register_secondlifeprotocol.sh")
+ self.end_prefix("linux_tools")
+
+ # Create an appropriate gridargs.dat for this package, denoting required grid.
+ self.put_in_file(self.flags_list(), 'gridargs.dat')
+
+
+ def package_finish(self):
+ # stripping all the libs removes a few megabytes from the end-user package
+ for s,d in self.file_list:
+ if re.search("lib/lib.+\.so.*", d):
+ self.run_command('strip -S %s' % d)
+ if re.search("app_settings/mozilla-runtime-.*/lib.+\.so.*", d):
+ self.run_command('strip %s' % d)
+
+ if 'installer_name' in self.args:
+ installer_name = self.args['installer_name']
+ else:
+ installer_name_components = ['SecondLife_', self.args.get('arch')]
+ installer_name_components.extend(self.args['version'])
+ installer_name = "_".join(installer_name_components)
+ if self.default_channel():
+ if not self.default_grid():
+ installer_name += '_' + self.args['grid'].upper()
+ else:
+ installer_name += '_' + self.channel_oneword().upper()
# Fix access permissions
self.run_command("""
@@ -477,71 +518,84 @@ class LinuxManifest(ViewerManifest):
find %(dst)s -type f -perm 0600 | xargs --no-run-if-empty chmod 0644;
find %(dst)s -type f -perm 0400 | xargs --no-run-if-empty chmod 0444;
true""" % {'dst':self.get_dst_prefix() })
-
- # temporarily move directory tree so that it has the right name in the tarfile
- self.run_command("mv %(dst)s %(inst)s" % {'dst':self.get_dst_prefix(),'inst':self.src_path_of(installer_name)})
- # --numeric-owner hides the username of the builder for security etc.
- self.run_command('tar -C %(dir)s --numeric-owner -cjf %(inst_path)s.tar.bz2 %(inst_name)s' % {'dir':self.get_src_prefix(), 'inst_name': installer_name, 'inst_path':self.src_path_of(installer_name)})
- self.run_command("mv %(inst)s %(dst)s" % {'dst':self.get_dst_prefix(),'inst':self.src_path_of(installer_name)})
+ self.package_file = installer_name + '.tar.bz2'
+
+ # temporarily move directory tree so that it has the right
+ # name in the tarfile
+ self.run_command("mv %(dst)s %(inst)s" % {
+ 'dst': self.get_dst_prefix(),
+ 'inst': self.build_path_of(installer_name)})
+ try:
+ # --numeric-owner hides the username of the builder for
+ # security etc.
+ self.run_command('tar -C %(dir)s --numeric-owner -cjf '
+ '%(inst_path)s.tar.bz2 %(inst_name)s' % {
+ 'dir': self.get_build_prefix(),
+ 'inst_name': installer_name,
+ 'inst_path':self.build_path_of(installer_name)})
+ finally:
+ self.run_command("mv %(inst)s %(dst)s" % {
+ 'dst': self.get_dst_prefix(),
+ 'inst': self.build_path_of(installer_name)})
class Linux_i686Manifest(LinuxManifest):
- def construct(self):
- super(Linux_i686Manifest, self).construct()
- self.path("secondlife-i686-bin-stripped","bin/do-not-directly-run-secondlife-bin")
- self.path("../linux_crash_logger/linux-crash-logger-i686-bin-stripped","linux-crash-logger.bin")
- self.path("linux_tools/launch_url.sh","launch_url.sh")
- if self.prefix("res-sdl"):
- self.path("*")
- # recurse
- self.end_prefix("res-sdl")
-
- self.path("featuretable_linux.txt")
- #self.path("secondlife-i686.supp")
-
- self.path("app_settings/mozilla-runtime-linux-i686")
-
- if self.prefix("../../libraries/i686-linux/lib_release_client", "lib"):
- self.path("libkdu_v42R.so")
- self.path("libfmod-3.75.so")
- self.path("libapr-1.so.0")
- self.path("libaprutil-1.so.0")
- self.path("libdb-4.2.so")
- self.path("libcrypto.so.0.9.7")
- self.path("libssl.so.0.9.7")
- self.path("libstdc++.so.6")
- self.path("libuuid.so", "libuuid.so.1")
- self.path("libSDL-1.2.so.0")
- self.path("libELFIO.so")
- self.path("libopenjpeg.so.2")
- #self.path("libtcmalloc.so.0") - bugged
- #self.path("libstacktrace.so.0") - probably bugged
- self.path("libllkdu.so", "../bin/libllkdu.so") # llkdu goes in bin for some reason
- self.end_prefix("lib")
-
- # Vivox runtimes
- if self.prefix(src="vivox-runtime/i686-linux", dst=""):
- self.path("SLVoice")
- self.end_prefix()
- if self.prefix(src="vivox-runtime/i686-linux", dst="lib"):
- self.path("libopenal.so.1")
- self.path("libortp.so")
- self.path("libvivoxsdk.so")
- self.path("libalut.so")
- self.end_prefix("lib")
+ def construct(self):
+ super(Linux_i686Manifest, self).construct()
+ self.path("secondlife-stripped","bin/do-not-directly-run-secondlife-bin")
+ self.path("../linux_crash_logger/linux-crash-logger-stripped","linux-crash-logger.bin")
+ self.path("linux_tools/launch_url.sh","launch_url.sh")
+ if self.prefix("res-sdl"):
+ self.path("*")
+ # recurse
+ self.end_prefix("res-sdl")
+
+ self.path("featuretable_linux.txt")
+ #self.path("secondlife-i686.supp")
+
+ self.path("app_settings/mozilla-runtime-linux-i686")
+
+ if self.prefix("../../libraries/i686-linux/lib_release_client", dst="lib"):
+ self.path("libkdu_v42R.so")
+ self.path("libfmod-3.75.so")
+ self.path("libapr-1.so.0")
+ self.path("libaprutil-1.so.0")
+ self.path("libdb-4.2.so")
+ self.path("libcrypto.so.0.9.7")
+ self.path("libssl.so.0.9.7")
+ self.path("libstdc++.so.6")
+ self.path("libuuid.so", "libuuid.so.1")
+ self.path("libSDL-1.2.so.0")
+ self.path("libELFIO.so")
+ self.path("libopenjpeg.so.2")
+ #self.path("libtcmalloc.so.0") - bugged
+ #self.path("libstacktrace.so.0") - probably bugged
+ self.path("libllkdu.so", "../bin/libllkdu.so") # llkdu goes in bin for some reason
+ self.end_prefix("lib")
+
+ # Vivox runtimes
+ if self.prefix(src="vivox-runtime/i686-linux", dst="bin"):
+ self.path("SLVoice")
+ self.end_prefix()
+ if self.prefix(src="vivox-runtime/i686-linux", dst="lib"):
+ self.path("libopenal.so.1")
+ self.path("libortp.so")
+ self.path("libvivoxsdk.so")
+ self.path("libalut.so")
+ self.end_prefix("lib")
class Linux_x86_64Manifest(LinuxManifest):
- def construct(self):
- super(Linux_x86_64Manifest, self).construct()
- self.path("secondlife-x86_64-bin-stripped","bin/do-not-directly-run-secondlife-bin")
- self.path("../linux_crash_logger/linux-crash-logger-x86_64-bin-stripped","linux-crash-logger.bin")
- self.path("linux_tools/launch_url.sh","launch_url.sh")
- if self.prefix("res-sdl"):
- self.path("*")
- # recurse
- self.end_prefix("res-sdl")
-
- self.path("featuretable_linux.txt")
- self.path("secondlife-i686.supp")
+ def construct(self):
+ super(Linux_x86_64Manifest, self).construct()
+ self.path("secondlife-stripped","bin/do-not-directly-run-secondlife-bin")
+ self.path("../linux_crash_logger/linux-crash-logger-stripped","linux-crash-logger.bin")
+ self.path("linux_tools/launch_url.sh","launch_url.sh")
+ if self.prefix("res-sdl"):
+ self.path("*")
+ # recurse
+ self.end_prefix("res-sdl")
+
+ self.path("featuretable_linux.txt")
+ self.path("secondlife-i686.supp")
if __name__ == "__main__":
- main(srctree=viewer_dir, dsttree=os.path.join(viewer_dir, "packaged"))
+ main()