[arch-commits] Commit in kdelibs/trunk (5 files)
Pierre Schmitz
pierre at archlinux.org
Fri Mar 27 14:20:30 UTC 2009
Date: Friday, March 27, 2009 @ 10:20:30
Author: pierre
Revision: 31492
KDE 4.2.2 (try #1)
Modified:
kdelibs/trunk/PKGBUILD
Deleted:
kdelibs/trunk/kde-r934640.patch
kdelibs/trunk/kde-r938348.patch
kdelibs/trunk/kde-r938370.patch
kdelibs/trunk/kde-r938657.patch
-------------------+
PKGBUILD | 27 --
kde-r934640.patch | 654 ----------------------------------------------------
kde-r938348.patch | 27 --
kde-r938370.patch | 57 ----
kde-r938657.patch | 13 -
5 files changed, 10 insertions(+), 768 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2009-03-27 13:47:48 UTC (rev 31491)
+++ PKGBUILD 2009-03-27 14:20:30 UTC (rev 31492)
@@ -2,8 +2,8 @@
# Maintainer: Pierre Schmitz <pierre at archlinux.de>
pkgname=kdelibs
-pkgver=4.2.1
-pkgrel=3
+pkgver=4.2.2
+pkgrel=1
pkgdesc="KDE Core Libraries"
arch=('i686' 'x86_64')
url='http://www.kde.org'
@@ -17,32 +17,25 @@
options=('docs')
install='kdelibs.install'
source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.bz2"
- 'kde-applications-menu.patch' 'archlinux-menu.patch'
- 'kde-r934640.patch' 'kde-r938348.patch' 'kde-r938370.patch' 'kde-r938657.patch')
-md5sums=('fa4206dd747890c4e4283c8adb831e6c'
+ 'kde-applications-menu.patch' 'archlinux-menu.patch')
+md5sums=('c60ab0b2efca14ed8913ac702de94666'
'e94450ba5430ea9c1e33bad9ae38ca2d'
- '0ad42200df2d2b8aab01d2ef4b21e02f'
- '9b5290f23dbea83b7fabd638cb26687b'
- 'c13c5e7570fdfb08a4b3c3e344eb026b'
- '688151661aa1f7022847cae1e4b3c8da'
- '4ce23b4a2a2b1ddd9ed6e0e15a0711b0')
+ '0ad42200df2d2b8aab01d2ef4b21e02f')
build() {
cd $srcdir/${pkgname}-${pkgver}
- # fix utf8 handling; see https://bugs.kde.org/show_bug.cgi?id=186038
- patch -p1 -i $srcdir/kde-r934640.patch || return 1
- patch -p1 -i $srcdir/kde-r938348.patch || return 1
- patch -p1 -i $srcdir/kde-r938370.patch || return 1
- patch -p1 -i $srcdir/kde-r938657.patch || return 1
+
# avoid file conflict with gnome-menu
- patch -p1 -i $srcdir/kde-applications-menu.patch || return 1
+ patch -p1 -i $srcdir/kde-applications-menu.patch
# add Archlinux menu entry
- patch -p0 -i $srcdir/archlinux-menu.patch || return 1
+ patch -p0 -i $srcdir/archlinux-menu.patch
cd ..
mkdir build
cd build
cmake ../${pkgname}-${pkgver} \
-DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_SKIP_RPATH=ON \
+ -DCMAKE_{SHARED,MODULE,EXE}_LINKER_FLAGS='-Wl,--no-undefined -Wl,--as-needed' \
-DKDE_DISTRIBUTION_TEXT='Arch Linux' \
-DCMAKE_INSTALL_PREFIX=/usr \
-DSYSCONF_INSTALL_DIR=/etc \
Deleted: kde-r934640.patch
===================================================================
--- kde-r934640.patch 2009-03-27 13:47:48 UTC (rev 31491)
+++ kde-r934640.patch 2009-03-27 14:20:30 UTC (rev 31492)
@@ -1,654 +0,0 @@
-Index: kdelibs/kdecore/kernel/kcmdlineargs.cpp
-===================================================================
---- kdelibs/kdecore/kernel/kcmdlineargs.cpp (Revision 934639)
-+++ kdelibs/kdecore/kernel/kcmdlineargs.cpp (Revision 934640)
-@@ -83,13 +83,13 @@
- // Helper classes
- //
-
--class KCmdLineParsedOptions : public QHash<QString,QString>
-+class KCmdLineParsedOptions : public QHash<QByteArray,QByteArray>
- {
- public:
- KCmdLineParsedOptions() { }
- };
-
--class KCmdLineParsedArgs : public QList<QString>
-+class KCmdLineParsedArgs : public QList<QByteArray>
- {
- public:
- KCmdLineParsedArgs() { }
-@@ -112,7 +112,7 @@
-
- class KCmdLineOptionsPrivate {
- public:
-- QStringList names;
-+ QList<QByteArray> names;
- QList<KLocalizedString> descriptions;
- QStringList defaults;
- };
-@@ -143,7 +143,7 @@
- const KLocalizedString &description,
- const QByteArray &defaultValue)
- {
-- d->names.append(QString::fromUtf8(name));
-+ d->names.append(name);
- d->descriptions.append(description);
- d->defaults.append(QString::fromUtf8(defaultValue));
- return *this;
-@@ -171,7 +171,7 @@
- char **argv; // The original argv
- bool parsed : 1; // Whether we have parsed the arguments since calling init
- bool ignoreUnknown : 1; // Ignore unknown options and arguments
-- QString mCwd; // Current working directory. Important for KUnqiueApp!
-+ QByteArray mCwd; // Current working directory. Important for KUnqiueApp!
- KCmdLineArgs::StdCmdLineArgs mStdargs;
-
- KCmdLineOptions qt_options;
-@@ -220,15 +220,15 @@
- *
- * +4 - no more options follow // !fork
- */
-- static int findOption(const KCmdLineOptions &options, QString &opt,
-- QString &opt_name, QString &def, bool &enabled);
-+ static int findOption(const KCmdLineOptions &options, QByteArray &opt,
-+ QByteArray &opt_name, QString &def, bool &enabled);
-
- /**
- * @internal
- *
- * Checks what to do with a single option
- */
-- static void findOption(const QString &optv, const QString &_opt,
-+ static void findOption(const QByteArray &optv, const QByteArray &_opt,
- int &i, bool _enabled, bool &moreOptions);
-
- /**
-@@ -246,7 +246,7 @@
- *
- * @param id The name of the options to be removed.
- */
-- static void removeArgs(const QString &id);
-+ static void removeArgs(const QByteArray &id);
- };
-
- K_GLOBAL_STATIC(KCmdLineArgsStatic, s)
-@@ -336,7 +336,7 @@
- {
- friend class KCmdLineArgsStatic;
- public:
-- KCmdLineArgsPrivate(const KCmdLineOptions &_options, const KLocalizedString &_name, const QString &_id)
-+ KCmdLineArgsPrivate(const KCmdLineOptions &_options, const KLocalizedString &_name, const QByteArray &_id)
- : options(_options)
- , name(_name)
- , id(_id)
-@@ -351,7 +351,7 @@
- }
- const KCmdLineOptions options;
- const KLocalizedString name;
-- const QString id;
-+ const QByteArray id;
- KCmdLineParsedOptions *parsedOptionList;
- KCmdLineParsedArgs *parsedArgList;
- bool isQt;
-@@ -361,21 +361,21 @@
- *
- * Set a boolean option
- */
-- void setOption(const QString &option, bool enabled);
-+ void setOption(const QByteArray &option, bool enabled);
-
- /**
- * @internal
- *
- * Set a string option
- */
-- void setOption(const QString &option, const QString &value);
-+ void setOption(const QByteArray &option, const QByteArray &value);
-
- /**
- * @internal
- *
- * Add an argument
- */
-- void addArgument(const QString &argument);
-+ void addArgument(const QByteArray &argument);
-
- /**
- * @internal
-@@ -469,13 +469,13 @@
-
- s->about = _about;
- s->parsed = false;
-- s->mCwd = QDir::currentPath();
-+ s->mCwd = QDir::currentPath().toLocal8Bit(); //currentPath() uses fromLocal8Bit internally apparently
- addStdCmdLineOptions(stdargs);
- }
-
- QString KCmdLineArgs::cwd()
- {
-- return s->mCwd;
-+ return QString::fromLocal8Bit(s->mCwd);
- }
-
- QString KCmdLineArgs::appName()
-@@ -499,14 +499,11 @@
-
- void
- KCmdLineArgs::addCmdLineOptions( const KCmdLineOptions &options, const KLocalizedString &name,
-- const QByteArray &_id, const QByteArray &_afterId)
-+ const QByteArray &id, const QByteArray &afterId)
- {
- if (!s->argsList)
- s->argsList = new KCmdLineArgsList;
-
-- QString id = QString::fromUtf8(_id);
-- QString afterId = QString::fromUtf8(_afterId);
--
- int pos = s->argsList->count();
- // To make sure that the named options come before unnamed.
- if (pos > 0 && !id.isEmpty() && s->argsList->last()->d->name.isEmpty())
-@@ -527,7 +524,7 @@
-
- Q_ASSERT( s->parsed == false ); // You must add _ALL_ cmd line options
- // before accessing the arguments!
-- s->argsList->insert(pos, new KCmdLineArgs(options, name, id.toUtf8()));
-+ s->argsList->insert(pos, new KCmdLineArgs(options, name, id));
- }
-
- void
-@@ -540,8 +537,7 @@
- s->removeArgs("qt");
- s->removeArgs("kde");
-
-- QByteArray qCwd = QFile::encodeName(s->mCwd);
-- ds << qCwd;
-+ ds << s->mCwd;
-
- uint count = s->argsList ? s->argsList->count() : 0;
- ds << count;
-@@ -579,16 +575,15 @@
- QByteArray qCwd;
- ds >> qCwd;
-
-- s->mCwd = QFile::decodeName(qCwd); //FIXME: Is this proper decoding?
-+ s->mCwd = qCwd;
-
- uint count;
- ds >> count;
-
- while(count--)
- {
-- QByteArray idRaw;
-- ds >> idRaw;
-- QString id = idRaw; //FIXME: What about decoding?
-+ QByteArray id;
-+ ds >> id;
- Q_ASSERT( s->argsList );
- for(args = s->argsList->begin(); args != s->argsList->end(); ++args)
- {
-@@ -602,9 +597,8 @@
- s->parsed = true;
- }
-
--KCmdLineArgs *KCmdLineArgs::parsedArgs(const QByteArray &_id)
-+KCmdLineArgs *KCmdLineArgs::parsedArgs(const QByteArray &id)
- {
-- QString id = QString::fromUtf8(_id);
- if (!s->argsList)
- return 0;
- KCmdLineArgsList::Iterator args = s->argsList->begin();
-@@ -622,7 +616,7 @@
- return 0;
- }
-
--void KCmdLineArgsStatic::removeArgs(const QString &id)
-+void KCmdLineArgsStatic::removeArgs(const QByteArray &id)
- {
- if (!s->argsList)
- return;
-@@ -646,8 +640,8 @@
- }
-
- int
--KCmdLineArgsStatic::findOption(const KCmdLineOptions &options, QString &opt,
-- QString &opt_name, QString &def, bool &enabled)
-+KCmdLineArgsStatic::findOption(const KCmdLineOptions &options, QByteArray &opt,
-+ QByteArray &opt_name, QString &def, bool &enabled)
- {
- int result;
- bool inverse;
-@@ -686,7 +680,7 @@
- i++;
- if (i >= options.d->names.size())
- return result+0;
-- QString nextOption = options.d->names[i];
-+ QByteArray nextOption = options.d->names[i];
- int p = nextOption.indexOf(' ');
- if (p > 0)
- nextOption = nextOption.left(p);
-@@ -717,14 +711,14 @@
- }
-
- void
--KCmdLineArgsStatic::findOption(const QString &optv, const QString &_opt,
-+KCmdLineArgsStatic::findOption(const QByteArray &optv, const QByteArray &_opt,
- int &i, bool _enabled, bool &moreOptions)
- {
- KCmdLineArgsList::Iterator args = s->argsList->begin();
-- QString opt = _opt;
-- QString opt_name;
-+ QByteArray opt = _opt;
-+ QByteArray opt_name;
- QString def;
-- QString argument;
-+ QByteArray argument;
- int j = opt.indexOf('=');
- if (j != -1)
- {
-@@ -753,7 +747,7 @@
- int p = 1;
- while (true)
- {
-- QString singleCharOption = " ";
-+ QByteArray singleCharOption = " ";
- singleCharOption[0] = optv[p];
- args = s->argsList->begin();
- while (args != s->argsList->end())
-@@ -800,7 +794,7 @@
- return;
- #endif
- KCmdLineArgs::enable_i18n();
-- KCmdLineArgs::usageError( i18n("Unknown option '%1'.", _opt));
-+ KCmdLineArgs::usageError( i18n("Unknown option '%1'.", QString::fromLocal8Bit(_opt)));
- }
-
- if ((result & 4) != 0)
-@@ -820,7 +814,7 @@
- return;
- #endif
- KCmdLineArgs::enable_i18n();
-- KCmdLineArgs::usageError( i18n("Unknown option '%1'.", _opt));
-+ KCmdLineArgs::usageError( i18n("Unknown option '%1'.", QString::fromLocal8Bit(_opt)));
- }
- if (argument.isEmpty())
- {
-@@ -828,9 +822,9 @@
- if (i >= s->argc)
- {
- KCmdLineArgs::enable_i18n();
-- KCmdLineArgs::usageError( i18nc("@info:shell %1 is cmdoption name","'%1' missing.", opt_name));
-+ KCmdLineArgs::usageError( i18nc("@info:shell %1 is cmdoption name","'%1' missing.", QString::fromLocal8Bit(opt_name)));
- }
-- argument = s->decodeInput(s->argv[i]);
-+ argument = s->argv[i];
- }
- (*args)->d->setOption(opt, argument);
- }
-@@ -849,16 +843,10 @@
- KCmdLineArgs *appOptions = s->argsList->last();
- if (appOptions->d->id.isEmpty())
- {
-- const KCmdLineOptions &option = appOptions->d->options;
-- for (int i = 0; i < option.d->names.size(); i++)
-+ foreach(const QByteArray& name, appOptions->d->options.d->names)
- {
-- if (option.d->names[i].startsWith('+'))
-- allowArgs = true;
-- if ( option.d->names[i].startsWith("!+") )
-- {
-- allowArgs = true;
-- everythingAfterArgIsArgs = true;
-- }
-+ everythingAfterArgIsArgs = everythingAfterArgIsArgs || name.startsWith("!+");
-+ allowArgs = allowArgs || name.startsWith('+') || everythingAfterArgIsArgs;
- }
- }
- for(int i = 1; i < s->argc; i++)
-@@ -869,8 +857,8 @@
- if ((s->argv[i][0] == '-') && s->argv[i][1] && inOptions)
- {
- bool enabled = true;
-- QString orig = decodeInput(s->argv[i]);
-- QString option = orig.mid(1);
-+ QByteArray orig = s->argv[i];
-+ QByteArray option = orig.mid(1);
- if (option.startsWith('-'))
- {
- option = option.mid(1);
-@@ -887,7 +875,7 @@
- }
- else if (option.startsWith("help-"))
- {
-- KCmdLineArgs::usage(option.mid(5).toUtf8());
-+ KCmdLineArgs::usage(option.mid(5));
- }
- else if ((option == "version") || (option == "v"))
- {
-@@ -924,9 +912,8 @@
- {
- if (s->about->bugAddress().isEmpty() || s->about->bugAddress() == "submit at bugs.kde.org" )
- s->printQ( i18n( "Please use http://bugs.kde.org to report bugs.\n" ) );
-- else {
-+ else
- s->printQ( i18n( "Please report bugs to %1.\n" , s->about->bugAddress()) );
-- }
- }
- else
- {
-@@ -955,7 +942,7 @@
- }
- else
- {
-- appOptions->d->addArgument(s->decodeInput(s->argv[i]));
-+ appOptions->d->addArgument(s->argv[i]);
- if (everythingAfterArgIsArgs)
- inOptions = false;
- }
-@@ -1009,7 +996,7 @@
- if (!(s->mStdargs & KCmdLineArgs::CmdLineArgQt))
- {
- s_qt_argv = new char*[2];
-- s_qt_argv[0] = qstrdup(s->encodeOutput(appName()));
-+ s_qt_argv[0] = qstrdup(s->argc?s->argv[0]:"");
- s_qt_argv[1] = 0;
-
- return s_qt_argv;
-@@ -1026,12 +1013,13 @@
- exit(255);
- }
-
-- s_qt_argv = new char*[ args->count() + 2 ];
-- s_qt_argv[0] = qstrdup(s->encodeOutput(appName()));
-+ int count=args->count();
-+ s_qt_argv = new char*[ count + 2 ];
-+ s_qt_argv[0] = qstrdup(s->argc?s->argv[0]:"");
- int i = 0;
-- for(; i < args->count(); i++)
-+ for(; i < count; i++)
- {
-- s_qt_argv[i+1] = qstrdup(s->encodeOutput(args->arg(i)));
-+ s_qt_argv[i+1] = qstrdup(args->d->parsedArgList->at(i));
- }
- s_qt_argv[i+1] = 0;
-
-@@ -1110,7 +1098,7 @@
- const KCmdLineOptions &option = appOptions->d->options;
- for (int i = 0; i < option.d->names.size(); i++)
- {
-- QString opt_name = option.d->names[i];
-+ QByteArray opt_name = option.d->names[i];
- if (opt_name.startsWith('+'))
- usage = usage + (opt_name.mid(1)) + ' ';
- else if ( opt_name.startsWith("!+") )
-@@ -1129,7 +1117,7 @@
- {
- if (!(*args)->d->name.isEmpty() && !(*args)->d->id.isEmpty())
- {
-- QString option = QString("--help-%1").arg((*args)->d->id);
-+ QString option = QString("--help-%1").arg(QString::fromLatin1((*args)->d->id));
- QString desc = i18n("Show %1 specific options", (*args)->d->name.toString());
-
- s->printQ(optionFormatString.arg(option, -25).arg(desc));
-@@ -1169,7 +1157,7 @@
- while (args != s->argsList->end())
- {
- const KCmdLineOptions &option = (*args)->d->options;
-- QString opt;
-+ QByteArray opt;
-
- for (int i = 0; i < option.d->names.size(); i++)
- {
-@@ -1214,7 +1202,7 @@
- description = dl.first();
- dl.erase( dl.begin() );
- }
-- QString name = option.d->names[i];
-+ QByteArray name = option.d->names[i];
- if (name.startsWith('!'))
- name = name.mid(1);
-
-@@ -1229,7 +1217,7 @@
- name = name.mid(1);
- if (name.startsWith('[') && name.endsWith(']'))
- name = name.mid(1, name.length()-2);
-- s->printQ(optionFormatString.arg(name, -25).arg(description));
-+ s->printQ(optionFormatString.arg(QString::fromLocal8Bit(name), -25).arg(description));
- }
- else
- {
-@@ -1259,7 +1247,7 @@
- s->printQ(optionFormatStringDef.arg(QString( opt ), -25)
- .arg(description, option.d->defaults[i]));
- }
-- opt = "";
-+ opt.clear();
- }
- }
- for(QStringList::Iterator it = dl.begin();
-@@ -1309,24 +1297,21 @@
- void
- KCmdLineArgs::setCwd( const QByteArray &cwd )
- {
-- s->mCwd = QString::fromUtf8(cwd);
-+ s->mCwd = cwd;
- }
-
- void
- KCmdLineArgs::clear()
- {
-- delete d->parsedArgList;
-- d->parsedArgList = 0;
-- delete d->parsedOptionList;
-- d->parsedOptionList = 0;
-+ delete d->parsedArgList; d->parsedArgList = 0;
-+ delete d->parsedOptionList; d->parsedOptionList = 0;
- }
-
- void
- KCmdLineArgs::reset()
- {
- if ( s->argsList ) {
-- delete s->argsList;
-- s->argsList = 0;
-+ delete s->argsList; s->argsList = 0;
- }
- s->parsed = false;
- }
-@@ -1356,23 +1341,21 @@
-
- if (parsedOptionList->count() == 0)
- {
-- delete parsedOptionList;
-- parsedOptionList = 0;
-+ delete parsedOptionList; parsedOptionList = 0;
- }
- if (parsedArgList->count() == 0)
- {
-- delete parsedArgList;
-- parsedArgList = 0;
-+ delete parsedArgList; parsedArgList = 0;
- }
- }
-
- void
--KCmdLineArgsPrivate::setOption(const QString &opt, bool enabled)
-+KCmdLineArgsPrivate::setOption(const QByteArray &opt, bool enabled)
- {
- if (isQt)
- {
- // Qt does it own parsing.
-- QString argString = "-";
-+ QByteArray argString = "-";
- if( !enabled )
- argString += "no";
- argString += opt;
-@@ -1383,18 +1366,18 @@
- }
-
- if (enabled)
-- parsedOptionList->insert( opt, QString::fromUtf8("t") );
-+ parsedOptionList->insert( opt, "t" );
- else
-- parsedOptionList->insert( opt, QString::fromUtf8("f") );
-+ parsedOptionList->insert( opt, "f" );
- }
-
- void
--KCmdLineArgsPrivate::setOption(const QString &opt, const QString &value)
-+KCmdLineArgsPrivate::setOption(const QByteArray &opt, const QByteArray &value)
- {
- if (isQt)
- {
- // Qt does it's own parsing.
-- QString argString = "-";
-+ QByteArray argString = "-";
- argString += opt;
- addArgument(argString);
- addArgument(value);
-@@ -1403,7 +1386,7 @@
- // Hack coming up!
- if (argString == "-display")
- {
-- setenv(DISPLAY, s->encodeOutput(value).data(), true);
-+ setenv(DISPLAY, value.data(), true);
- }
- #endif
- }
-@@ -1417,8 +1400,8 @@
- QString
- KCmdLineArgs::getOption(const QByteArray &_opt) const
- {
-- QString opt = QString::fromUtf8(_opt);
-- QString value;
-+ QByteArray opt = _opt;
-+ QByteArray value;
- if (d->parsedOptionList)
- {
- value = d->parsedOptionList->value(opt);
-@@ -1427,7 +1410,7 @@
- return value;
-
- // Look up the default.
-- QString opt_name;
-+ QByteArray opt_name;
- QString def;
- bool dummy = true;
- int result = s->findOption( d->options, opt, opt_name, def, dummy) & ~4;
-@@ -1436,7 +1419,7 @@
- {
- fprintf(stderr, "\n\nFAILURE (KCmdLineArgs):\n");
- fprintf(stderr, "Application requests for getOption(\"%s\") but the \"%s\" option\n",
-- s->encodeOutput(opt).data(), s->encodeOutput(opt).data());
-+ opt.data(), opt.data());
- fprintf(stderr, "has never been specified via addCmdLineOptions( ... )\n\n");
-
- Q_ASSERT( 0 );
-@@ -1446,20 +1429,18 @@
- }
-
- QStringList
--KCmdLineArgs::getOptionList(const QByteArray &_opt) const
-+KCmdLineArgs::getOptionList(const QByteArray &opt) const
- {
-- QString opt = QString::fromUtf8(_opt);
--
- QStringList result;
- if (!d->parsedOptionList)
- return result;
-
- while(true)
- {
-- QString value = d->parsedOptionList->take(opt);
-+ QByteArray value = d->parsedOptionList->take(opt);
- if (value.isEmpty())
- break;
-- result.prepend(value);
-+ result.prepend(QString::fromLocal8Bit(value));
- }
-
- // Reinsert items in dictionary
-@@ -1469,7 +1450,7 @@
- // So taking them out and then putting them back is the only way.
- Q_FOREACH(const QString &str, result)
- {
-- d->parsedOptionList->insertMulti(opt, str);
-+ d->parsedOptionList->insertMulti(opt, str.toLocal8Bit());
- }
- return result;
- }
-@@ -1478,8 +1459,8 @@
- KCmdLineArgs::isSet(const QByteArray &_opt) const
- {
- // Look up the default.
-- QString opt = QString::fromUtf8(_opt);
-- QString opt_name;
-+ QByteArray opt = _opt;
-+ QByteArray opt_name;
- QString def;
- int result = 0;
- KCmdLineArgsList::Iterator args = s->argsList->begin();
-@@ -1495,14 +1476,14 @@
- {
- fprintf(stderr, "\n\nFAILURE (KCmdLineArgs):\n");
- fprintf(stderr, "Application requests for isSet(\"%s\") but the \"%s\" option\n",
-- s->encodeOutput(opt).data(), s->encodeOutput(opt).data());
-+ opt.data(), opt.data());
- fprintf(stderr, "has never been specified via addCmdLineOptions( ... )\n\n");
-
- Q_ASSERT( 0 );
- exit(255);
- }
-
-- QString value;
-+ QByteArray value;
- if (d->parsedOptionList)
- {
- value = d->parsedOptionList->value(opt);
-@@ -1513,7 +1494,7 @@
- if (result == 3)
- return true;
- else
-- return (value[0] == 't');
-+ return (value.at(0) == 't');
- }
-
- if (result == 3)
-@@ -1527,9 +1508,7 @@
- int
- KCmdLineArgs::count() const
- {
-- if (!d->parsedArgList)
-- return 0;
-- return d->parsedArgList->count();
-+ return d->parsedArgList?d->parsedArgList->count():0;
- }
-
- QString
-@@ -1545,7 +1524,7 @@
- exit(255);
- }
-
-- return d->parsedArgList->at(n);
-+ return QString::fromLocal8Bit(d->parsedArgList->at(n));
- }
-
- KUrl
-@@ -1575,7 +1554,7 @@
- }
-
- void
--KCmdLineArgsPrivate::addArgument(const QString &argument)
-+KCmdLineArgsPrivate::addArgument(const QByteArray &argument)
- {
- if (!parsedArgList)
- parsedArgList = new KCmdLineParsedArgs;
-@@ -1594,7 +1573,5 @@
- bool KCmdLineArgs::isTempFileSet()
- {
- KCmdLineArgs* args = KCmdLineArgs::parsedArgs( "kde-tempfile" );
-- if ( args )
-- return args->isSet( "tempfile" );
-- return false;
-+ return args && args->isSet( "tempfile" );
- }
Deleted: kde-r938348.patch
===================================================================
--- kde-r938348.patch 2009-03-27 13:47:48 UTC (rev 31491)
+++ kde-r938348.patch 2009-03-27 14:20:30 UTC (rev 31492)
@@ -1,27 +0,0 @@
---- kdelibs/kdecore/localization/kencodingdetector.cpp 2009/03/11 16:32:16 938347
-+++ kdelibs/kdecore/localization/kencodingdetector.cpp 2009/03/11 16:37:50 938348
-@@ -1052,10 +1052,8 @@
- }
-
- if (len<20)
-- {
-- setEncoding("",DefaultEncoding);
- return false;
-- }
-+
- #ifdef DECODE_DEBUG
- kDebug( 6005 ) << "KEncodingDetector: using heuristics (" << strlen(data) << ")";
- #endif
-@@ -1110,10 +1108,9 @@
- // huh. somethings broken in this code ### FIXME
- //enc = 0; //Reset invalid codec we tried, so we get back to latin1 fallback.
- break;
-- }
-+ }
-
-- setEncoding("",DefaultEncoding);
-- return true;
-+ return true;
- }
-
-
Deleted: kde-r938370.patch
===================================================================
--- kde-r938370.patch 2009-03-27 13:47:48 UTC (rev 31491)
+++ kde-r938370.patch 2009-03-27 14:20:30 UTC (rev 31492)
@@ -1,57 +0,0 @@
---- kdelibs/kdecore/localization/kcatalog.cpp 2009/03/11 18:07:25 938369
-+++ kdelibs/kdecore/localization/kcatalog.cpp 2009/03/11 18:08:04 938370
-@@ -30,6 +30,24 @@
- #include <locale.h>
- #include "gettext.h"
-
-+
-+static bool s_localeSet = false;
-+
-+// Initialize the locale very early during application startup
-+// This is necessary for e.g. toLocal8Bit() to work, even before
-+// a Q[Core]Application exists (David)
-+int kInitializeLocale()
-+{
-+ setlocale(LC_ALL, "");
-+#if QT_VERSION >= 0x040500
-+ extern Q_CORE_EXPORT bool qt_locale_initialized; // in Qt since 4.5.0
-+ qt_locale_initialized = true; // as recommended by Thiago
-+#endif
-+ s_localeSet = true;
-+ return 1;
-+}
-+Q_CONSTRUCTOR_FUNCTION(kInitializeLocale)
-+
- // not defined on win32 :(
- #ifdef _WIN32
- # ifndef LC_MESSAGES
-@@ -50,7 +68,6 @@
-
- QByteArray systemLanguage;
-
-- static int localeSet;
- static QByteArray currentLanguage;
-
- void setupGettextEnv ();
-@@ -62,17 +79,15 @@
- return debug << c.d->language << " " << c.d->name << " " << c.d->localeDir;
- }
-
--int KCatalogPrivate::localeSet = 0;
- QByteArray KCatalogPrivate::currentLanguage;
-
- KCatalog::KCatalog(const QString & name, const QString & language )
- : d( new KCatalogPrivate )
- {
-- // Set locales only once.
-- if (! KCatalogPrivate::localeSet) {
-- setlocale(LC_ALL, "");
-- KCatalogPrivate::localeSet = 1;
-- }
-+ // Set locales if the static initializer didn't work
-+ if (!s_localeSet) {
-+ kInitializeLocale();
-+ }
-
- // Find locale directory for this catalog.
- QString localeDir = catalogLocaleDir( name, language );
Deleted: kde-r938657.patch
===================================================================
--- kde-r938657.patch 2009-03-27 13:47:48 UTC (rev 31491)
+++ kde-r938657.patch 2009-03-27 14:20:30 UTC (rev 31492)
@@ -1,13 +0,0 @@
-Index: kdelibs/kdecore/kernel/kcmdlineargs.cpp
-===================================================================
---- kdelibs/kdecore/kernel/kcmdlineargs.cpp (Revision 938656)
-+++ kdelibs/kdecore/kernel/kcmdlineargs.cpp (Revision 938657)
-@@ -1407,7 +1407,7 @@
- value = d->parsedOptionList->value(opt);
- }
- if (!value.isEmpty())
-- return value;
-+ return QString::fromLocal8Bit(value);
-
- // Look up the default.
- QByteArray opt_name;
More information about the arch-commits
mailing list