php*: disable global regs on i386. Fixes PR pkg/53222 that resurfaced Remove the previous workaround to add GCC_REQD, which isn't sufficient any more, possibly due to enabling ssp/fortify? XXX bumping PKGREVISION might not be sufficient, for the same reason the GCC_REQD had to be moved to Makefile.php, it affects modules too.diff -r1.10 -r1.11 pkgsrc/lang/php70/Makefile
(maya)
@@ -1,20 +1,21 @@ | @@ -1,20 +1,21 @@ | |||
1 | # $NetBSD: Makefile,v 1.10 2017/10/27 08:46:49 taca Exp $ | 1 | # $NetBSD: Makefile,v 1.11 2018/07/16 10:58:50 maya Exp $ | |
2 | 2 | |||
3 | # | 3 | # | |
4 | # We can't omit PKGNAME here to handle PKG_OPTIONS. | 4 | # We can't omit PKGNAME here to handle PKG_OPTIONS. | |
5 | # | 5 | # | |
6 | PKGNAME= php-${PHP_VERSION} | 6 | PKGNAME= php-${PHP_VERSION} | |
7 | CATEGORIES= lang | 7 | CATEGORIES= lang | |
8 | PKGREVISION= 1 | |||
8 | 9 | |||
9 | HOMEPAGE= http://www.php.net/ | 10 | HOMEPAGE= http://www.php.net/ | |
10 | COMMENT= PHP Hypertext Preprocessor version 7.0 | 11 | COMMENT= PHP Hypertext Preprocessor version 7.0 | |
11 | LICENSE= php | 12 | LICENSE= php | |
12 | 13 | |||
13 | TEST_TARGET= test | 14 | TEST_TARGET= test | |
14 | 15 | |||
15 | USE_TOOLS+= gmake lex pkg-config | 16 | USE_TOOLS+= gmake lex pkg-config | |
16 | LIBTOOL_OVERRIDE= # empty | 17 | LIBTOOL_OVERRIDE= # empty | |
17 | PHP_CHECK_INSTALLED= No | 18 | PHP_CHECK_INSTALLED= No | |
18 | 19 | |||
19 | PHP_VERSIONS_ACCEPTED= 70 | 20 | PHP_VERSIONS_ACCEPTED= 70 | |
20 | 21 | |||
@@ -38,26 +39,32 @@ SUBST_FILES.path+= php.ini-development p | @@ -38,26 +39,32 @@ SUBST_FILES.path+= php.ini-development p | |||
38 | SUBST_FILES.path+= sapi/cgi/Makefile.frag | 39 | SUBST_FILES.path+= sapi/cgi/Makefile.frag | |
39 | SUBST_SED.path= -e 's,@CGIDIR@,${CGIDIR},g' | 40 | SUBST_SED.path= -e 's,@CGIDIR@,${CGIDIR},g' | |
40 | SUBST_SED.path+= -e 's,@PREFIX@,${PREFIX},g' | 41 | SUBST_SED.path+= -e 's,@PREFIX@,${PREFIX},g' | |
41 | 42 | |||
42 | INSTALLATION_DIRS+= ${CGIDIR} ${PHP_EXTENSION_DIR} ${EGDIR} share/php | 43 | INSTALLATION_DIRS+= ${CGIDIR} ${PHP_EXTENSION_DIR} ${EGDIR} share/php | |
43 | 44 | |||
44 | # segfault generating phar.phar for i386 & SPARC | 45 | # segfault generating phar.phar for i386 & SPARC | |
45 | # revisit this if builtin PCRE is updated beyond PCRE1 8.38 | 46 | # revisit this if builtin PCRE is updated beyond PCRE1 8.38 | |
46 | # https://bugs.php.net/bug.php?id=73880 | 47 | # https://bugs.php.net/bug.php?id=73880 | |
47 | .if ${MACHINE_ARCH} != "x86_64" | 48 | .if ${MACHINE_ARCH} != "x86_64" | |
48 | CONFIGURE_ARGS+= --without-pcre-jit | 49 | CONFIGURE_ARGS+= --without-pcre-jit | |
49 | .endif | 50 | .endif | |
50 | 51 | |||
52 | .if ${MACHINE_ARCH} == "i386" | |||
53 | # segfaults when buidling with many compilers | |||
54 | # https://bugs.php.net/bug.php?id=74527 | |||
55 | CONFIGURE_ARGS+= --disable-gcc-global-regs | |||
56 | .endif | |||
57 | ||||
51 | # Make sure modules can link correctly | 58 | # Make sure modules can link correctly | |
52 | .if ${OPSYS} == "Darwin" | 59 | .if ${OPSYS} == "Darwin" | |
53 | INSTALL_UNSTRIPPED= yes | 60 | INSTALL_UNSTRIPPED= yes | |
54 | .endif | 61 | .endif | |
55 | 62 | |||
56 | # Darwin < 9 (Mac OS X < 10.5 "Leopard") doesn't have gethostuuid(2) | 63 | # Darwin < 9 (Mac OS X < 10.5 "Leopard") doesn't have gethostuuid(2) | |
57 | # and lacks the zone memory allocator | 64 | # and lacks the zone memory allocator | |
58 | .if !empty(MACHINE_PLATFORM:MDarwin-[0-8].*-*) | 65 | .if !empty(MACHINE_PLATFORM:MDarwin-[0-8].*-*) | |
59 | CFLAGS+= -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_WITHOUT_ZONEMALLOC | 66 | CFLAGS+= -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_WITHOUT_ZONEMALLOC | |
60 | .endif | 67 | .endif | |
61 | 68 | |||
62 | post-install: | 69 | post-install: | |
63 | ${INSTALL_PROGRAM} ${WRKSRC}/sapi/cli/php ${DESTDIR}${PREFIX}/bin/php | 70 | ${INSTALL_PROGRAM} ${WRKSRC}/sapi/cli/php ${DESTDIR}${PREFIX}/bin/php |
@@ -1,23 +1,18 @@ | @@ -1,23 +1,18 @@ | |||
1 | # $NetBSD: Makefile.php,v 1.7 2017/08/04 23:07:28 taca Exp $ | 1 | # $NetBSD: Makefile.php,v 1.8 2018/07/16 10:58:50 maya Exp $ | |
2 | # used by lang/php70/Makefile | 2 | # used by lang/php70/Makefile | |
3 | # used by www/ap-php/Makefile | 3 | # used by www/ap-php/Makefile | |
4 | # used by www/php-fpm/Makefile | 4 | # used by www/php-fpm/Makefile | |
5 | 5 | |||
6 | # PHP bug #74526 - segfaults on build with GCC 4.8.5 i386 | |||
7 | .if ${MACHINE_ARCH} == "i386" | |||
8 | GCC_REQD+= 4.9 | |||
9 | .endif | |||
10 | ||||
11 | .include "../../lang/php70/Makefile.common" | 6 | .include "../../lang/php70/Makefile.common" | |
12 | 7 | |||
13 | DISTINFO_FILE= ${.CURDIR}/../../lang/php70/distinfo | 8 | DISTINFO_FILE= ${.CURDIR}/../../lang/php70/distinfo | |
14 | PATCHDIR= ${.CURDIR}/../../lang/php70/patches | 9 | PATCHDIR= ${.CURDIR}/../../lang/php70/patches | |
15 | 10 | |||
16 | USE_LIBTOOL= YES | 11 | USE_LIBTOOL= YES | |
17 | USE_LANGUAGES= c c++ | 12 | USE_LANGUAGES= c c++ | |
18 | GNU_CONFIGURE= YES | 13 | GNU_CONFIGURE= YES | |
19 | BUILD_DEFS+= VARBASE | 14 | BUILD_DEFS+= VARBASE | |
20 | PLIST_VARS+= dtrace | 15 | PLIST_VARS+= dtrace | |
21 | 16 | |||
22 | CONFIGURE_ENV+= EXTENSION_DIR="${PREFIX}/${PHP_EXTENSION_DIR}" | 17 | CONFIGURE_ENV+= EXTENSION_DIR="${PREFIX}/${PHP_EXTENSION_DIR}" | |
23 | 18 |
@@ -1,20 +1,21 @@ | @@ -1,20 +1,21 @@ | |||
1 | # $NetBSD: Makefile,v 1.13 2017/10/27 08:47:49 taca Exp $ | 1 | # $NetBSD: Makefile,v 1.14 2018/07/16 10:58:50 maya Exp $ | |
2 | 2 | |||
3 | # | 3 | # | |
4 | # We can't omit PKGNAME here to handle PKG_OPTIONS. | 4 | # We can't omit PKGNAME here to handle PKG_OPTIONS. | |
5 | # | 5 | # | |
6 | PKGNAME= php-${PHP_VERSION:S/RC/rc/} | 6 | PKGNAME= php-${PHP_VERSION:S/RC/rc/} | |
7 | CATEGORIES= lang | 7 | CATEGORIES= lang | |
8 | PKGREVISION= 1 | |||
8 | 9 | |||
9 | HOMEPAGE= http://www.php.net/ | 10 | HOMEPAGE= http://www.php.net/ | |
10 | COMMENT= PHP Hypertext Preprocessor version 7.1 | 11 | COMMENT= PHP Hypertext Preprocessor version 7.1 | |
11 | LICENSE= php | 12 | LICENSE= php | |
12 | 13 | |||
13 | TEST_TARGET= test | 14 | TEST_TARGET= test | |
14 | 15 | |||
15 | USE_TOOLS+= gmake lex pkg-config | 16 | USE_TOOLS+= gmake lex pkg-config | |
16 | LIBTOOL_OVERRIDE= # empty | 17 | LIBTOOL_OVERRIDE= # empty | |
17 | PHP_CHECK_INSTALLED= No | 18 | PHP_CHECK_INSTALLED= No | |
18 | 19 | |||
19 | PHP_VERSIONS_ACCEPTED= 71 | 20 | PHP_VERSIONS_ACCEPTED= 71 | |
20 | 21 | |||
@@ -38,26 +39,32 @@ SUBST_FILES.path+= php.ini-development p | @@ -38,26 +39,32 @@ SUBST_FILES.path+= php.ini-development p | |||
38 | SUBST_FILES.path+= sapi/cgi/Makefile.frag | 39 | SUBST_FILES.path+= sapi/cgi/Makefile.frag | |
39 | SUBST_SED.path= -e 's,@CGIDIR@,${CGIDIR},g' | 40 | SUBST_SED.path= -e 's,@CGIDIR@,${CGIDIR},g' | |
40 | SUBST_SED.path+= -e 's,@PREFIX@,${PREFIX},g' | 41 | SUBST_SED.path+= -e 's,@PREFIX@,${PREFIX},g' | |
41 | 42 | |||
42 | INSTALLATION_DIRS+= ${CGIDIR} ${PHP_EXTENSION_DIR} ${EGDIR} share/php | 43 | INSTALLATION_DIRS+= ${CGIDIR} ${PHP_EXTENSION_DIR} ${EGDIR} share/php | |
43 | 44 | |||
44 | # segfault generating phar.phar for i386 & SPARC | 45 | # segfault generating phar.phar for i386 & SPARC | |
45 | # revisit this if builtin PCRE is updated beyond PCRE1 8.38 | 46 | # revisit this if builtin PCRE is updated beyond PCRE1 8.38 | |
46 | # https://bugs.php.net/bug.php?id=73880 | 47 | # https://bugs.php.net/bug.php?id=73880 | |
47 | .if ${MACHINE_ARCH} != "x86_64" | 48 | .if ${MACHINE_ARCH} != "x86_64" | |
48 | CONFIGURE_ARGS+= --without-pcre-jit | 49 | CONFIGURE_ARGS+= --without-pcre-jit | |
49 | .endif | 50 | .endif | |
50 | 51 | |||
52 | # segfaults when buidling with many compilers | |||
53 | # https://bugs.php.net/bug.php?id=74527 | |||
54 | .if ${MACHINE_ARCH} == "i386" | |||
55 | CONFIGURE_ARGS+= --disable-gcc-global-regs | |||
56 | .endif | |||
57 | ||||
51 | # Make sure modules can link correctly | 58 | # Make sure modules can link correctly | |
52 | .if ${OPSYS} == "Darwin" | 59 | .if ${OPSYS} == "Darwin" | |
53 | INSTALL_UNSTRIPPED= yes | 60 | INSTALL_UNSTRIPPED= yes | |
54 | .endif | 61 | .endif | |
55 | 62 | |||
56 | # Darwin < 9 (Mac OS X < 10.5 "Leopard") doesn't have gethostuuid(2) | 63 | # Darwin < 9 (Mac OS X < 10.5 "Leopard") doesn't have gethostuuid(2) | |
57 | # and lacks the zone memory allocator | 64 | # and lacks the zone memory allocator | |
58 | .if !empty(MACHINE_PLATFORM:MDarwin-[0-8].*-*) | 65 | .if !empty(MACHINE_PLATFORM:MDarwin-[0-8].*-*) | |
59 | CFLAGS+= -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_WITHOUT_ZONEMALLOC | 66 | CFLAGS+= -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_WITHOUT_ZONEMALLOC | |
60 | .endif | 67 | .endif | |
61 | 68 | |||
62 | post-install: | 69 | post-install: | |
63 | ${INSTALL_PROGRAM} ${WRKSRC}/sapi/cli/php ${DESTDIR}${PREFIX}/bin/php | 70 | ${INSTALL_PROGRAM} ${WRKSRC}/sapi/cli/php ${DESTDIR}${PREFIX}/bin/php |
@@ -1,23 +1,18 @@ | @@ -1,23 +1,18 @@ | |||
1 | # $NetBSD: Makefile.php,v 1.6 2017/08/04 23:08:47 taca Exp $ | 1 | # $NetBSD: Makefile.php,v 1.7 2018/07/16 10:58:50 maya Exp $ | |
2 | # used by lang/php71/Makefile | 2 | # used by lang/php71/Makefile | |
3 | # used by www/ap-php/Makefile | 3 | # used by www/ap-php/Makefile | |
4 | # used by www/php-fpm/Makefile | 4 | # used by www/php-fpm/Makefile | |
5 | 5 | |||
6 | # PHP bug #74526 - segfaults on build with GCC 4.8.5 i386 | |||
7 | .if ${MACHINE_ARCH} == "i386" | |||
8 | GCC_REQD+= 4.9 | |||
9 | .endif | |||
10 | ||||
11 | .include "../../lang/php71/Makefile.common" | 6 | .include "../../lang/php71/Makefile.common" | |
12 | 7 | |||
13 | DISTINFO_FILE= ${.CURDIR}/../../lang/php71/distinfo | 8 | DISTINFO_FILE= ${.CURDIR}/../../lang/php71/distinfo | |
14 | PATCHDIR= ${.CURDIR}/../../lang/php71/patches | 9 | PATCHDIR= ${.CURDIR}/../../lang/php71/patches | |
15 | 10 | |||
16 | USE_LIBTOOL= YES | 11 | USE_LIBTOOL= YES | |
17 | USE_LANGUAGES= c c++ | 12 | USE_LANGUAGES= c c++ | |
18 | GNU_CONFIGURE= YES | 13 | GNU_CONFIGURE= YES | |
19 | BUILD_DEFS+= VARBASE | 14 | BUILD_DEFS+= VARBASE | |
20 | PLIST_VARS+= dtrace | 15 | PLIST_VARS+= dtrace | |
21 | 16 | |||
22 | CONFIGURE_ENV+= EXTENSION_DIR="${PREFIX}/${PHP_EXTENSION_DIR}" | 17 | CONFIGURE_ENV+= EXTENSION_DIR="${PREFIX}/${PHP_EXTENSION_DIR}" | |
23 | 18 |
@@ -1,20 +1,21 @@ | @@ -1,20 +1,21 @@ | |||
1 | # $NetBSD: Makefile,v 1.8 2018/04/26 15:44:15 taca Exp $ | 1 | # $NetBSD: Makefile,v 1.9 2018/07/16 10:58:50 maya Exp $ | |
2 | 2 | |||
3 | # | 3 | # | |
4 | # We can't omit PKGNAME here to handle PKG_OPTIONS. | 4 | # We can't omit PKGNAME here to handle PKG_OPTIONS. | |
5 | # | 5 | # | |
6 | PKGNAME= php-${PHP_VERSION:S/RC/rc/} | 6 | PKGNAME= php-${PHP_VERSION:S/RC/rc/} | |
7 | CATEGORIES= lang | 7 | CATEGORIES= lang | |
8 | PKGREVISION= 1 | |||
8 | 9 | |||
9 | HOMEPAGE= http://www.php.net/ | 10 | HOMEPAGE= http://www.php.net/ | |
10 | COMMENT= PHP Hypertext Preprocessor version 7.2 | 11 | COMMENT= PHP Hypertext Preprocessor version 7.2 | |
11 | LICENSE= php | 12 | LICENSE= php | |
12 | 13 | |||
13 | TEST_TARGET= test | 14 | TEST_TARGET= test | |
14 | 15 | |||
15 | USE_TOOLS+= gmake lex pkg-config | 16 | USE_TOOLS+= gmake lex pkg-config | |
16 | LIBTOOL_OVERRIDE= # empty | 17 | LIBTOOL_OVERRIDE= # empty | |
17 | PHP_CHECK_INSTALLED= No | 18 | PHP_CHECK_INSTALLED= No | |
18 | 19 | |||
19 | PHP_VERSIONS_ACCEPTED= 72 | 20 | PHP_VERSIONS_ACCEPTED= 72 | |
20 | 21 | |||
@@ -31,26 +32,32 @@ CONF_FILES= ${EGDIR}/php.ini-production | @@ -31,26 +32,32 @@ CONF_FILES= ${EGDIR}/php.ini-production | |||
31 | PLIST_SUBST+= PHPEXTDIR="${PHP_EXTENSION_DIR}" | 32 | PLIST_SUBST+= PHPEXTDIR="${PHP_EXTENSION_DIR}" | |
32 | 33 | |||
33 | SUBST_CLASSES+= path | 34 | SUBST_CLASSES+= path | |
34 | SUBST_MESSAGE.path= Fixing common paths. | 35 | SUBST_MESSAGE.path= Fixing common paths. | |
35 | SUBST_STAGE.path= pre-configure | 36 | SUBST_STAGE.path= pre-configure | |
36 | SUBST_FILES.path= ext/phar/phar/phar.php | 37 | SUBST_FILES.path= ext/phar/phar/phar.php | |
37 | SUBST_FILES.path+= php.ini-development php.ini-production run-tests.php | 38 | SUBST_FILES.path+= php.ini-development php.ini-production run-tests.php | |
38 | SUBST_FILES.path+= sapi/cgi/Makefile.frag | 39 | SUBST_FILES.path+= sapi/cgi/Makefile.frag | |
39 | SUBST_SED.path= -e 's,@CGIDIR@,${CGIDIR},g' | 40 | SUBST_SED.path= -e 's,@CGIDIR@,${CGIDIR},g' | |
40 | SUBST_SED.path+= -e 's,@PREFIX@,${PREFIX},g' | 41 | SUBST_SED.path+= -e 's,@PREFIX@,${PREFIX},g' | |
41 | 42 | |||
42 | INSTALLATION_DIRS+= ${CGIDIR} ${PHP_EXTENSION_DIR} ${EGDIR} share/php | 43 | INSTALLATION_DIRS+= ${CGIDIR} ${PHP_EXTENSION_DIR} ${EGDIR} share/php | |
43 | 44 | |||
45 | # segfaults when buidling with many compilers | |||
46 | # https://bugs.php.net/bug.php?id=74527 | |||
47 | .if ${MACHINE_ARCH} == "i386" | |||
48 | CONFIGURE_ARGS+= --disable-gcc-global-regs | |||
49 | .endif | |||
50 | ||||
44 | # Make sure modules can link correctly | 51 | # Make sure modules can link correctly | |
45 | .if ${OPSYS} == "Darwin" | 52 | .if ${OPSYS} == "Darwin" | |
46 | INSTALL_UNSTRIPPED= yes | 53 | INSTALL_UNSTRIPPED= yes | |
47 | .endif | 54 | .endif | |
48 | 55 | |||
49 | # Darwin < 9 (Mac OS X < 10.5 "Leopard") doesn't have gethostuuid(2) | 56 | # Darwin < 9 (Mac OS X < 10.5 "Leopard") doesn't have gethostuuid(2) | |
50 | # and lacks the zone memory allocator | 57 | # and lacks the zone memory allocator | |
51 | .if !empty(MACHINE_PLATFORM:MDarwin-[0-8].*-*) | 58 | .if !empty(MACHINE_PLATFORM:MDarwin-[0-8].*-*) | |
52 | CFLAGS+= -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_WITHOUT_ZONEMALLOC | 59 | CFLAGS+= -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_WITHOUT_ZONEMALLOC | |
53 | .endif | 60 | .endif | |
54 | 61 | |||
55 | post-install: | 62 | post-install: | |
56 | ${INSTALL_PROGRAM} ${WRKSRC}/sapi/cli/php ${DESTDIR}${PREFIX}/bin/php | 63 | ${INSTALL_PROGRAM} ${WRKSRC}/sapi/cli/php ${DESTDIR}${PREFIX}/bin/php |
@@ -1,23 +1,18 @@ | @@ -1,23 +1,18 @@ | |||
1 | # $NetBSD: Makefile.php,v 1.4 2018/02/05 08:51:25 jdolecek Exp $ | 1 | # $NetBSD: Makefile.php,v 1.5 2018/07/16 10:58:50 maya Exp $ | |
2 | # used by lang/php72/Makefile | 2 | # used by lang/php72/Makefile | |
3 | # used by www/ap-php/Makefile | 3 | # used by www/ap-php/Makefile | |
4 | # used by www/php-fpm/Makefile | 4 | # used by www/php-fpm/Makefile | |
5 | 5 | |||
6 | # PHP bug #74526 - segfaults on build with GCC 4.8.5 i386 | |||
7 | .if ${MACHINE_ARCH} == "i386" | |||
8 | GCC_REQD+= 4.9 | |||
9 | .endif | |||
10 | ||||
11 | # the binary actually needs full dep on PCRE | 6 | # the binary actually needs full dep on PCRE | |
12 | BUILDLINK_DEPMETHOD.pcre= full | 7 | BUILDLINK_DEPMETHOD.pcre= full | |
13 | 8 | |||
14 | .include "../../lang/php72/Makefile.common" | 9 | .include "../../lang/php72/Makefile.common" | |
15 | 10 | |||
16 | DISTINFO_FILE= ${.CURDIR}/../../lang/php72/distinfo | 11 | DISTINFO_FILE= ${.CURDIR}/../../lang/php72/distinfo | |
17 | PATCHDIR= ${.CURDIR}/../../lang/php72/patches | 12 | PATCHDIR= ${.CURDIR}/../../lang/php72/patches | |
18 | 13 | |||
19 | USE_LIBTOOL= YES | 14 | USE_LIBTOOL= YES | |
20 | USE_LANGUAGES= c c++ | 15 | USE_LANGUAGES= c c++ | |
21 | GNU_CONFIGURE= YES | 16 | GNU_CONFIGURE= YES | |
22 | BUILD_DEFS+= VARBASE | 17 | BUILD_DEFS+= VARBASE | |
23 | PLIST_VARS+= dtrace | 18 | PLIST_VARS+= dtrace |