summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Clean up the logger project file and add a minimal qmake confHEADmasterLaszlo Papp2013-08-102-12/+4
| | | | | | Change-Id: I2017ac6440e4cae3add67c533eefe6136703dfd3 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Changed Contact details "qt-project.org/" to "qt-project.org/legal"Teemu Kaukoranta2013-05-278-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | Used the following command: find . -path '*/3rdparty/*' -prune -o -exec grep -ilI -E '.*Copyright.*Nokia.*|.*Contact.*' {} \; | tee >(xargs sed -i -r '1,50 { /INdT|copy[a-z]*[ ]*=/ !{ s/(^[ \t:#*]*)([a-z ]*) (Copyright.*Nokia.*)/ \1\2Copyright \(C\) 2013 Digia Plc and\/or its subsidiary\(-ies\)\./I }}') >(xargs sed -i -r '1,50 s/(^[ \t:#*]*)(.*info@qt\.nokia\.com.* |.*INSERT EMAIL ADDRESS.*|.*qt-info@nokia\.com.* |.*qt-label1@nokia\.com.*|.*http:\/\/qt\.nokia\.com\/contact.* |.*qt-sales@nokia\.com.*|.*http:\/\/www\.qt-project\.org\/.*)/ \1Contact: http:\/\/www\.qt-project\.org\/legal/I') >(xargs sed -i -r '1,50{/(^[ \t:#*]*)(all rights reserved.*)/Id}') Command now finds command details that point to qt-project.org and changes them to qt-project.org/legal Also no longer wrongly replaces code snippet "copyright = ..". Need to fix these case-by-case later. Change-Id: I540431f916247192d748479fc6c816ebf773516c Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Replaced Nokia copyrights and contact detailsTeemu Kaukoranta2013-05-279-11/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | Replaced Nokia copyrights with correct Digia copyrights. Text in front of copyright is now retained: ** File is part of Foo, Copyright Nokia... -> ** File is part of Foo, Copyright Digia... Replaced Nokia contact details with Digia's. Removing "All Rights Reserved" no longer leaves an empty line. Used the following command: find . -path '*/3rdparty/*' -prune -o -exec grep -ilI -E '.*Copyright.*Nokia.*|.*Contact.*Nokia.*' {} \; | tee >(xargs sed -i -r '1,50 { /INdT/ !{ s/(^[ \t:#*]*)([a-z ]*)(Copyright.*Nokia.*)/ \1\2Copyright \(C\) 2013 Digia Plc and\/or its subsidiary\(-ies\)\./I } }') >(xargs sed -i -r '1,50 s/(^[ \t:#*]*)(.*info@qt\.nokia\.com.* |.*INSERT EMAIL ADDRESS.*|.*qt-info@nokia\.com.* |.*qt-label1@nokia\.com.*|.*http:\/\/qt\.nokia\.com\/contact.* |.*qt-sales@nokia\.com.*) /\1Contact: http:\/\/www\.qt-project\.org\/legal/I') >(xargs sed -i -r '1,50{/(^[ \t:#*]*)(all rights reserved.*)/Id}') Change-Id: I5d1a59e0f450d630a615df61ca23ac1d3185cb84 Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Fixed licensesTeemu Kaukoranta2013-05-239-177/+178
| | | | | | | | | Updated licenses using replace-licenses.zsh from mkdist repo. Possible copyright and contact changes will come later. Change-Id: Idcbc937d184c0f8b027044a8d1157a17ff87dd6d Reviewed-by: Janne Anttila <janne.anttila@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Revert "Add some symbols so we preserve BC."Lincoln Ramsay2012-06-062-114/+1
| | | | | | | | | These symbols are no longer needed. This reverts commit 2e636e534b81538841694dd392c0aff30d7debb8. Change-Id: I27581fdc7ef94ee58996206eada0dedffd1a5bf0 Reviewed-by: Zsolt Simon <zsolt.simon@nokia.com>
* Re-define the macros to avoid ambiguous else warnings.Lincoln Ramsay2012-06-011-26/+14
| | | | | | | | | | Using if (condition) qCDebug(CAT) << "message"; provokes an ambiguous else warning from the compiler. Using this form of loop avoids this warning yet compiles to the same quick "do nothing" logic. Change-Id: Ic8b025de5b6270dc981c9736201c8105a697c39c Reviewed-by: Zsolt Simon <zsolt.simon@nokia.com>
* Delay initialization of the logging system.Lincoln Ramsay2012-05-313-96/+93
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Apparently I didn't run the unit tests at some point because they were failing. The ultimate cause was the default category object, which is constructed before main(). It was causing the logging system to be initialized early and the unit test's qputenv() was being ignored. However, we want the logging system to delay initialization until someone explicitly calls a logging-related function. The solution is to delay setting the _enabledDebug flag on the default category object until the logging system is initialized. However, for this to work, the d_func() method had to be moved into QLoggingPrivate to avoid a recursive call to qLogging(). Since d_func() and the code in ~QLoggingCategory() deals primarily with structures owned by QLoggingPrivate anyway, this works well. There was also a code path where the environment checking code wasn't being called. Rather than inserting more calls to checkEnvironment(), I made that a simple getter and now check the environment from the QLoggingPrivate constructor. After all this, the unit tests pass again :) Change-Id: I97fdfa7e7dd92ea620618a426fe309a535d917bc Reviewed-by: Zsolt Simon <zsolt.simon@nokia.com>
* Upgrade const char * to QString message handlers.Lincoln Ramsay2012-05-313-13/+13
| | | | | | | | | The const char * based message handler functions will be removed so update the code to use the new QString based message handler functions. Change-Id: I9f80cdc86d7e344934c4339452d2de9442f1168d Reviewed-by: Zsolt Simon <zsolt.simon@nokia.com>
* Add some symbols so we preserve BC.Lincoln Ramsay2012-05-312-1/+114
| | | | | | | | This is a temporary fix to allow us to upgrade in-use versions of qlogger more easily. This is a hack and will be removed shortly. Change-Id: I14c56796adc9555e6e8380f99647b457bf8a5a18 Reviewed-by: Zsolt Simon <zsolt.simon@nokia.com>
* Don't crash during app shutdown.Lincoln Ramsay2012-05-282-102/+97
| | | | | | | | | | | | | | | | | | | We have an object with a well-defined lifetime (QLoggingPrivate) but we also have a bunch of global static objects. The differing lifetime causes problems during app shutdown that lead to crashes. We can simplify this by just putting everything into QLoggingPrivate. When this object no longer exists, we know the app is shutting down and can act appropriately (eg. don't try to check the environment, don't try to register or unregister category objects). The default category object remains as a global static so that calls to qDebug() can still work while the app is shutting down. Change-Id: I934c1d92e7666368fd2c8a35d79835953afc2f69 Reviewed-by: Andrew Stanley-Jones <andrew.stanley-jones@nokia.com> Reviewed-by: Lorn Potter <lorn.potter@nokia.com> Reviewed-by: Zsolt Simon <zsolt.simon@nokia.com>
* don't install .pro files, .cpp filesLincoln Ramsay2012-05-142-9/+5
| | | | | | | Just install the app and its data Change-Id: I518118262de9406801ae1143e42d9cd2cba4ae30 Reviewed-by: Wolfgang Beck <wolfgang.beck@nokia.com>
* Fix ordering of these macrosLincoln Ramsay2012-05-142-2/+2
| | | | | Change-Id: Ie210b824f293b0438b3f9a841da5329c14f922c5 Reviewed-by: Wolfgang Beck <wolfgang.beck@nokia.com>
* QT_BUILD_INTERNAL and Q_AUTOTEST_EXPORT are evilLincoln Ramsay2012-05-142-5/+1
| | | | | | | | These prevent normal builds from running and being tested. Just get rid of them. Change-Id: I416f3c4368a270a8a8fcf4d7acf1491860438cb7 Reviewed-by: Wolfgang Beck <wolfgang.beck@nokia.com>
* QLogger should use category of QMessageLoggerWolfgang Beck2012-05-113-117/+83
| | | | | Change-Id: I4d91314f2d18375025ec87d21a66d74a3d380c39 Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com>
* Using QLoggingCategory without QT_LOG_CATEGORY macroWolfgang Beck2012-05-117-182/+494
| | | | | Change-Id: I086107777d49f1b9f6bc2396b8276f333ecd0e85 Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com>
* Unregister categories on destruction.Lincoln Ramsay2012-05-013-1/+27
| | | | | | | | | | | | If we're going to do this we should really provide explicit support for registering categories without the macro. Use cases include registering categories from a plugin (which may then be unloaded) as well as registering categories for a dynamic binding (easier to do without statically-declared categories). Change-Id: I72c4ef8d8189a97658087c1a892be39b575b9e2c Reviewed-by: Wolfgang Beck <wolfgang.beck@nokia.com>
* Renaming unit test executablesWolfgang Beck2012-05-012-2/+2
| | | | | Change-Id: Ie1febdaeb67c431ed2fd4f8fc7cca6a4e060599f Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com>
* Ensure Filewatcher is created on the Application thread.Wolfgang Beck2012-04-305-13/+317
| | | | | Change-Id: I6e8a41408801103c2013e3e30adf83f4f3d6bb93 Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com>
* Doc update.Lincoln Ramsay2012-04-264-36/+106
| | | | | Change-Id: Ibb7b814016ab352d57ddf415d52ad73d3229de35 Reviewed-by: Wolfgang Beck <wolfgang.beck@nokia.com>
* Refactor "startup" logic.Lincoln Ramsay2012-04-262-48/+70
| | | | | | | | | | | | | | The first call to isEnabled() will cause the QT_LOGGING_CONFIG environment variable to be checked. Or if qSetLoggingRules[File]() is called, this will also check the environment variable. The QLoggingPrivate object is created only if a valid config file can be found or a non-empty set of rules is given. Change-Id: I5ed4a14e4ef105bb65663edd62c4e79761010b55 Reviewed-by: Wolfgang Beck <wolfgang.beck@nokia.com>
* Include <QDebug> otherwise everyone else has to do it.Lincoln Ramsay2012-04-201-1/+2
| | | | | | | | This also resolves the problem of including qlogger.h before QDebug. Now you can't do that. Change-Id: Ie78993cf4037d8748571d03d8b79cba9ee1935c8 Reviewed-by: Wolfgang Beck <wolfgang.beck@nokia.com>
* Create category logging moduleWolfgang Beck2012-04-0423-0/+2049
| | | | | | Change-Id: I12bd44a23e92abb8938af9b7ee22ffcae0391d8d Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com> Reviewed-by: Wolfgang Beck <wolfgang.beck@nokia.com>
* Initial commitSergio Ahumada2012-03-290-0/+0