diff options
Diffstat (limited to 'pcr')
-rw-r--r-- | pcr/spectrum/PKGBUILD | 81 | ||||
-rw-r--r-- | pcr/spectrum/gcc47.patch | 97 | ||||
-rw-r--r-- | pcr/spectrum/logrotate.spectrum | 10 | ||||
-rw-r--r-- | pcr/spectrum/spectrum.install | 45 | ||||
-rw-r--r-- | pcr/spectrum/spectrum.tmpfiles | 1 | ||||
-rw-r--r-- | pcr/spectrum/spectrum@.service | 14 |
6 files changed, 0 insertions, 248 deletions
diff --git a/pcr/spectrum/PKGBUILD b/pcr/spectrum/PKGBUILD deleted file mode 100644 index a58992bc9..000000000 --- a/pcr/spectrum/PKGBUILD +++ /dev/null @@ -1,81 +0,0 @@ -# Maintainer (Arch): Clément Démoulins <clement@archivel.fr> -# Contributor (Arch): Sonny Piers <sonny.piers@gmail.com> -# Contributor (Arch): Tim Besard <tim.besard@gmail.com> -# Contributor (Arch): miniature <miniature@archlinux.us> - -pkgname=spectrum -pkgver=1.4.8 -pkgrel=4 -pkgdesc="XMPP libpurple transport/gateway." -arch=('i686' 'x86_64') -url="http://spectrum.im" -license=('GPL') -depends=('gloox' 'libpurple-minimal' 'poco' 'python2' libev) -replaces=('spectrum-git') -makedepends=('cmake' 'gettext') -optdepends=('mysql: MySQL database backend support' - 'postgresql-libs: PostgreSQL database backend support' - 'sqlite3: SQLite database backend support' - 'libevent: support for libevent' - 'imagemagick: support for avatars synchronization with legacy networks' - - # Protocols plugins - 'mbpurple-svn: microblogging services support like Twitter or identi.ca/StatusNet' - 'msn-pecan: a different implementation of the MSN protocol for libpurple' - 'pidgin-facebookchat: Facebook support, with more features than Facebook XMPP server' - 'pidgin-sipe: SIPE protocol support' -) -backup=('etc/conf.d/spectrum') -install='spectrum.install' - -source=('https://github.com/downloads/hanzz/libtransport/spectrum-1.4.8.tar.gz' - 'logrotate.spectrum' - 'gcc47.patch' - 'spectrum@.service' - 'spectrum.tmpfiles') -md5sums=('edd88e1e70f86fe9aa4b43d787529a47' - '4f9cbfe3878fe5f4137d1bb5acc9e850' - '7a3de7e91d581b6c9119965ac34b9510' - '8abfd4926fec074847c4d28465af22bb' - '21dc715b3b2fb90c5349a12966277bc6') - -build() { - cd "${srcdir}/${pkgname}-${pkgver}" - - msg "Starting make..." - - sed -i -e 's/${PYTHON_EXECUTABLE}/python2/g' CMakeLists.txt - patch -p1 < ../gcc47.patch - cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr . - make - - cd spectrumctl - python2 setup.py build -} - -package() { - cd "${srcdir}/${pkgname}-${pkgver}" - - # Various needed folders -- correct permissions are set in spectrum.install - install -d "${pkgdir}/etc/spectrum" - install -d "${pkgdir}/var/log/spectrum" - install -d "${pkgdir}/var/lib/spectrum" - - # Install binaries and Python control script - make DESTDIR="${pkgdir}" install - - cd spectrumctl - python2 setup.py install --root="${pkgdir}" - - # Install initscript and logrotate config - install -Dm755 "${srcdir}/${pkgname}-${pkgver}/initscripts/archlinux/spectrum-rc.d" "${pkgdir}/etc/rc.d/spectrum" - install -Dm644 "${srcdir}/${pkgname}-${pkgver}/initscripts/archlinux/spectrum-conf.d" "${pkgdir}/etc/conf.d/spectrum" - install -Dm644 "${srcdir}/logrotate.spectrum" "${pkgdir}/etc/logrotate.d/spectrum" - - # Install systemd related files - install -Dm644 "${srcdir}/spectrum@.service" "${pkgdir}/usr/lib/systemd/system/spectrum@.service" - install -Dm644 "${srcdir}/spectrum.tmpfiles" "${pkgdir}/usr/lib/tmpfiles.d/spectrum.conf" - - # Patch to use python2 - sed -i -e "s|#!/usr/bin/env python|#!/usr/bin/env python2|" "${pkgdir}/usr/bin/spectrumctl" -} diff --git a/pcr/spectrum/gcc47.patch b/pcr/spectrum/gcc47.patch deleted file mode 100644 index 82cc58677..000000000 --- a/pcr/spectrum/gcc47.patch +++ /dev/null @@ -1,97 +0,0 @@ -diff -rupN spectrum-1.4.8/src/configinterface.cpp spectrum-1.4.8_gcc47/src/configinterface.cpp ---- spectrum-1.4.8/src/configinterface.cpp 2011-06-11 15:17:44.000000000 +0200 -+++ spectrum-1.4.8_gcc47/src/configinterface.cpp 2012-04-14 18:27:14.000000000 +0200 -@@ -18,6 +18,7 @@ - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA - */ - -+#include <unistd.h> - #include "configinterface.h" - #include "sys/un.h" - #include "sys/socket.h" -diff -rupN spectrum-1.4.8/src/spectrum_util.cpp spectrum-1.4.8_gcc47/src/spectrum_util.cpp ---- spectrum-1.4.8/src/spectrum_util.cpp 2011-06-11 15:17:44.000000000 +0200 -+++ spectrum-1.4.8_gcc47/src/spectrum_util.cpp 2012-04-14 18:26:33.000000000 +0200 -@@ -28,6 +28,7 @@ - #include "protocols/abstractprotocol.h" - #include "transport.h" - #include <sys/param.h> -+#include <unistd.h> - #ifdef BSD - #include <sys/types.h> - #include <sys/sysctl.h> -diff -rupN spectrum-1.4.8/src/utf8/checked.h spectrum-1.4.8_gcc47/src/utf8/checked.h ---- spectrum-1.4.8/src/utf8/checked.h 2010-10-08 09:15:22.000000000 +0200 -+++ spectrum-1.4.8_gcc47/src/utf8/checked.h 2012-04-14 18:26:31.000000000 +0200 -@@ -65,6 +65,35 @@ namespace utf8 - - /// The library API - functions intended to be called by the users - -+ template <typename octet_iterator> -+ octet_iterator append(uint32_t cp, octet_iterator result) -+ { -+ if (!internal::is_code_point_valid(cp)) -+ throw invalid_code_point(cp); -+ -+ if (cp < 0x80) // one octet -+ *(result++) = static_cast<uint8_t>(cp); -+ else if (cp < 0x800) { // two octets -+ *(result++) = static_cast<uint8_t>((cp >> 6) | 0xc0); -+ *(result++) = static_cast<uint8_t>((cp & 0x3f) | 0x80); -+ } -+ else if (cp < 0x10000) { // three octets -+ *(result++) = static_cast<uint8_t>((cp >> 12) | 0xe0); -+ *(result++) = static_cast<uint8_t>(((cp >> 6) & 0x3f) | 0x80); -+ *(result++) = static_cast<uint8_t>((cp & 0x3f) | 0x80); -+ } -+ else if (cp <= internal::CODE_POINT_MAX) { // four octets -+ *(result++) = static_cast<uint8_t>((cp >> 18) | 0xf0); -+ *(result++) = static_cast<uint8_t>(((cp >> 12)& 0x3f) | 0x80); -+ *(result++) = static_cast<uint8_t>(((cp >> 6) & 0x3f) | 0x80); -+ *(result++) = static_cast<uint8_t>((cp & 0x3f) | 0x80); -+ } -+ else -+ throw invalid_code_point(cp); -+ -+ return result; -+ } -+ - template <typename octet_iterator, typename output_iterator> - output_iterator replace_invalid(octet_iterator start, octet_iterator end, output_iterator out, uint32_t replacement) - { -@@ -104,35 +133,6 @@ namespace utf8 - } - - template <typename octet_iterator> -- octet_iterator append(uint32_t cp, octet_iterator result) -- { -- if (!internal::is_code_point_valid(cp)) -- throw invalid_code_point(cp); -- -- if (cp < 0x80) // one octet -- *(result++) = static_cast<uint8_t>(cp); -- else if (cp < 0x800) { // two octets -- *(result++) = static_cast<uint8_t>((cp >> 6) | 0xc0); -- *(result++) = static_cast<uint8_t>((cp & 0x3f) | 0x80); -- } -- else if (cp < 0x10000) { // three octets -- *(result++) = static_cast<uint8_t>((cp >> 12) | 0xe0); -- *(result++) = static_cast<uint8_t>(((cp >> 6) & 0x3f) | 0x80); -- *(result++) = static_cast<uint8_t>((cp & 0x3f) | 0x80); -- } -- else if (cp <= internal::CODE_POINT_MAX) { // four octets -- *(result++) = static_cast<uint8_t>((cp >> 18) | 0xf0); -- *(result++) = static_cast<uint8_t>(((cp >> 12)& 0x3f) | 0x80); -- *(result++) = static_cast<uint8_t>(((cp >> 6) & 0x3f) | 0x80); -- *(result++) = static_cast<uint8_t>((cp & 0x3f) | 0x80); -- } -- else -- throw invalid_code_point(cp); -- -- return result; -- } -- -- template <typename octet_iterator> - uint32_t next(octet_iterator& it, octet_iterator end) - { - uint32_t cp = 0; diff --git a/pcr/spectrum/logrotate.spectrum b/pcr/spectrum/logrotate.spectrum deleted file mode 100644 index ae52ff156..000000000 --- a/pcr/spectrum/logrotate.spectrum +++ /dev/null @@ -1,10 +0,0 @@ -/var/log/spectrum/*.log { - notifempty - missingok - sharedscripts - postrotate - for P in /var/run/spectrum/*.pid; do - /bin/kill -HUP `cat "$P" 2>/dev/null` 2>/dev/null || true - done - endscript -} diff --git a/pcr/spectrum/spectrum.install b/pcr/spectrum/spectrum.install deleted file mode 100644 index d3e0449fc..000000000 --- a/pcr/spectrum/spectrum.install +++ /dev/null @@ -1,45 +0,0 @@ -# arg 1: the new package version -post_install() { - if [ -z "`grep '^spectrum:' /etc/group`" ]; then - groupadd -g 417 spectrum - fi - if [ -z "`grep '^spectrum:' /etc/passwd`" ]; then - useradd -u 417 -d /etc/spectrum -g spectrum -s /bin/false spectrum - fi - - chown spectrum:spectrum var/lib/spectrum - chown spectrum:spectrum var/log/spectrum - -cat << EOF - -==> Documentation: http://spectrum.im/ - -==> You must now customize the configuration file located in /etc/spectrum/. Copy and reconfigure for each seperate protocol. - -EOF - -} - -# arg 1: the new package version -# arg 2: the old package version -post_upgrade() { - post_install $1 -} - -# arg 1: the old package version -post_remove() { - userdel spectrum - - paths=(/etc/spectrum /var/lib/spectrum /var/log/spectrum) - - first=true - for path in ${paths[@]}; do - if [ -d $path ]; then - if $first; then - first=false - echo "==> Leftover Paths:" - fi - echo "==> $path" - fi - done -} diff --git a/pcr/spectrum/spectrum.tmpfiles b/pcr/spectrum/spectrum.tmpfiles deleted file mode 100644 index cabe97bc5..000000000 --- a/pcr/spectrum/spectrum.tmpfiles +++ /dev/null @@ -1 +0,0 @@ -d /run/spectrum 0750 spectrum spectrum - diff --git a/pcr/spectrum/spectrum@.service b/pcr/spectrum/spectrum@.service deleted file mode 100644 index 8e1338543..000000000 --- a/pcr/spectrum/spectrum@.service +++ /dev/null @@ -1,14 +0,0 @@ -[Unit] -Description=Spectrum XMPP transport for %i -After=network.service prosody.service ejabberd.service - -[Service] -Type=forking -PIDFile=/run/spectrum/%i.pid -ExecStart=/usr/bin/spectrumctl --su=spectrum -c /etc/spectrum/%i.cfg start -ExecStop=/usr/binspectrumctl --su=spectrum -c /etc/spectrum/%i.cfg stop -ExecReload=/usr/binspectrumctl --su=spectrum -c /etc/spectrum/%i.cfg reload - -[Install] -WantedBy=multi-user.target - |