OK. I created SNOW-174. BTW, it looks like the Second Life Project Contribution Agreement conflicts with the GPL. I'm just contributing like any other GPL project. I'm not a lawyer though :-)
On Thu, 2009-08-06 at 14:12 +0200, Carlo Wood wrote: > Hey Ralph, looks good. > > Can you create a pjira (on > https://jira.secondlife.com/secure/CreateIssue!default.jspa) > for this and attach your patch? > > Note that you might need to sign a contribution agreement for this, > not sure if it will be considered minor changes. > > On Wed, Aug 05, 2009 at 08:44:31PM -0700, Ralph Campbell wrote: > > I was able to get snowglobe-src-viewer-1.0.2-r2451.tar.gz to compile > > and run on a Fedora 11 x86_64 system with the following patches. > > > > Fixed compiler warnings since I didn't know how to turn off gcc -Werror > > in cmake. > > > > Fixed viewer_manifest.py to copy secondlife-stripped to the right > > location for x86_64 builds. > > > > When I started snowglobe, I was able to log in and it popped up > > a dialog box to accept the terms of usage. The usage agreement didn't > > display and I traced this to LLSDXMLParser::Impl::parse() being used > > on the text which defined "</head>" but didn't skip over it properly. > > LLSDXMLParser::Impl::parse() doesn't seem like a general purpose XML > > parser, just for reading saved configuration data. Since the parser > > returned an error, the "I agree" checkbox was not enabled and I couldn't > > make progress. I hacked around the problem by temporarily making > > the checkbox enabled by default. > > Anyway, a patch is included to skip over unknown elements. > > > > I edited tut-2008-11-30.tar.gz to include tut::result_type::skip since > > it wasn't defined. I guess there must be a newer version of tut > > somewhere. > > I also edited the hash_map C++ file to not warn about future > > incompatibility. > > > > > > > Fix compiler warnings on Fedora 11 x86_64. > > > > --- indra/llcommon/llstring.h.old 2009-08-02 19:52:13.549420229 -0700 > > +++ indra/llcommon/llstring.h 2009-08-02 19:55:15.642777031 -0700 > > @@ -41,6 +41,7 @@ > > #endif > > > > #include <string.h> > > +#include <stdio.h> > > > > #if LL_SOLARIS > > // stricmp and strnicmp do not exist on Solaris: > > --- indra/llcommon/llstring.cpp.old 2009-08-02 19:04:52.374419361 -0700 > > +++ indra/llcommon/llstring.cpp 2009-08-02 19:05:34.102740108 -0700 > > @@ -134,7 +134,7 @@ S32 wchar_to_utf8chars(llwchar in_char, > > *outchars++ = 0xF0 | (cur_char >> 18); > > *outchars++ = 0x80 | ((cur_char >> 12) & 0x3F); > > *outchars++ = 0x80 | ((cur_char >> 6) & 0x3F); > > - *outchars++ = 0x80 | cur_char & 0x3F; > > + *outchars++ = 0x80 | (cur_char & 0x3F); > > } > > else if (cur_char < 0x4000000) > > { > > @@ -142,7 +142,7 @@ S32 wchar_to_utf8chars(llwchar in_char, > > *outchars++ = 0x80 | ((cur_char >> 18) & 0x3F); > > *outchars++ = 0x80 | ((cur_char >> 12) & 0x3F); > > *outchars++ = 0x80 | ((cur_char >> 6) & 0x3F); > > - *outchars++ = 0x80 | cur_char & 0x3F; > > + *outchars++ = 0x80 | (cur_char & 0x3F); > > } > > else if (cur_char < 0x80000000) > > { > > @@ -151,7 +151,7 @@ S32 wchar_to_utf8chars(llwchar in_char, > > *outchars++ = 0x80 | ((cur_char >> 18) & 0x3F); > > *outchars++ = 0x80 | ((cur_char >> 12) & 0x3F); > > *outchars++ = 0x80 | ((cur_char >> 6) & 0x3F); > > - *outchars++ = 0x80 | cur_char & 0x3F; > > + *outchars++ = 0x80 | (cur_char & 0x3F); > > } > > else > > { > > --- indra/newview/llface.cpp.old 2009-08-02 20:08:44.758441558 -0700 > > +++ indra/newview/llface.cpp 2009-08-02 20:09:31.333549560 -0700 > > @@ -988,7 +988,7 @@ BOOL LLFace::getGeometryVolume(const LLV > > 0.75f > > }; > > > > - if (getPoolType() != LLDrawPool::POOL_ALPHA && > > (LLPipeline::sRenderDeferred || LLPipeline::sRenderBump && tep->getShiny())) > > + if (getPoolType() != LLDrawPool::POOL_ALPHA && > > (LLPipeline::sRenderDeferred || (LLPipeline::sRenderBump && > > tep->getShiny()))) > > { > > color.mV[3] = U8 (alpha[tep->getShiny()] * 255); > > } > > --- indra/newview/llviewerobject.cpp.old 2009-08-02 20:20:01.278799787 > > -0700 > > +++ indra/newview/llviewerobject.cpp 2009-08-02 20:21:03.142651650 > > -0700 > > @@ -624,8 +624,8 @@ BOOL LLViewerObject::setDrawableParent(L > > > > BOOL ret = mDrawable->mXform.setParent(parentp ? &parentp->mXform : > > NULL); > > gPipeline.markRebuild(mDrawable, LLDrawable::REBUILD_VOLUME, TRUE); > > - if( old_parent != parentp && > > - old_parent || (parentp && parentp->isActive())) > > + if( (old_parent != parentp && old_parent) || > > + (parentp && parentp->isActive())) > > { > > // *TODO we should not be relying on setDrawable parent to call > > markMoved > > gPipeline.markMoved(mDrawable, FALSE); > > --- indra/newview/llvoavatar.cpp.old 2009-08-02 20:21:41.036419558 > > -0700 > > +++ indra/newview/llvoavatar.cpp 2009-08-02 20:22:38.648667807 -0700 > > @@ -1582,7 +1582,7 @@ BOOL LLVOAvatar::lineSegmentIntersect(co > > ) > > { > > > > - if (mIsSelf && !gAgent.needsRenderAvatar() || !LLPipeline::sPickAvatar) > > + if ((mIsSelf && !gAgent.needsRenderAvatar()) || > > !LLPipeline::sPickAvatar) > > { > > return FALSE; > > } > > @@ -9070,9 +9070,9 @@ BOOL LLVOAvatar::updateLOD() > > > > LLFace* facep = mDrawable->getFace(0); > > if (facep->mVertexBuffer.isNull() || > > - LLVertexBuffer::sEnableVBOs && > > + (LLVertexBuffer::sEnableVBOs && > > ((facep->mVertexBuffer->getUsage() == GL_STATIC_DRAW ? TRUE : > > FALSE) != > > - (facep->getPool()->getVertexShaderLevel() > 0 ? TRUE : FALSE))) > > + (facep->getPool()->getVertexShaderLevel() > 0 ? TRUE : FALSE)))) > > { > > mDirtyMesh = TRUE; > > } > > --- indra/newview/llvovolume.cpp.old 2009-08-02 20:25:05.546443870 > > -0700 > > +++ indra/newview/llvovolume.cpp 2009-08-02 20:25:53.161545016 -0700 > > @@ -468,8 +468,8 @@ void LLVOVolume::updateTextureVirtualSiz > > > > if (face->mTextureMatrix != NULL) > > { > > - if (vsize < MIN_TEX_ANIM_SIZE && old_size > > > MIN_TEX_ANIM_SIZE || > > - vsize > MIN_TEX_ANIM_SIZE && old_size < > > MIN_TEX_ANIM_SIZE) > > + if ((vsize < MIN_TEX_ANIM_SIZE && old_size > > > MIN_TEX_ANIM_SIZE) || > > + (vsize > MIN_TEX_ANIM_SIZE && old_size < > > MIN_TEX_ANIM_SIZE)) > > { > > gPipeline.markRebuild(mDrawable, > > LLDrawable::REBUILD_TCOORD, FALSE); > > } > > @@ -2333,7 +2333,7 @@ void LLVolumeGeometryManager::rebuildGeo > > { //needs normal + binormal > > > > bump_faces.push_back(facep); > > } > > - else if (te->getShiny() && > > LLPipeline::sRenderBump || > > + else if ((te->getShiny() && > > LLPipeline::sRenderBump) || > > !te->getFullbright()) > > { //needs normal > > > > simple_faces.push_back(facep); > > --- indra/newview/llvosky.cpp.old 2009-08-02 20:23:21.098419519 -0700 > > +++ indra/newview/llvosky.cpp 2009-08-02 20:24:10.443854152 -0700 > > @@ -1095,10 +1095,10 @@ BOOL LLVOSky::updateSky() > > > > mLastTotalAmbient.mV[2] - mTotalAmbient.mV[2]); > > > > if ( mForceUpdate > > - || ((dot_lighting < LIGHT_DIRECTION_THRESHOLD) > > + || (((dot_lighting < LIGHT_DIRECTION_THRESHOLD) > > || (delta_color.length() > > > COLOR_CHANGE_THRESHOLD) > > || !mInitialized) > > - && !direction.isExactlyZero()) > > + && !direction.isExactlyZero())) > > { > > mLastLightingDirection = direction; > > mLastTotalAmbient = mTotalAmbient; > > --- indra/newview/llspatialpartition.cpp.old 2009-08-02 > > 20:14:50.719419513 -0700 > > +++ indra/newview/llspatialpartition.cpp 2009-08-02 20:15:22.499425689 > > -0700 > > @@ -1671,9 +1671,9 @@ public: > > virtual bool earlyFail(LLSpatialGroup* group) > > { > > if (mResult || //already found a node, don't check any more > > - group->mOctreeNode->getParent() && //never > > occlusion cull the root node > > + (group->mOctreeNode->getParent() && //never > > occlusion cull the root node > > LLPipeline::sUseOcclusion && > > //ignore occlusion if disabled > > - group->isState(LLSpatialGroup::OCCLUDED)) > > + group->isState(LLSpatialGroup::OCCLUDED))) > > { > > return true; > > } > > --- indra/newview/lldrawpoolbump.cpp.old 2009-08-02 20:04:53.718419420 > > -0700 > > +++ indra/newview/lldrawpoolbump.cpp 2009-08-02 20:08:10.074442399 > > -0700 > > @@ -309,8 +309,8 @@ void LLDrawPoolBump::endRenderPass(S32 p > > void LLDrawPoolBump::beginShiny(bool invisible) > > { > > LLFastTimer t(LLFastTimer::FTM_RENDER_SHINY); > > - if (!invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_SHINY)|| > > - invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_INVISI_SHINY)) > > + if ((!invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_SHINY)) || > > + (invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_INVISI_SHINY))) > > { > > return; > > } > > @@ -384,8 +384,8 @@ void LLDrawPoolBump::beginShiny(bool inv > > void LLDrawPoolBump::renderShiny(bool invisible) > > { > > LLFastTimer t(LLFastTimer::FTM_RENDER_SHINY); > > - if (!invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_SHINY)|| > > - invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_INVISI_SHINY)) > > + if ((!invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_SHINY)) || > > + (invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_INVISI_SHINY))) > > { > > return; > > } > > @@ -411,8 +411,8 @@ void LLDrawPoolBump::renderShiny(bool in > > void LLDrawPoolBump::endShiny(bool invisible) > > { > > LLFastTimer t(LLFastTimer::FTM_RENDER_SHINY); > > - if (!invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_SHINY)|| > > - invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_INVISI_SHINY)) > > + if ((!invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_SHINY)) || > > + (invisible && > > !gPipeline.hasRenderBatches(LLRenderPass::PASS_INVISI_SHINY))) > > { > > return; > > } > > --- indra/newview/lltoolpie.cpp.old 2009-08-02 20:16:16.273667975 -0700 > > +++ indra/newview/lltoolpie.cpp 2009-08-02 20:16:37.753481495 -0700 > > @@ -189,8 +189,8 @@ BOOL LLToolPie::pickAndShowMenu(BOOL alw > > } // else nothing (fall through to touch) > > > > case CLICK_ACTION_PAY: > > - if (object && object->flagTakesMoney() > > - || parent && parent->flagTakesMoney()) > > + if ((object && object->flagTakesMoney()) > > + || (parent && parent->flagTakesMoney())) > > { > > // pay event goes to object actually clicked on > > mClickActionObject = object; > > --- indra/newview/llviewerkeyboard.cpp.old 2009-08-02 20:18:09.417419363 > > -0700 > > +++ indra/newview/llviewerkeyboard.cpp 2009-08-02 20:19:28.185424042 > > -0700 > > @@ -683,7 +683,7 @@ BOOL LLViewerKeyboard::bindKey(const S32 > > if (idx >=2 && idx <= 12) > > { > > U32 keyidx = ((mask<<16)|key); > > - (mRemapKeys[mode])[keyidx] = > > ((0<<16)|KEY_F1+(idx-1)); > > + (mRemapKeys[mode])[keyidx] = > > ((0<<16)|(KEY_F1+(idx-1))); > > return TRUE; > > } > > } > > --- indra/newview/llhudeffectlookat.cpp.old 2009-08-02 20:11:20.196419425 > > -0700 > > +++ indra/newview/llhudeffectlookat.cpp 2009-08-02 20:12:35.818564610 > > -0700 > > @@ -421,8 +421,8 @@ BOOL LLHUDEffectLookAt::setLookAt(ELookA > > BOOL lookAtChanged = (target_type != mTargetType) || (object != > > mTargetObject); > > > > // lookat position has moved a certain amount and we haven't just sent > > an update > > - lookAtChanged = lookAtChanged || (dist_vec(position, > > mLastSentOffsetGlobal) > MIN_DELTAPOS_FOR_UPDATE) && > > - ((current_time - mLastSendTime) > (1.f / MAX_SENDS_PER_SEC)); > > + lookAtChanged = lookAtChanged || ((dist_vec(position, > > mLastSentOffsetGlobal) > MIN_DELTAPOS_FOR_UPDATE) && > > + ((current_time - mLastSendTime) > (1.f / MAX_SENDS_PER_SEC))); > > > > if (lookAtChanged) > > { > > --- indra/newview/llvosky.h.old 2009-08-02 19:57:47.632419969 -0700 > > +++ indra/newview/llvosky.h 2009-08-02 20:01:46.860842458 -0700 > > @@ -147,7 +147,7 @@ protected: > > > > static S32 getResolution() > > { return sResolution; } > > static S32 getCurrent() { > > return sCurrent; } > > - static S32 stepCurrent() { > > return (sCurrent = ++sCurrent % 2); } > > + static S32 stepCurrent() { > > return (sCurrent = (sCurrent + 1) % 2); } > > static S32 getNext() { > > return ((sCurrent+1) % 2); } > > static S32 getWhich(const BOOL curr) { return curr ? > > sCurrent : getNext(); } > > > > --- indra/newview/llviewercamera.cpp.old 2009-08-02 20:17:11.132435433 > > -0700 > > +++ indra/newview/llviewercamera.cpp 2009-08-02 20:17:32.135718440 > > -0700 > > @@ -769,8 +769,8 @@ BOOL LLViewerCamera::areVertsVisible(LLV > > > > BOOL in_frustum = pointInFrustum(LLVector3(vec)) > 0; > > > > - if ( !in_frustum && all_verts || > > - in_frustum && !all_verts) > > + if ((!in_frustum && all_verts) || > > + (in_frustum && !all_verts)) > > { > > return !all_verts; > > } > > --- indra/llmessage/lliobuffer.cpp.old 2009-08-02 19:28:44.739420260 > > -0700 > > +++ indra/llmessage/lliobuffer.cpp 2009-08-02 19:29:26.290441332 -0700 > > @@ -87,7 +87,7 @@ LLIOPipe::EStatus LLIOBuffer::seek(LLIOB > > { > > case READ: > > if(((delta >= 0) && ((mReadHead + delta) <= mWriteHead)) > > - || (delta < 0) && ((mReadHead + delta) >= mBuffer)) > > + || ((delta < 0) && ((mReadHead + delta) >= mBuffer))) > > { > > mReadHead += delta; > > status = STATUS_OK; > > @@ -95,7 +95,7 @@ LLIOPipe::EStatus LLIOBuffer::seek(LLIOB > > break; > > case WRITE: > > if(((delta >= 0) && ((mWriteHead + delta) < (mBuffer + > > mBufferSize))) > > - || (delta < 0) && ((mWriteHead + delta) > mReadHead)) > > + || ((delta < 0) && ((mWriteHead + delta) > mReadHead))) > > { > > mWriteHead += delta; > > status = STATUS_OK; > > --- indra/llui/llmenugl.cpp.old 2009-08-02 19:32:21.227489696 -0700 > > +++ indra/llui/llmenugl.cpp 2009-08-02 19:32:47.332501176 -0700 > > @@ -2413,8 +2413,8 @@ void LLMenuGL::createJumpKeys() > > { > > char jump_key = uppercase_word[i]; > > > > - if (LLStringOps::isDigit(jump_key) || > > LLStringOps::isUpper(jump_key) && > > - mJumpKeys.find(jump_key) == > > mJumpKeys.end()) > > + if (LLStringOps::isDigit(jump_key) || > > (LLStringOps::isUpper(jump_key) && > > + mJumpKeys.find(jump_key) == > > mJumpKeys.end())) > > { > > mJumpKeys.insert(std::pair<KEY, > > LLMenuItemGL*>(jump_key, (*item_it))); > > > > (*item_it)->setJumpKey(jump_key); > > --- indra/llmath/v3math.h.old 2009-08-02 19:01:55.634419501 -0700 > > +++ indra/llmath/v3math.h 2009-08-02 19:03:39.578426127 -0700 > > @@ -411,8 +411,8 @@ inline bool operator<(const LLVector3 &a > > return (a.mV[0] < b.mV[0] > > || (a.mV[0] == b.mV[0] > > && (a.mV[1] < b.mV[1] > > - || (a.mV[1] == b.mV[1]) > > - && a.mV[2] < b.mV[2]))); > > + || ((a.mV[1] == b.mV[1]) > > + && a.mV[2] < b.mV[2])))); > > } > > > > inline const LLVector3& operator+=(LLVector3 &a, const LLVector3 &b) > > --- indra/llrender/llrendertarget.cpp.old 2009-08-02 19:29:49.945485691 > > -0700 > > +++ indra/llrender/llrendertarget.cpp 2009-08-02 19:30:30.470549575 > > -0700 > > @@ -139,7 +139,7 @@ void LLRenderTarget::addColorAttachment( > > > > U32 offset = mTex.size(); > > if (offset >= 4 || > > - offset > 0 && (mFBO == 0 || !gGLManager.mHasDrawBuffers)) > > + (offset > 0 && (mFBO == 0 || !gGLManager.mHasDrawBuffers))) > > { > > llerrs << "Too many color attachments!" << llendl; > > } > > @@ -608,7 +608,7 @@ void LLMultisampleBuffer::addColorAttach > > > > U32 offset = mTex.size(); > > if (offset >= 4 || > > - offset > 0 && (mFBO == 0 || !gGLManager.mHasDrawBuffers)) > > + (offset > 0 && (mFBO == 0 || !gGLManager.mHasDrawBuffers))) > > { > > llerrs << "Too many color attachments!" << llendl; > > } > > > --- indra/newview/viewer_manifest.py.old 2009-08-03 19:35:51.223659265 > > -0700 > > +++ indra/newview/viewer_manifest.py 2009-08-04 23:56:25.562523297 > > -0700 > > @@ -763,7 +763,7 @@ class Linux_i686Manifest(LinuxManifest): > > class Linux_x86_64Manifest(LinuxManifest): > > def construct(self): > > super(Linux_x86_64Manifest, self).construct() > > - self.path("secondlife-stripped",self.get_linuxbin()) > > + self.path("secondlife-stripped","bin/"+self.binary_name()) > > > > 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"): > > @@ -772,7 +772,7 @@ class Linux_x86_64Manifest(LinuxManifest > > self.end_prefix("res-sdl") > > > > self.path("featuretable_linux.txt") > > - self.path("secondlife-i686.supp") > > + #self.path("secondlife-i686.supp") > > > > if __name__ == "__main__": > > main() > > > --- indra/llcommon/llsdserialize_xml.cpp.old 2009-08-04 > > 19:34:36.119613187 -0700 > > +++ indra/llcommon/llsdserialize_xml.cpp 2009-08-05 08:23:04.403267737 > > -0700 > > @@ -408,7 +408,9 @@ S32 LLSDXMLParser::Impl::parse(std::istr > > { > > ((char*) buffer)[count ? count - 1 : 0] = '\0'; > > } > > - llinfos << "LLSDXMLParser::Impl::parse: XML_STATUS_ERROR > > parsing:" << (char*) buffer << llendl; > > + llinfos << "LLSDXMLParser::Impl::parse: XML_STATUS_ERROR (" << > > + XML_GetErrorCode(mParser) << ") parsing :" << > > + (char*) buffer << llendl; > > data = LLSD(); > > return LLSDParser::PARSE_FAILURE; > > } > > @@ -623,6 +625,9 @@ void LLSDXMLParser::Impl::startElementHa > > break; > > } > > > > + case ELEMENT_UNKNOWN: > > + return startSkipping(); > > + > > default: > > // all rest are values, fall through > > ; > > > _______________________________________________ > > Policies and (un)subscribe information available here: > > http://wiki.secondlife.com/wiki/SLDev > > Please read the policies before posting to keep unmoderated posting > > privileges > _______________________________________________ Policies and (un)subscribe information available here: http://wiki.secondlife.com/wiki/SLDev Please read the policies before posting to keep unmoderated posting privileges
