summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD13
-rw-r--r--setuptools-replace-newlines-in-description.patch31
3 files changed, 44 insertions, 4 deletions
diff --git a/.SRCINFO b/.SRCINFO
index bd29a8e289a..ed56a2c9fb2 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = python-catkin_pkg
pkgdesc = Standalone Python library for the catkin package system
pkgver = 0.4.24
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/ros-infrastructure/catkin_pkg
arch = any
license = BSD
@@ -15,6 +15,8 @@ pkgbase = python-catkin_pkg
conflicts = python2-catkin_pkg
conflicts = python-catkin-pkg
source = https://github.com/ros-infrastructure/catkin_pkg/archive/0.4.24.tar.gz
+ source = setuptools-replace-newlines-in-description.patch
sha256sums = 57ea09fd51d9a67ccf5a0660a8f84794304182c4f644f27ad835a979567893b1
+ sha256sums = 4ab7ed56cbdc16dd4a6b73d8563b7ae7ac66efcf5589ee53fec96d9fd45a6b09
pkgname = python-catkin_pkg
diff --git a/PKGBUILD b/PKGBUILD
index a309b221132..53f9cd86f98 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=('python-catkin_pkg')
pkgver='0.4.24'
-pkgrel=1
+pkgrel=2
pkgdesc='Standalone Python library for the catkin package system'
arch=('any')
url='https://github.com/ros-infrastructure/catkin_pkg'
@@ -11,11 +11,18 @@ depends=('python' 'python-argparse' 'python-dateutil' 'python-docutils' 'python-
makedepends=('python-setuptools')
provides=('python-catkin-pkg')
conflicts=('python2-catkin_pkg' 'python-catkin-pkg')
-source=("https://github.com/ros-infrastructure/catkin_pkg/archive/${pkgver}.tar.gz")
-sha256sums=('57ea09fd51d9a67ccf5a0660a8f84794304182c4f644f27ad835a979567893b1')
+source=("https://github.com/ros-infrastructure/catkin_pkg/archive/${pkgver}.tar.gz"
+ "setuptools-replace-newlines-in-description.patch")
+sha256sums=('57ea09fd51d9a67ccf5a0660a8f84794304182c4f644f27ad835a979567893b1'
+ '0575506c2b25f44e6900f30c320b3dbdd6726174ab1ff45b22d8445b5a42f331')
_module='catkin_pkg'
+prepare() {
+ cd "${srcdir}/${_module}-${pkgver}"
+ patch --forward --strip=1 -i "${srcdir}/setuptools-replace-newlines-in-description.patch"
+}
+
build() {
cd "${srcdir}/${_module}-${pkgver}"
python setup.py build
diff --git a/setuptools-replace-newlines-in-description.patch b/setuptools-replace-newlines-in-description.patch
new file mode 100644
index 00000000000..9482d84150f
--- /dev/null
+++ b/setuptools-replace-newlines-in-description.patch
@@ -0,0 +1,31 @@
+--- catkin_pkg-0.4.24/src/catkin_pkg/python_setup.py
++++ catkin_pkg-0.4.24/src/catkin_pkg/python_setup.py
+@@ -58,7 +58,10 @@
+
+ The "description" is taken from the eponymous tag if it does not
+ exceed 200 characters. If it does "description" contains the
+- truncated text while "description_long" contains the complete.
++ truncated text while "long_description" contains the complete.
++
++ The description shouldn't contain newlines, remove them automatically
++ here and leave them in long_description.
+
+ All licenses are merged into the "license" field.
+
+@@ -98,10 +101,13 @@
+ elif package.urls:
+ data['url'] = package.urls[0].url
+
+- if len(package.description) <= 200:
+- data['description'] = package.description
++ description = package.description.replace('\n', ' ')
++ if len(description) <= 200:
++ data['description'] = description
+ else:
+- data['description'] = package.description[:197] + '...'
++ data['description'] = description[:197] + '...'
++
++ if data['description'] != package.description:
+ data['long_description'] = package.description
+
+ data['license'] = ', '.join(package.licenses)