Date: Wednesday, December 25, 2019 @ 23:46:44 Author: felixonmars Revision: 541505
archrelease: copy trunk to community-x86_64 Added: cppcheck/repos/community-x86_64/PKGBUILD (from rev 541504, cppcheck/trunk/PKGBUILD) cppcheck/repos/community-x86_64/translations-location.patch (from rev 541504, cppcheck/trunk/translations-location.patch) Deleted: cppcheck/repos/community-x86_64/PKGBUILD cppcheck/repos/community-x86_64/translations-location.patch -----------------------------+ PKGBUILD | 126 +++++++++++++++++++++--------------------- translations-location.patch | 40 ++++++------- 2 files changed, 83 insertions(+), 83 deletions(-) Deleted: PKGBUILD =================================================================== --- PKGBUILD 2019-12-25 23:46:31 UTC (rev 541504) +++ PKGBUILD 2019-12-25 23:46:44 UTC (rev 541505) @@ -1,63 +0,0 @@ -# Maintainer: Jelle van der Waa <je...@archlinux.org> -# Maintainer: Stéphane Gaudreault <steph...@archlinux.org> - -pkgname=cppcheck -pkgver=1.89 -pkgrel=1 -pkgdesc="A tool for static C/C++ code analysis" -arch=('x86_64') -url="http://cppcheck.sourceforge.net/" -license=('GPL') -depends=('python-pygments') -makedepends=('docbook-xsl' 'qt5-tools' 'qt5-base' 'python') -optdepends=('qt5-base: run cppcheck-gui') -source=($pkgname-$pkgver.tar.gz::https://github.com/danmar/cppcheck/archive/${pkgver}.tar.gz - translations-location.patch) -sha1sums=('9114a99e629ac820f417e5a4e7c7af47cb90050f' - '03b0888438cf92ccdcbf307dbc3c35e65c91b844') - -prepare() { - cd "${pkgname}-${pkgver}" - patch -Np1 -i $srcdir/translations-location.patch -} - -build() { - cd "${pkgname}-${pkgver}" - export CXXFLAGS+=" -DNDEBUG" - # Unicode fix - LANG='en_US.UTF-8' make SRCDIR=build CFGDIR=/usr/share/cppcheck/cfg HAVE_RULES=yes USE_MATCHCOMPILER=yes - - make DB2MAN=/usr/share/xml/docbook/xsl-stylesheets-1.79.2/manpages/docbook.xsl CFGDIR=/usr/share/cppcheck/cfg man - - cd gui - lrelease gui.pro - qmake HAVE_RULES=yes - make CFGDIR=/usr/share/cppcheck/cfg USE_MATCHCOMPILER=yes HAVE_RULES=yes SRCDIR=build -} - -check() { - cd "${pkgname}-${pkgver}" - - #LANG='en_US.UTF-8' make SRCDIR=build CFGDIR=/usr/share/cppcheck/cfg HAVE_RULES=yes test -} - -package() { - cd "${pkgname}-${pkgver}" - LANG='en_US.UTF-8' make DESTDIR="${pkgdir}" \ - FILESDIR=/usr/share/cppcheck \ - CFGDIR=/usr/share/cppcheck/cfg \ - USE_MATCHCOMPILER=yes HAVE_RULES=yes install - - install -D -p -m 644 cppcheck.1 "${pkgdir}"/usr/share/man/man1/cppcheck.1 - - # GUI - install -m755 gui/cppcheck-gui "${pkgdir}"/usr/bin - install -d "${pkgdir}/usr/share/applications/" - install -m644 gui/cppcheck-gui.desktop "${pkgdir}/usr/share/applications/" - - install -d "${pkgdir}"/usr/share/cppcheck/cfg - install -D ./cfg/* -t "${pkgdir}"/usr/share/cppcheck/cfg - - install -d "${pkgdir}"/usr/share/cppcheck/cfg/lang - install -D gui/*.qm -t "${pkgdir}"/usr/share/cppcheck/cfg/lang/ -} Copied: cppcheck/repos/community-x86_64/PKGBUILD (from rev 541504, cppcheck/trunk/PKGBUILD) =================================================================== --- PKGBUILD (rev 0) +++ PKGBUILD 2019-12-25 23:46:44 UTC (rev 541505) @@ -0,0 +1,63 @@ +# Maintainer: Jelle van der Waa <je...@archlinux.org> +# Maintainer: Stéphane Gaudreault <steph...@archlinux.org> + +pkgname=cppcheck +pkgver=1.90 +pkgrel=1 +pkgdesc="A tool for static C/C++ code analysis" +arch=('x86_64') +url="http://cppcheck.sourceforge.net/" +license=('GPL') +depends=('python-pygments') +makedepends=('docbook-xsl' 'qt5-tools' 'qt5-base' 'python') +optdepends=('qt5-base: run cppcheck-gui') +source=($pkgname-$pkgver.tar.gz::https://github.com/danmar/cppcheck/archive/${pkgver}.tar.gz + translations-location.patch) +sha1sums=('852d69a60b6caf023a3420943ebdc29e99fd0349' + '03b0888438cf92ccdcbf307dbc3c35e65c91b844') + +prepare() { + cd "${pkgname}-${pkgver}" + patch -Np1 -i $srcdir/translations-location.patch +} + +build() { + cd "${pkgname}-${pkgver}" + export CXXFLAGS+=" -DNDEBUG" + # Unicode fix + LANG='en_US.UTF-8' make SRCDIR=build CFGDIR=/usr/share/cppcheck/cfg HAVE_RULES=yes USE_MATCHCOMPILER=yes + + make DB2MAN=/usr/share/xml/docbook/xsl-stylesheets-1.79.2/manpages/docbook.xsl CFGDIR=/usr/share/cppcheck/cfg man + + cd gui + lrelease gui.pro + qmake HAVE_RULES=yes + make CFGDIR=/usr/share/cppcheck/cfg USE_MATCHCOMPILER=yes HAVE_RULES=yes SRCDIR=build +} + +check() { + cd "${pkgname}-${pkgver}" + + #LANG='en_US.UTF-8' make SRCDIR=build CFGDIR=/usr/share/cppcheck/cfg HAVE_RULES=yes test +} + +package() { + cd "${pkgname}-${pkgver}" + LANG='en_US.UTF-8' make DESTDIR="${pkgdir}" \ + FILESDIR=/usr/share/cppcheck \ + CFGDIR=/usr/share/cppcheck/cfg \ + USE_MATCHCOMPILER=yes HAVE_RULES=yes install + + install -D -p -m 644 cppcheck.1 "${pkgdir}"/usr/share/man/man1/cppcheck.1 + + # GUI + install -m755 gui/cppcheck-gui "${pkgdir}"/usr/bin + install -d "${pkgdir}/usr/share/applications/" + install -m644 gui/cppcheck-gui.desktop "${pkgdir}/usr/share/applications/" + + install -d "${pkgdir}"/usr/share/cppcheck/cfg + install -D ./cfg/* -t "${pkgdir}"/usr/share/cppcheck/cfg + + install -d "${pkgdir}"/usr/share/cppcheck/cfg/lang + install -D gui/*.qm -t "${pkgdir}"/usr/share/cppcheck/cfg/lang/ +} Deleted: translations-location.patch =================================================================== --- translations-location.patch 2019-12-25 23:46:31 UTC (rev 541504) +++ translations-location.patch 2019-12-25 23:46:44 UTC (rev 541505) @@ -1,20 +0,0 @@ -diff -aur cppcheck-1.89/gui/translationhandler.cpp cppcheck-1.89.new/gui/translationhandler.cpp ---- cppcheck-1.89/gui/translationhandler.cpp 2019-09-01 15:01:12.000000000 +0200 -+++ cppcheck-1.89.new/gui/translationhandler.cpp 2019-10-02 13:47:44.503900628 +0200 -@@ -116,15 +116,7 @@ - if (datadir.isEmpty()) - datadir = appPath; - -- QString translationFile; -- if (QFile::exists(datadir + "/lang/" + mTranslations[index].mFilename + ".qm")) -- translationFile = datadir + "/lang/" + mTranslations[index].mFilename + ".qm"; -- -- else if (QFile::exists(datadir + "/" + mTranslations[index].mFilename + ".qm")) -- translationFile = datadir + "/" + mTranslations[index].mFilename + ".qm"; -- -- else -- translationFile = appPath + "/" + mTranslations[index].mFilename + ".qm"; -+ QString translationFile("/usr/share/cppcheck/cfg/lang/" + mTranslations[index].mFilename + ".qm"); - - if (!mTranslator->load(translationFile) && !failure) { - //If it failed, lets check if the default file exists Copied: cppcheck/repos/community-x86_64/translations-location.patch (from rev 541504, cppcheck/trunk/translations-location.patch) =================================================================== --- translations-location.patch (rev 0) +++ translations-location.patch 2019-12-25 23:46:44 UTC (rev 541505) @@ -0,0 +1,20 @@ +diff -aur cppcheck-1.89/gui/translationhandler.cpp cppcheck-1.89.new/gui/translationhandler.cpp +--- cppcheck-1.89/gui/translationhandler.cpp 2019-09-01 15:01:12.000000000 +0200 ++++ cppcheck-1.89.new/gui/translationhandler.cpp 2019-10-02 13:47:44.503900628 +0200 +@@ -116,15 +116,7 @@ + if (datadir.isEmpty()) + datadir = appPath; + +- QString translationFile; +- if (QFile::exists(datadir + "/lang/" + mTranslations[index].mFilename + ".qm")) +- translationFile = datadir + "/lang/" + mTranslations[index].mFilename + ".qm"; +- +- else if (QFile::exists(datadir + "/" + mTranslations[index].mFilename + ".qm")) +- translationFile = datadir + "/" + mTranslations[index].mFilename + ".qm"; +- +- else +- translationFile = appPath + "/" + mTranslations[index].mFilename + ".qm"; ++ QString translationFile("/usr/share/cppcheck/cfg/lang/" + mTranslations[index].mFilename + ".qm"); + + if (!mTranslator->load(translationFile) && !failure) { + //If it failed, lets check if the default file exists