[php-maint] Bug#819240: php7.0: FTBFS when built with dpkg-buildpackage -A (ln: failed to create symbolic link)
Santiago Vila
sanvila at debian.org
Fri Mar 25 12:34:45 UTC 2016
Package: src:php7.0
Version: 7.0.4-6
User: sanvila at debian.org
Usertags: binary-indep
Severity: important
Dear maintainer:
I tried to build this package with "dpkg-buildpackage -A"
(i.e. only architecture-independent packages), and it failed:
--------------------------------------------------------------------------------
[...]
debian/rules build-indep
dh build-indep --with systemd --with apache2 --parallel
dh_testdir -i -O--parallel
dh_update_autotools_config -i -O--parallel
install -d debian/.debhelper/bucket/files
cp -an --reflink=auto config.guess debian/.debhelper/bucket/files/b7eab9b8a73dc6e0421366bca6921cd2621dab6c3909d6e3bebf863011442d15.tmp
mv -f debian/.debhelper/bucket/files/b7eab9b8a73dc6e0421366bca6921cd2621dab6c3909d6e3bebf863011442d15.tmp debian/.debhelper/bucket/files/b7eab9b8a73dc6e0421366bca6921cd2621dab6c3909d6e3bebf863011442d15
cp -f /usr/share/misc/config.guess ./config.guess
cp -an --reflink=auto config.sub debian/.debhelper/bucket/files/82745ce935695e7984a053c155a64b9ad16ece3a07d931cc90ab3fb28b7221af.tmp
mv -f debian/.debhelper/bucket/files/82745ce935695e7984a053c155a64b9ad16ece3a07d931cc90ab3fb28b7221af.tmp debian/.debhelper/bucket/files/82745ce935695e7984a053c155a64b9ad16ece3a07d931cc90ab3fb28b7221af
cp -f /usr/share/misc/config.sub ./config.sub
debian/rules override_dh_auto_configure
[... snipped ...]
< debian/tmp/etc/php-fpm.conf.default \
> debian/php7.0-fpm/etc/php/7.0/fpm/php-fpm.conf
mkdir -p debian/php7.0-fpm/etc/php/7.0/fpm/pool.d/
sed -e's,^listen = .*,listen = /run/php/php7.0-fpm.sock,' \
-e's{^;listen\.owner{listen.owner{;' \
-e's{^;listen\.group{listen.group{;' \
< debian/tmp/etc/php-fpm.d/www.conf.default \
> debian/php7.0-fpm/etc/php/7.0/fpm/pool.d/www.conf
rm -f \
debian/tmp/etc/php-fpm.conf.default \
debian/tmp/etc/php-fpm.d/www.conf.default
# install extra CGI-BIN
install -d -m 755 debian/tmp/usr/lib/cgi-bin/
ln debian/tmp/usr/bin/php-cgi7.0 debian/tmp/usr/lib/cgi-bin/php7.0
# sanitize php.ini files
mkdir -p debian/php7.0-common/usr/lib/php/7.0/
cat php.ini-production | tr "\t" " " | \
sed -e'/session.gc_probability =/ s/1/0/g;' \
-e'/disable_functions =/ s/$/ pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,/g;' \
-e'/expose_php =/ s/On/Off/g;' \
> debian/php7.0-common/usr/lib/php/7.0/php.ini-production
cat php.ini-production | tr "\t" " " | \
sed -e'/memory_limit =/ s/128M/-1/g;' \
-e'/session.gc_probability =/ s/1/0/g' \
> debian/php7.0-common/usr/lib/php/7.0/php.ini-production.cli
cat php.ini-development | tr "\t" " " | \
sed -e'/session.gc_probability =/ s/1/0/g;' \
-e'/disable_functions =/ s/$/ pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,/g;' \
> debian/php7.0-common/usr/lib/php/7.0/php.ini-development
mkdir -p debian/php7.0-fpm/usr/lib/php/
install -m 755 debian/php7.0-fpm-checkconf debian/php7.0-fpm/usr/lib/php/
install -m 755 debian/php7.0-fpm-reopenlogs debian/php7.0-fpm/usr/lib/php/
dh_install --fail-missing
ln -sf /usr/share/misc/config.guess debian/php7.0-dev/usr/lib/php/20151012/build/config.guess
ln: failed to create symbolic link 'debian/php7.0-dev/usr/lib/php/20151012/build/config.guess': No such file or directory
debian/rules:468: recipe for target 'override_dh_install' failed
make[1]: *** [override_dh_install] Error 1
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
debian/rules:260: recipe for target 'binary-indep' failed
make: *** [binary-indep] Error 2
dpkg-buildpackage: error: fakeroot debian/rules binary-indep gave error exit status 2
--------------------------------------------------------------------------------
Sorry not to have a fix, as I am reporting many bugs similar to
this one. The common hints are:
* If the only architecture-independent packages are dummy transitional
ones and they were released with jessie, the easy fix is to drop them
now.
* When using "dh", it is allowed to use (independently)
optional targets override_dh_foo-arch and override_dh_foo-indep
(for several values of "foo").
Once that both "dpkg-buildpackage -A" and "dpkg-buildpackage -B" work
properly, the package would be suitable to be uploaded in source-only
form if you wish.
Thanks.
More information about the pkg-php-maint
mailing list