diff options
-rw-r--r-- | autobuild.xml | 10 | ||||
-rw-r--r-- | indra/llcommon/llerror.cpp | 17 | ||||
-rw-r--r-- | indra/llcommon/llerror.h | 10 | ||||
-rw-r--r-- | indra/newview/llappviewer.cpp | 4 | ||||
-rw-r--r-- | indra/newview/llcurrencyuimanager.cpp | 13 | ||||
-rw-r--r-- | indra/newview/llpanellogin.cpp | 13 | ||||
-rw-r--r-- | indra/newview/lltranslate.cpp | 25 | ||||
-rw-r--r-- | indra/newview/llversioninfo.cpp | 4 | ||||
-rw-r--r-- | indra/newview/llversioninfo.h | 2 | ||||
-rw-r--r-- | indra/newview/llxmlrpctransaction.cpp | 15 | ||||
-rwxr-xr-x | indra/newview/viewer_manifest.py | 50 |
11 files changed, 93 insertions, 70 deletions
diff --git a/autobuild.xml b/autobuild.xml index 38f4a8c256..569b9f7c28 100644 --- a/autobuild.xml +++ b/autobuild.xml @@ -440,11 +440,11 @@ <key>archive</key> <map> <key>hash</key> - <string>6bb33eb9818f8b166e3bad22ba84fec0f9b397fa</string> + <string>e4d568c166049ce61b39d69887b56d2382781a1a</string> <key>hash_algorithm</key> <string>sha1</string> <key>url</key> - <string>https://github.com/secondlife/dullahan/releases/download/v1.14.0/dullahan-1.14.0.202310042042_117.2.2_ge80c977_chromium-117.0.5938.132-darwin64-bb8417d.tar.zst</string> + <string>https://github.com/secondlife/dullahan/releases/download/v118.0.5993.54/dullahan-1.14.0.202310131309_118.4.1_g3dd6078_chromium-118.0.5993.54-darwin64-6b02a60.tar.zst</string> </map> <key>name</key> <string>darwin64</string> @@ -454,11 +454,11 @@ <key>archive</key> <map> <key>hash</key> - <string>7100f36b969d3c09bcaf50df988b4035c77e3158</string> + <string>a00eae7f5dc430ae48389ab723ced39739b0a144</string> <key>hash_algorithm</key> <string>sha1</string> <key>url</key> - <string>https://github.com/secondlife/dullahan/releases/download/v1.14.0/dullahan-1.14.0.202310042145_117.2.2_ge80c977_chromium-117.0.5938.132-windows64-bb8417d.tar.zst</string> + <string>https://github.com/secondlife/dullahan/releases/download/v118.0.5993.54/dullahan-1.14.0.202310131404_118.4.1_g3dd6078_chromium-118.0.5993.54-windows64-6b02a60.tar.zst</string> </map> <key>name</key> <string>windows64</string> @@ -471,7 +471,7 @@ <key>copyright</key> <string>Copyright (c) 2017, Linden Research, Inc.</string> <key>version</key> - <string>1.14.0.202310042145_117.2.2_ge80c977_chromium-117.0.5938.132</string> + <string>1.14.0.202310131404_118.4.1_g3dd6078_chromium-118.0.5993.54</string> <key>name</key> <string>dullahan</string> <key>description</key> diff --git a/indra/llcommon/llerror.cpp b/indra/llcommon/llerror.cpp index 02cb186275..05e719b494 100644 --- a/indra/llcommon/llerror.cpp +++ b/indra/llcommon/llerror.cpp @@ -1617,5 +1617,18 @@ bool debugLoggingEnabled(const std::string& tag) return res; } - - +void crashdriver(void (*callback)(int*)) +{ + // The LLERROR_CRASH macro used to have inline code of the form: + //int* make_me_crash = NULL; + //*make_me_crash = 0; + + // But compilers are getting smart enough to recognize that, so we must + // assign to an address supplied by a separate source file. We could do + // the assignment here in crashdriver() -- but then BugSplat would group + // all LL_ERRS() crashes as the fault of this one function, instead of + // identifying the specific LL_ERRS() source line. So instead, do the + // assignment in a lambda in the caller's source. We just provide the + // nullptr target. + callback(nullptr); +} diff --git a/indra/llcommon/llerror.h b/indra/llcommon/llerror.h index 020f05e8f5..624a5fb37a 100644 --- a/indra/llcommon/llerror.h +++ b/indra/llcommon/llerror.h @@ -383,11 +383,9 @@ typedef LLError::NoClassInfo _LL_CLASS_TO_LOG; #define LL_NEWLINE '\n' // Use this only in LL_ERRS or in a place that LL_ERRS may not be used -#define LLERROR_CRASH \ -{ \ - int* make_me_crash = NULL;\ - *make_me_crash = 0; \ - exit(*make_me_crash); \ +#define LLERROR_CRASH \ +{ \ + crashdriver([](int* ptr){ *ptr = 0; exit(*ptr); }); \ } #define LL_ENDL \ @@ -466,5 +464,7 @@ typedef LLError::NoClassInfo _LL_CLASS_TO_LOG; // Check at run-time whether logging is enabled, without generating output bool debugLoggingEnabled(const std::string& tag); +// used by LLERROR_CRASH +void crashdriver(void (*)(int*)); #endif // LL_LLERROR_H diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index dec849afa1..5763ebe721 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -3209,8 +3209,10 @@ LLSD LLAppViewer::getViewerInfo() const // LLFloaterAbout. LLSD info; auto& versionInfo(LLVersionInfo::instance()); + // With GitHub builds, the build number is too big to fit in a 32-bit int, + // and LLSD doesn't deal with integers wider than int. Use string. info["VIEWER_VERSION"] = llsd::array(versionInfo.getMajor(), versionInfo.getMinor(), - versionInfo.getPatch(), versionInfo.getBuild()); + versionInfo.getPatch(), stringize(versionInfo.getBuild())); info["VIEWER_VERSION_STR"] = versionInfo.getVersion(); info["CHANNEL"] = versionInfo.getChannel(); info["ADDRESS_SIZE"] = ADDRESS_SIZE; diff --git a/indra/newview/llcurrencyuimanager.cpp b/indra/newview/llcurrencyuimanager.cpp index 232e461fd0..4c0a5cf183 100644 --- a/indra/newview/llcurrencyuimanager.cpp +++ b/indra/newview/llcurrencyuimanager.cpp @@ -45,6 +45,7 @@ #include "llxmlrpctransaction.h" #include "llviewernetwork.h" #include "llpanel.h" +#include "stringize.h" const F64 CURRENCY_ESTIMATE_FREQUENCY = 2.0; @@ -158,7 +159,7 @@ void LLCurrencyUIManager::Impl::updateCurrencyInfo() mLocalCurrencyEstimated = true; return; } - + LLXMLRPCValue keywordArgs = LLXMLRPCValue::createStruct(); keywordArgs.appendString("agentId", gAgent.getID().asString()); keywordArgs.appendString( @@ -170,8 +171,10 @@ void LLCurrencyUIManager::Impl::updateCurrencyInfo() keywordArgs.appendInt("viewerMajorVersion", LLVersionInfo::instance().getMajor()); keywordArgs.appendInt("viewerMinorVersion", LLVersionInfo::instance().getMinor()); keywordArgs.appendInt("viewerPatchVersion", LLVersionInfo::instance().getPatch()); - keywordArgs.appendInt("viewerBuildVersion", LLVersionInfo::instance().getBuild()); - + // With GitHub builds, the build number is too big to fit in a 32-bit int, + // and XMLRPC_VALUE doesn't deal with integers wider than int. Use string. + keywordArgs.appendString("viewerBuildVersion", stringize(LLVersionInfo::instance().getBuild())); + LLXMLRPCValue params = LLXMLRPCValue::createArray(); params.append(keywordArgs); @@ -245,7 +248,9 @@ void LLCurrencyUIManager::Impl::startCurrencyBuy(const std::string& password) keywordArgs.appendInt("viewerMajorVersion", LLVersionInfo::instance().getMajor()); keywordArgs.appendInt("viewerMinorVersion", LLVersionInfo::instance().getMinor()); keywordArgs.appendInt("viewerPatchVersion", LLVersionInfo::instance().getPatch()); - keywordArgs.appendInt("viewerBuildVersion", LLVersionInfo::instance().getBuild()); + // With GitHub builds, the build number is too big to fit in a 32-bit int, + // and XMLRPC_VALUE doesn't deal with integers wider than int. Use string. + keywordArgs.appendString("viewerBuildVersion", stringize(LLVersionInfo::instance().getBuild())); LLXMLRPCValue params = LLXMLRPCValue::createArray(); params.append(keywordArgs); diff --git a/indra/newview/llpanellogin.cpp b/indra/newview/llpanellogin.cpp index ea936ab024..025a653c47 100644 --- a/indra/newview/llpanellogin.cpp +++ b/indra/newview/llpanellogin.cpp @@ -65,6 +65,7 @@ #include "lltrans.h" #include "llglheaders.h" #include "llpanelloginlistener.h" +#include "stringize.h" #if LL_WINDOWS #pragma warning(disable: 4355) // 'this' used in initializer list @@ -300,10 +301,9 @@ LLPanelLogin::LLPanelLogin(const LLRect &rect, setDefaultBtn(def_btn); std::string channel = LLVersionInfo::instance().getChannel(); - std::string version = llformat("%s (%ld)", - LLVersionInfo::instance().getShortVersion().c_str(), - LLVersionInfo::instance().getBuild()); - + std::string version = stringize(LLVersionInfo::instance().getShortVersion(), " (", + LLVersionInfo::instance().getBuild(), ')'); + LLTextBox* forgot_password_text = getChild<LLTextBox>("forgot_password_text"); forgot_password_text->setClickedCallback(onClickForgotPassword, NULL); @@ -894,9 +894,8 @@ void LLPanelLogin::loadLoginPage() } // Channel and Version - params["version"] = llformat("%s (%ld)", - LLVersionInfo::instance().getShortVersion().c_str(), - LLVersionInfo::instance().getBuild()); + params["version"] = stringize(LLVersionInfo::instance().getShortVersion(), " (", + LLVersionInfo::instance().getBuild(), ')'); params["channel"] = LLVersionInfo::instance().getChannel(); // Grid diff --git a/indra/newview/lltranslate.cpp b/indra/newview/lltranslate.cpp index 1e21c3fa05..6526e1df92 100644 --- a/indra/newview/lltranslate.cpp +++ b/indra/newview/lltranslate.cpp @@ -39,6 +39,7 @@ #include "json/reader.h" #include "llcorehttputil.h" #include "llurlregistry.h" +#include "stringize.h" static const std::string AZURE_NOTRANSLATE_OPENING_TAG("<div translate=\"no\">"); @@ -160,12 +161,12 @@ void LLTranslationAPIHandler::verifyKeyCoro(LLTranslate::EService service, LLSD LLCore::HttpHeaders::ptr_t httpHeaders(new LLCore::HttpHeaders); - std::string user_agent = llformat("%s %d.%d.%d (%ld)", - LLVersionInfo::instance().getChannel().c_str(), - LLVersionInfo::instance().getMajor(), - LLVersionInfo::instance().getMinor(), - LLVersionInfo::instance().getPatch(), - LLVersionInfo::instance().getBuild()); + std::string user_agent = stringize( + LLVersionInfo::instance().getChannel(), ' ', + LLVersionInfo::instance().getMajor(), '.', + LLVersionInfo::instance().getMinor(), '.', + LLVersionInfo::instance().getPatch(), " (", + LLVersionInfo::instance().getBuild(), ')'); initHttpHeader(httpHeaders, user_agent, key); @@ -215,12 +216,12 @@ void LLTranslationAPIHandler::translateMessageCoro(LanguagePair_t fromTo, std::s LLCore::HttpHeaders::ptr_t httpHeaders(new LLCore::HttpHeaders); - std::string user_agent = llformat("%s %d.%d.%d (%ld)", - LLVersionInfo::instance().getChannel().c_str(), - LLVersionInfo::instance().getMajor(), - LLVersionInfo::instance().getMinor(), - LLVersionInfo::instance().getPatch(), - LLVersionInfo::instance().getBuild()); + std::string user_agent = stringize( + LLVersionInfo::instance().getChannel(), ' ', + LLVersionInfo::instance().getMajor(), '.', + LLVersionInfo::instance().getMinor(), '.', + LLVersionInfo::instance().getPatch(), " (", + LLVersionInfo::instance().getBuild(), ')'); initHttpHeader(httpHeaders, user_agent); httpOpts->setSSLVerifyPeer(false); diff --git a/indra/newview/llversioninfo.cpp b/indra/newview/llversioninfo.cpp index 62bfa24e29..9551df7bee 100644 --- a/indra/newview/llversioninfo.cpp +++ b/indra/newview/llversioninfo.cpp @@ -69,7 +69,7 @@ void LLVersionInfo::initSingleton() // fully constructed; such calls don't really belong in the constructor. // cache the version string - version = STRINGIZE(getShortVersion() << "." << getBuild()); + version = stringize(getShortVersion(), ".", getBuild()); } LLVersionInfo::~LLVersionInfo() @@ -91,7 +91,7 @@ S32 LLVersionInfo::getPatch() return LL_VIEWER_VERSION_PATCH; } -S64 LLVersionInfo::getBuild() +U64 LLVersionInfo::getBuild() { return LL_VIEWER_VERSION_BUILD; } diff --git a/indra/newview/llversioninfo.h b/indra/newview/llversioninfo.h index 122bd5c47a..a40042380a 100644 --- a/indra/newview/llversioninfo.h +++ b/indra/newview/llversioninfo.h @@ -61,7 +61,7 @@ public: S32 getPatch(); /// return the build number as an integer - S64 getBuild(); + U64 getBuild(); /// return the full viewer version as a string like "2.0.0.200030" std::string getVersion(); diff --git a/indra/newview/llxmlrpctransaction.cpp b/indra/newview/llxmlrpctransaction.cpp index b851b7ad5c..8ea07fcee0 100644 --- a/indra/newview/llxmlrpctransaction.cpp +++ b/indra/newview/llxmlrpctransaction.cpp @@ -42,6 +42,7 @@ #include "bufferarray.h" #include "llversioninfo.h" #include "llviewercontrol.h" +#include "stringize.h" // Have to include these last to avoid queue redefinition! @@ -384,14 +385,14 @@ void LLXMLRPCTransaction::Impl::init(XMLRPC_REQUEST request, bool useGzip, const httpHeaders->append(HTTP_OUT_HEADER_CONTENT_TYPE, HTTP_CONTENT_TEXT_XML); - std::string user_agent = llformat("%s %d.%d.%d (%ld)", - LLVersionInfo::instance().getChannel().c_str(), - LLVersionInfo::instance().getMajor(), - LLVersionInfo::instance().getMinor(), - LLVersionInfo::instance().getPatch(), - LLVersionInfo::instance().getBuild()); + std::string user_agent = stringize( + LLVersionInfo::instance().getChannel(), ' ', + LLVersionInfo::instance().getMajor(), '.', + LLVersionInfo::instance().getMinor(), '.', + LLVersionInfo::instance().getPatch(), " (", + LLVersionInfo::instance().getBuild(), ')'); - httpHeaders->append(HTTP_OUT_HEADER_USER_AGENT, user_agent); + httpHeaders->append(HTTP_OUT_HEADER_USER_AGENT, user_agent); ///* Setting the DNS cache timeout to -1 disables it completely. //This might help with bug #503 */ diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py index 33b2e4affc..1fa4df1682 100755 --- a/indra/newview/viewer_manifest.py +++ b/indra/newview/viewer_manifest.py @@ -837,30 +837,7 @@ class Darwin_x86_64_Manifest(ViewerManifest): def construct(self): # copy over the build result (this is a no-op if run within the xcode # script) - appname = self.channel() + ".app" - self.path(os.path.join(self.args['configuration'], appname), dst="") - RUNNER_TEMP = os.getenv('RUNNER_TEMP') - # When running as a GitHub Action job, RUNNER_TEMP is the recommended - # temp directory. If we're not running on GitHub, don't create this - # temp directory or this tarball: we don't clean them up, trusting - # that the runner is itself transient. On a dev machine, that would - # result in temp-directory clutter. - if RUNNER_TEMP: - # Per GitHub's actions/upload-artifact documentation - # https://github.com/actions/upload-artifact#maintaining-file-permissions-and-case-sensitive-files - # we must package the app bundle with tar before posting as an - # artifact. Posting individual files follows symlinks, which - # causes problems, especially with frameworks: a framework's top - # level must contain symlinks into its Versions/Current, which - # must itself be a symlink to some specific Versions subdir. - tarpath = os.path.join(RUNNER_TEMP, "viewer.tar.bz2") - print(f'Creating {tarpath} from {self.get_dst_prefix()}') - with tarfile.open(tarpath, mode="w:bz2") as tarball: - # store in the tarball as just 'Second Life Mumble.app' - # instead of 'Users/someone/.../newview/Release/Second...' - tarball.add(self.get_dst_prefix(), - arcname=os.path.basename(self.get_dst_prefix())) - self.set_github_output_path('viewer_app', tarpath) + self.path(os.path.join(self.args['configuration'], self.channel() + ".app"), dst="") pkgdir = os.path.join(self.args['build'], os.pardir, 'packages') relpkgdir = os.path.join(pkgdir, "lib", "release") @@ -1188,6 +1165,31 @@ class Darwin_x86_64_Manifest(ViewerManifest): finalname = imagename + ".dmg" self.package_file = finalname + RUNNER_TEMP = os.getenv('RUNNER_TEMP') + # When running as a GitHub Action job, RUNNER_TEMP is the recommended + # temp directory. If we're not running on GitHub, don't create this + # temp directory or this tarball: we don't clean them up, trusting + # that the runner is itself transient. On a dev machine, that would + # result in temp-directory clutter. + if RUNNER_TEMP: + # Per GitHub's actions/upload-artifact documentation + # https://github.com/actions/upload-artifact#maintaining-file-permissions-and-case-sensitive-files + # we must package the app bundle with tar before posting as an + # artifact. Posting individual files follows symlinks, which + # causes problems, especially with frameworks: a framework's top + # level must contain symlinks into its Versions/Current, which + # must itself be a symlink to some specific Versions subdir. + tarpath = os.path.join(RUNNER_TEMP, "viewer.tar.bz2") + print(f'Creating {tarpath} from {self.get_dst_prefix()}') + with tarfile.open(tarpath, mode="w:bz2") as tarball: + # Store in the tarball as just 'Second Life Mumble.app' + # instead of 'Users/someone/.../newview/Release/Second...' + # It's at this point that we rename 'Second Life Release.app' + # to 'Second Life Viewer.app'. + tarball.add(self.get_dst_prefix(), + arcname=self.app_name() + ".app") + self.set_github_output_path('viewer_app', tarpath) + class LinuxManifest(ViewerManifest): build_data_json_platform = 'lnx' |