Skip to content

Commit

Permalink
Update formulae --build-all
Browse files Browse the repository at this point in the history
  • Loading branch information
shivammathur committed Jul 2, 2020
1 parent 0cfe9f3 commit 1e8dc68
Show file tree
Hide file tree
Showing 8 changed files with 43 additions and 39 deletions.
4 changes: 2 additions & 2 deletions Formula/php.rb
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ def install
system "make", "install"

# Allow pecl to install outside of Cellar
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
orig_ext_dir = File.basename(extension_dir)
inreplace bin/"php-config", lib/"php", prefix/"pecl"
inreplace "php.ini-development", %r{; ?extension_dir = "\./"},
Expand Down Expand Up @@ -236,7 +236,7 @@ def post_install
# Custom location for extensions installed via pecl
pecl_path = HOMEBREW_PREFIX/"lib/php/pecl"
ln_s pecl_path, prefix/"pecl" unless (prefix/"pecl").exist?
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
php_basename = File.basename(extension_dir)
php_ext_dir = opt_prefix/"lib/php"/php_basename

Expand Down
11 changes: 9 additions & 2 deletions Formula/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -174,12 +174,19 @@ def install
system "make", "install"

# Allow pecl to install outside of Cellar
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
orig_ext_dir = File.basename(extension_dir)
inreplace bin/"php-config", lib/"php", prefix/"pecl"
inreplace "php.ini-development", %r{; ?extension_dir = "\./"},
"extension_dir = \"#{HOMEBREW_PREFIX}/lib/php/pecl/#{orig_ext_dir}\""

# Use OpenSSL cert bundle
openssl = Formula["[email protected]"]
inreplace "php.ini-development", /; ?openssl\.cafile=/,
"openssl.cafile = \"#{openssl.pkgetc}/cert.pem\""
inreplace "php.ini-development", /; ?openssl\.capath=/,
"openssl.capath = \"#{openssl.pkgetc}/certs\""

