Package: php7.0
Version: 7.0.8-2
Severity: wishlist
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu yakkety ubuntu-patch

Dear Maintainer,

In Ubuntu, the attached patch was applied to achieve the following:

  * Re-enable test suite, thanks to Marc Deslauriers
    <marc.deslauri...@ubuntu.com>
    - debian/rules, debian/setup-mysql.sh: updated for new MySQL version
      and new layout.

Thanks for considering the patch.

*** /tmp/tmpTBf45P/php7.0_7.0.8-2ubuntu1.debdiff
diff -Nru php7.0-7.0.8/debian/rules php7.0-7.0.8/debian/rules
--- php7.0-7.0.8/debian/rules   2016-06-24 04:42:02.000000000 -0700
+++ php7.0-7.0.8/debian/rules   2016-06-28 08:54:49.000000000 -0700
@@ -90,7 +90,7 @@
 LIBTOOL_VERSION := $(shell dpkg-query -f'$${Version}' -W libtool)
 
 # Disable the test now
-RUN_TESTS := no
+RUN_TESTS := yes
 ifeq (nocheck,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
   $(warning Disabling checks due DEB_BUILD_OPTIONS)
   RUN_TESTS := no
@@ -101,12 +101,12 @@
 endif
 
 ifeq (yes,$(RUN_TESTS))
-  MYSQL_PORT ?= $(shell for i in $$(seq 1025 3600 | sort -R); do nc -z 
localhost $$i || { echo $$i; exit; } ; done)
-  MYSQL_DATA_DIR ?= $(shell readlink -f mysql_db)
+  MYSQL_PORT := $(shell for i in $$(seq 1025 3600 | sort -R); do nc -z 
localhost $$i || { echo $$i; exit; } ; done)
+  MYSQL_DATA_DIR := $(shell readlink -f mysql_db)
   ifeq (,$(MYSQL_PORT))
       $(error Could not find available port for mysql server)
   endif
-  MYSQL_SOCKET ?= $(MYSQL_DATA_DIR)/mysql.sock
+  MYSQL_SOCKET := $(MYSQL_DATA_DIR)/mysql.sock
 endif
 
 ifeq (linux,$(DEB_HOST_ARCH_OS))
@@ -343,7 +343,7 @@
        # start our own mysql server for the tests
        $(SHELL) -x debian/setup-mysql.sh $(MYSQL_PORT) $(MYSQL_DATA_DIR)
        extensions=""; \
-       for f in $(CURDIR)/apache2-build/modules/*.so; do \
+       for f in $(CURDIR)/ext-build/modules/*.so; do \
            ext=`basename "$$f"`; \
            test -d "$(CURDIR)/ext/$${ext%.so}/tests" || continue; \
            test "$$ext" != "imap.so" || continue; \
@@ -357,11 +357,15 @@
            test "$$ext" != "pdo_pgsql.so" || continue; \
            test "$$ext" != "snmp.so" || continue; \
            test "$$ext" != "opcache.so" || continue; \
+           test "$$ext" != "mysqlnd.so" || continue; \
+           test "$$ext" != "mysqli.so" || continue; \
+           test "$$ext" != "pdo_mysql.so" || continue; \
+           test "$$ext" != "wddx.so" || continue; \
            extensions="$$extensions -d extension=$$ext"; \
        done; \
        [ "$$extensions" ] || { echo "extensions list is empty"; exit 1; }; \
-       env MYSQL_TEST_HOST=127.0.0.1 MYSQL_TEST_PORT=$(MYSQL_PORT) 
MYSQL_TEST_SOCKET=$(MYSQL_SOCKET) PDO_MYSQL_TEST_HOST=127.0.0.1 
PDO_MYSQL_TEST_PORT=$(MYSQL_PORT) PDO_MYSQL_TEST_SOCKET=$(MYSQL_SOCKET) 
NO_INTERACTION=1 
TEST_PHP_CGI_EXECUTABLE=$(CURDIR)/cgi-build/sapi/cgi/cgi-bin.php$(PHP_NAME_VERSION)
 TEST_PHP_EXECUTABLE=$(CURDIR)/cli-build/sapi/cli/php \
-       $(CURDIR)/cli-build/sapi/cli/php run-tests.php -n -d 
mysql.default_host=127.0.0.1 -d mysql.default_socket=$(MYSQL_SOCKET) -d 
mysqli.default_socket=$(MYSQL_SOCKET) -d 
extension_dir=$(CURDIR)/apache2-build/modules/ $$extensions| tee 
test-results.txt
+       env MYSQL_TEST_HOST=127.0.0.1 MYSQL_TEST_PORT=$(MYSQL_PORT) 
MYSQL_TEST_SOCKET=$(MYSQL_SOCKET) PDO_MYSQL_TEST_HOST=127.0.0.1 
PDO_MYSQL_TEST_PORT=$(MYSQL_PORT) PDO_MYSQL_TEST_SOCKET=$(MYSQL_SOCKET) 
NO_INTERACTION=1 TEST_PHP_CGI_EXECUTABLE=$(CURDIR)/cgi-build/sapi/php-cgi 
TEST_PHP_EXECUTABLE=$(CURDIR)/cli-build/sapi/cli/php \
+       $(CURDIR)/cli-build/sapi/cli/php run-tests.php -n -d 
mysql.default_host=127.0.0.1 -d mysql.default_socket=$(MYSQL_SOCKET) -d 
mysqli.default_socket=$(MYSQL_SOCKET) -d 
extension_dir=$(CURDIR)/ext-build/modules/ $$extensions| tee test-results.txt
        rm -rf temp_session_store
        @for test in `find . -name '*.log' -a '!' -name 'config.log' -a '!' 
-name 'bootstrap.log' -a '!' -name 'run.log'`; do \
            echo; \
diff -Nru php7.0-7.0.8/debian/setup-mysql.sh php7.0-7.0.8/debian/setup-mysql.sh
--- php7.0-7.0.8/debian/setup-mysql.sh  2016-06-24 04:42:02.000000000 -0700
+++ php7.0-7.0.8/debian/setup-mysql.sh  2016-06-28 08:57:39.000000000 -0700
@@ -36,12 +36,12 @@
 chmod go-rx $datadir
 chown $user: $datadir
 
-mysql_install_db --no-defaults --user=$user --datadir=$datadir --rpm --force
+mysql_install_db --no-defaults --user=$user --datadir=$datadir 
--mysqld-file=/usr/sbin/mysqld --random-password-file=$datadir/.mysql_secret
 
 tmpf=$(mktemp)
 cat > "$tmpf" <<EOF
 USE mysql;
-UPDATE user SET password=PASSWORD('') WHERE user='root';
+UPDATE user SET authentication_string=PASSWORD(''), password_expired = 'N' 
WHERE user='root';
 FLUSH PRIVILEGES;
 EOF
 


-- System Information:
Debian Release: stretch/sid
  APT prefers xenial-updates
  APT policy: (500, 'xenial-updates'), (500, 'xenial-security'), (500, 
'xenial'), (100, 'xenial-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.4.0-24-generic (SMP w/4 CPU cores)
Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

-- 
Nishanth Aravamudan
Ubuntu Server
Canonical Ltd

Reply via email to