Package: libphp-swiftmailer
Version: 4.2.1-1
Severity: wishlist
Tags: patch

Hi,

Your package does not follow the pkg-php name convention, thus
forcing other packages using dh_phpcomposer to provide a
debian/pkg-php-tools-overrides in order to generate working
dependencies out of a composer.json.
Therefore your should consider renaming your binary package to
php-swiftmailer, providing a transitional package libphp-swiftmailer.

The patch provided with this bug report can be applied to a local
clone of swift.git with '# git am', e.g.:
# cd /PATH/TO/SWIFT-GIT-REPO
# git am /PATH/TO/0001-Rename-binary-package-to-php-swiftmailer.patch

Note that you might need to update the (<<5.1.0-1~) that is found in
the Replaces: and Breaks: fields in debian/control, if you intend to
do the renaming in a version post 5.1.0-1 - e.g. set it to (<<5.2.1-1~)
if it is renamed in your version 5.2.1-1.

Thanks
Daniel
From e8c478f6d16fdf8bce614249dfa515e5b6a42962 Mon Sep 17 00:00:00 2001
From: Daniel Beyer <d...@deb.ymc.ch>
Date: Wed, 6 Aug 2014 08:23:33 +0200
Subject: [PATCH] Rename binary package to php-swiftmailer

The package does not follow the pkg-php name convention, thus forcing other
packages using dh_phpcomposer to provide a debian/pkg-php-tools-overrides
in order to generate working dependencies out of a composer.json.
Therefore the binary package is renamed to php-swiftmailer, providing a
transitional package libphp-swiftmailer.
---
 debian/control           | 12 +++++++++++-
 debian/dirs              |  2 +-
 debian/lintian-overrides |  2 +-
 debian/rules             |  4 ++--
 4 files changed, 15 insertions(+), 5 deletions(-)

diff --git a/debian/control b/debian/control
index deb489e..00768ae 100644
--- a/debian/control
+++ b/debian/control
@@ -9,9 +9,12 @@ Homepage: http://swiftmailer.org/
 Vcs-Git: git://anonscm.debian.org/collab-maint/swift.git
 Vcs-Browser: http://anonscm.debian.org/gitweb/?p=collab-maint/swift.git
 
-Package: libphp-swiftmailer
+Package: php-swiftmailer
 Architecture: all
 Depends: ${misc:Depends}, php5 | php5-cli
+Replaces: libphp-swiftmailer (<<5.1.0-1~)
+Breaks: libphp-swiftmailer (<<5.1.0-1~)
+Provides: libphp-swiftmailer
 Description: component-based library for sending e-mails
  Swift Mailer is component based mailing solution for PHP 5
  Send emails using SMTP, sendmail, postfix or a custom Transport
@@ -23,3 +26,10 @@ Description: component-based library for sending e-mails
   - event-driven plugins to customize the library
   - MIME compliant HTML/multipart emails
   - large attachments and inline/embedded images with low memory use
+
+Package: libphp-swiftmailer
+Depends: ${misc:Depends}, php-swiftmailer
+Architecture: all
+Section: oldlibs
+Description: transitional dummy package
+ This is a transitional dummy package. It can safely be removed.
diff --git a/debian/dirs b/debian/dirs
index 260c4e7..7105aeb 100644
--- a/debian/dirs
+++ b/debian/dirs
@@ -1,2 +1,2 @@
 usr/share/php/Swift
-usr/share/doc/libphp-swiftmailer
+usr/share/doc/php-swiftmailer
diff --git a/debian/lintian-overrides b/debian/lintian-overrides
index 0095669..258599c 100644
--- a/debian/lintian-overrides
+++ b/debian/lintian-overrides
@@ -1,4 +1,4 @@
 # Upstream distribute it like this. That script is used to generate mime types
 # used by swiftmailer.
 # tell lintian to not complain:
-libphp-swiftmailer: script-not-executable
+php-swiftmailer: script-not-executable
diff --git a/debian/rules b/debian/rules
index 679fccb..4cea9c7 100755
--- a/debian/rules
+++ b/debian/rules
@@ -14,5 +14,5 @@
 
 override_dh_installdocs:
 	dh_installdocs
-	rm debian/libphp-swiftmailer/usr/share/doc/libphp-swiftmailer/test-suite/LICENSE
-	rm debian/libphp-swiftmailer/usr/share/doc/libphp-swiftmailer/test-suite/lib/simpletest/LICENSE
+	rm debian/php-swiftmailer/usr/share/doc/php-swiftmailer/test-suite/LICENSE
+	rm debian/php-swiftmailer/usr/share/doc/php-swiftmailer/test-suite/lib/simpletest/LICENSE
-- 
1.9.1

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to