Mail archive
alpine-aports

[alpine-aports] [PATCH] testing/php7: fix conflict with php5

From: Valery Kartel <valery.kartel_at_gmail.com>
Date: Thu, 30 Mar 2017 16:35:04 +0300

fix conflict if both php5-dev, php7-dev would be installed
fix php7-dev depends (add autoconf, pcre-dev)
fix php7-pecl depends (remove autoconf)
remove unneeded replaces=, provides=
---
 testing/php7/APKBUILD | 35 ++++++++++++-----------------------
 1 file changed, 12 insertions(+), 23 deletions(-)
diff --git a/testing/php7/APKBUILD b/testing/php7/APKBUILD
index 0b69648b52..4b1446aded 100644
--- a/testing/php7/APKBUILD
+++ b/testing/php7/APKBUILD
_at_@ -2,7 +2,7 @@
 # Maintainer: Valery Kartel <valery.kartel_at_gmail.com>
 pkgname=php7
 pkgver=7.1.3
-pkgrel=0
+pkgrel=1
 _apiver=20160303
 _compat=7.1
 _suffix=${pkgname#php}
_at_@ -13,9 +13,9 @@ arch="all"
 license="PHP-3"
 options="!check"
 depends="$pkgname-config"
-depends_dev="$pkgname"
-replaces="$_pkgreal $_pkgreal-cli $_pkgreal$_compat $_pkgreal$_compat-cli"
-provides="$replaces $pkgname-cli"
+depends_dev="$pkgname autoconf pcre-dev"
+replaces="php5"
+provides="$_pkgreal"
 makedepends="autoconf bison re2c apache2-dev libxml2-dev libxslt-dev libzip-dev bzip2-dev zlib-dev
 	aspell-dev enchant-dev expat-dev pcre-dev curl-dev gmp-dev icu-dev imap-dev gd-dev
 	libical-dev libressl-dev openldap-dev net-snmp-dev db-dev krb5-dev gdbm-dev sqlite-dev
_at_@ -213,8 +213,7 @@ package() {
 }
 
 dev() {
-	provides="$_pkgreal-dev $_pkgreal$_compat-dev"
-	replaces=$provides
+	replaces=$replaces-${subpkgname#$pkgname-}
 	default_dev || return 1
 
 	mkdir -p "$subpkgdir"/usr/bin \
_at_@ -231,7 +230,7 @@ dev() {
 }
 
 doc() {
-	provides=
+	depends=
 	replaces=
 	default_doc || return 1
 	install_if="docs $pkgname-config=$pkgver-r$pkgrel"
_at_@ -244,7 +243,6 @@ doc() {
 }
 
 apache2() {
-	provides="$_pkgreal-apache2 $_pkgreal$_compat-apache2"
 	replaces=
 	pkgdesc="$pkgdesc (apache2 module)"
 	depends="$pkgname-config apache2"
_at_@ -258,8 +256,7 @@ apache2() {
 }
 
 phpdbg() {
-	provides="$_pkgreal-phpdbg $_pkgreal$_compat-phpdbg"
-	replaces=$provides
+	replaces=$replaces-${subpkgname#$pkgname-}
 	pkgdesc="$pkgdesc (interactive debugger)"
 	depends="$pkgname-config"
 
_at_@ -269,7 +266,6 @@ phpdbg() {
 }
 
 libs() {
-	provides="$_pkgreal-libs $_pkgreal$_compat-libs"
 	replaces=
 	pkgdesc="$pkgdesc (embedded library)"
 	depends="$pkgname-config"
_at_@ -280,8 +276,7 @@ libs() {
 }
 
 litespeed() {
-	provides="$_pkgreal-litespeed $_pkgreal$_compat-litespeed"
-	replaces=$provides
+	replaces=$replaces-${subpkgname#$pkgname-}
 	pkgdesc="$pkgdesc (litespeed)"
 	depends="$pkgname-config"
 
_at_@ -292,8 +287,7 @@ litespeed() {
 }
 
 cgi() {
-	provides="$_pkgreal-cgi $_pkgreal$_compat-cgi"
-	replaces=$provides
+	replaces=$replaces-${subpkgname#$pkgname-}
 	pkgdesc="$pkgdesc (common gateway interface)"
 	depends="$pkgname-config"
 
_at_@ -304,7 +298,6 @@ cgi() {
 }
 
 fpm() {
-	provides="$_pkgreal-fpm $_pkgreal$_compat-fpm"
 	replaces=
 	pkgdesc="$pkgdesc (fastcgi process manager)"
 	depends="$pkgname-config"
_at_@ -332,8 +325,7 @@ fpm() {
 }
 
 pear() {
-	provides="$_pkgreal-pear $_pkgreal$_compat-pear"
-	replaces=$provides
+	replaces=$replaces-${subpkgname#$pkgname-}
 	pkgdesc="$pkgdesc (php extension and application repository)"
 	depends="$pkgname $pkgname-xml"
 
_at_@ -361,10 +353,9 @@ pear() {
 }
 
 pecl() {
-	provides="$_pkgreal-pecl $_pkgreal$_compat-pecl"
 	replaces=
 	pkgdesc="$pkgdesc (php extension community library)"
-	depends="$pkgname-pear $pkgname-dev autoconf gcc make musl-dev"
+	depends="$pkgname-pear $pkgname-dev gcc make musl-dev"
 	mkdir -p "$subpkgdir"
 }
 
_at_@ -385,8 +376,7 @@ config() {
 }
 
 _phar() {
-	provides="$_pkgreal-phar-utils $_pkgreal$_compat-phar-utils"
-	replaces=$provides
+	replaces=$replaces-${subpkgname#$pkgname-}
 	pkgdesc="$pkgdesc (archive script)"
 	depends="$pkgname $pkgname-phar"
 
_at_@ -407,7 +397,6 @@ _extension() {
 	local dep deps
 	local name=${subpkgname#$pkgname-}
 	local index=$(eval echo \${_index_$name:-0})
-	provides="$_pkgreal-$name $_pkgreal$_compat-$name"
 	replaces=
 	depends=$(eval echo \$_depends_$name)
 
-- 
2.12.2
---
Unsubscribe:  alpine-aports+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-aports+help_at_lists.alpinelinux.org
---
Received on Thu Mar 30 2017 - 16:35:04 GMT