config_files = {
"php.ini-development" => "php.ini",
"sapi/fpm/php-fpm.conf" => "php-fpm.conf",
Expand Down Expand Up @@ -218,7 +225,7 @@ def post_install
# Custom location for extensions installed via pecl
pecl_path = HOMEBREW_PREFIX/"lib/php/pecl"
ln_s pecl_path, prefix/"pecl" unless (prefix/"pecl").exist?
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
php_basename = File.basename(extension_dir)
php_ext_dir = opt_prefix/"lib/php"/php_basename

Expand Down
11 changes: 9 additions & 2 deletions Formula/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -173,12 +173,19 @@ def install
system "make", "install"

# Allow pecl to install outside of Cellar
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
orig_ext_dir = File.basename(extension_dir)
inreplace bin/"php-config", lib/"php", prefix/"pecl"
inreplace "php.ini-development", %r{; ?extension_dir = "\./"},
"extension_dir = \"#{HOMEBREW_PREFIX}/lib/php/pecl/#{orig_ext_dir}\""

# Use OpenSSL cert bundle
openssl = Formula["[email protected]"]
inreplace "php.ini-development", /; ?openssl\.cafile=/,
"openssl.cafile = \"#{openssl.pkgetc}/cert.pem\""
inreplace "php.ini-development", /; ?openssl\.capath=/,
"openssl.capath = \"#{openssl.pkgetc}/certs\""

config_files = {
"php.ini-development" => "php.ini",
"sapi/fpm/php-fpm.conf" => "php-fpm.conf",
Expand Down Expand Up @@ -218,7 +225,7 @@ def post_install
# Custom location for extensions installed via pecl
pecl_path = HOMEBREW_PREFIX/"lib/php/pecl"
ln_s pecl_path, prefix/"pecl" unless (prefix/"pecl").exist?
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
php_basename = File.basename(extension_dir)
php_ext_dir = opt_prefix/"lib/php"/php_basename

Expand Down
9 changes: 5 additions & 4 deletions Formula/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -166,17 +166,18 @@ def install
system "make", "install"

# Allow pecl to install outside of Cellar
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
orig_ext_dir = File.basename(extension_dir)
inreplace bin/"php-config", lib/"php", prefix/"pecl"
inreplace "php.ini-development", %r{; ?extension_dir = "\./"},
"extension_dir = \"#{HOMEBREW_PREFIX}/lib/php/pecl/#{orig_ext_dir}\""

# Use OpenSSL cert bundle
openssl = Formula["[email protected]"]
inreplace "php.ini-development", /; ?openssl\.cafile=/,
"openssl.cafile = \"#{etc}/openssl@1.1/cert.pem\""
"openssl.cafile = \"#{openssl.pkgetc}/cert.pem\""
inreplace "php.ini-development", /; ?openssl\.capath=/,
"openssl.capath = \"#{etc}/openssl@1.1/certs\""
"openssl.capath = \"#{openssl.pkgetc}/certs\""

config_files = {
"php.ini-development" => "php.ini",
Expand Down Expand Up @@ -217,7 +218,7 @@ def post_install
# Custom location for extensions installed via pecl
pecl_path = HOMEBREW_PREFIX/"lib/php/pecl"
ln_s pecl_path, prefix/"pecl" unless (prefix/"pecl").exist?
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
php_basename = File.basename(extension_dir)
php_ext_dir = opt_prefix/"lib/php"/php_basename

Expand Down
6 changes: 3 additions & 3 deletions Formula/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class PhpAT72 < Formula

keg_only :versioned_formula

deprecate! :date => "November 30, 2020"
deprecate! :date => "2020-11-30"

depends_on "httpd" => [:build, :test]
depends_on "pkg-config" => :build
Expand Down Expand Up @@ -178,7 +178,7 @@ def install
system "make", "install"

# Allow pecl to install outside of Cellar
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
orig_ext_dir = File.basename(extension_dir)
inreplace bin/"php-config", lib/"php", prefix/"pecl"
inreplace "php.ini-development", %r{; ?extension_dir = "\./"},
Expand Down Expand Up @@ -230,7 +230,7 @@ def post_install
# Custom location for extensions installed via pecl
pecl_path = HOMEBREW_PREFIX/"lib/php/pecl"
ln_s pecl_path, prefix/"pecl" unless (prefix/"pecl").exist?
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
php_basename = File.basename(extension_dir)
php_ext_dir = opt_prefix/"lib/php"/php_basename

Expand Down
6 changes: 3 additions & 3 deletions Formula/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class PhpAT73 < Formula

keg_only :versioned_formula

deprecate! :date => "December 6, 2021"
deprecate! :date => "2021-12-06"

depends_on "httpd" => [:build, :test]
depends_on "pkg-config" => :build
Expand Down Expand Up @@ -178,7 +178,7 @@ def install
system "make", "install"

# Allow pecl to install outside of Cellar
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
orig_ext_dir = File.basename(extension_dir)
inreplace bin/"php-config", lib/"php", prefix/"pecl"
inreplace "php.ini-development", %r{; ?extension_dir = "\./"},
Expand Down Expand Up @@ -235,7 +235,7 @@ def post_install
# Custom location for extensions installed via pecl
pecl_path = HOMEBREW_PREFIX/"lib/php/pecl"
ln_s pecl_path, prefix/"pecl" unless (prefix/"pecl").exist?
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
php_basename = File.basename(extension_dir)
php_ext_dir = opt_prefix/"lib/php"/php_basename

Expand Down
14 changes: 8 additions & 6 deletions Formula/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,15 @@ class PhpAT80 < Formula

keg_only :versioned_formula

depends_on "bison" => :build
depends_on "httpd" => [:build, :test]
depends_on "pkg-config" => :build
depends_on "re2c" => :build
depends_on "apr"
depends_on "apr-util"
depends_on "argon2"
depends_on "aspell"
depends_on "autoconf"
depends_on "bison"
depends_on "curl-openssl"
depends_on "freetds"
depends_on "freetype"
Expand All @@ -36,7 +37,7 @@ class PhpAT80 < Formula
depends_on "oniguruma"
depends_on "openldap"
depends_on "[email protected]"
depends_on "re2c"

depends_on "sqlite"
depends_on "tidyp"
depends_on "unixodbc"
Expand Down Expand Up @@ -183,17 +184,18 @@ def install
system "make", "install"

# Allow pecl to install outside of Cellar
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
orig_ext_dir = File.basename(extension_dir)
inreplace bin/"php-config", lib/"php", prefix/"pecl"
inreplace "php.ini-development", %r{; ?extension_dir = "\./"},
"extension_dir = \"#{HOMEBREW_PREFIX}/lib/php/pecl/#{orig_ext_dir}\""

# Use OpenSSL cert bundle
openssl = Formula["[email protected]"]
inreplace "php.ini-development", /; ?openssl\.cafile=/,
"openssl.cafile = \"#{etc}/openssl@1.1/cert.pem\""
"openssl.cafile = \"#{openssl.pkgetc}/cert.pem\""
inreplace "php.ini-development", /; ?openssl\.capath=/,
"openssl.capath = \"#{etc}/openssl@1.1/certs\""
"openssl.capath = \"#{openssl.pkgetc}/certs\""

config_files = {
"php.ini-development" => "php.ini",
Expand Down Expand Up @@ -234,7 +236,7 @@ def post_install
# Custom location for extensions installed via pecl
pecl_path = HOMEBREW_PREFIX/"lib/php/pecl"
ln_s pecl_path, prefix/"pecl" unless (prefix/"pecl").exist?
extension_dir = Utils.popen_read("#{bin}/php-config --extension-dir").chomp
extension_dir = Utils.safe_popen_read("#{bin}/php-config --extension-dir").chomp
php_basename = File.basename(extension_dir)
php_ext_dir = opt_prefix/"lib/php"/php_basename

Expand Down
21 changes: 4 additions & 17 deletions Patches/openssl.patch
Original file line number Diff line number Diff line change
@@ -1,21 +1,8 @@
Subject: [PATCH] PHP 5.6 - LibSSL 1.1 compatibility
From c24860dc09845d3d2538ec7447e5edec638e029d Mon Sep 17 00:00:00 2001
From: zsalab <[email protected]>
Date: Tue, 1 Aug 2017 01:43:04 +0200
Subject: OpenSSL 1.1.0 compatibility

This patch does not try to backport the 7.1 openssl module, it is the
improved version of the 5.6 original openssl module.

https://github.com/oerdnj/deb.sury.org/issues/566
http://zettasystem.com/PHP-5.6.31-OpenSSL-1.1.0-compatibility-20170801.patch

Upstream-Status: Deny [https://github.com/php/php-src/pull/2667]
Reason: As PHP 5.6 is no longer actively supported only security fixes
may land on this branch. As this change does not fall in this category,
I'm closing this PR. (All higher versions of PHP already have OpenSSL
1.1 support.)

Author: zsalab@github https://github.com/zsalab

Only port source modification, do not include the test case
Signed-off-by: Hongxu Jia <[email protected]>
---
ext/openssl/openssl.c | 683 +++++++++++++++++++++++++++++++++++++-------------
ext/openssl/xp_ssl.c | 18 +-
Expand Down

0 comments on commit 1e8dc68

Please sign in to comment.