-
-
Notifications
You must be signed in to change notification settings - Fork 47
/
ds@8.5.rb
37 lines (32 loc) · 1.45 KB
/
ds@8.5.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# typed: true
# frozen_string_literal: true
require File.expand_path("../Abstract/abstract-php-extension", __dir__)
# Class for Ds Extension
class DsAT85 < AbstractPhpExtension
init
desc "Ds PHP extension"
homepage "https://github.com/php-ds/ext-ds"
url "https://pecl.php.net/get/ds-1.5.0.tgz"
sha256 "2b2b45d609ca0958bda52098581ecbab2de749e0b3934d729de61a59226718b0"
head "https://github.com/php-ds/ext-ds.git", branch: "master"
license "MIT"
bottle do
root_url "https://ghcr.io/v2/shivammathur/extensions"
sha256 cellar: :any_skip_relocation, arm64_sequoia: "1c1d3162f6e543aea028d262da8da0821b1bbda294ade1984bd8207c938cf9fe"
sha256 cellar: :any_skip_relocation, arm64_sonoma: "8de22c9c47e53161ef33a627eccd362a0442e987b3958fdf8578a9f24fb4b451"
sha256 cellar: :any_skip_relocation, arm64_ventura: "e18ce3a503812b44697b8d4d0af7270aab3874e8f7fa0282c89fb24d3f51a9b7"
sha256 cellar: :any_skip_relocation, ventura: "c8ba43f914b99c024d152d0e9e16fd506620de0818a5d9b46f900eda997662bf"
sha256 cellar: :any_skip_relocation, x86_64_linux: "dda1b56d5c42694aecfbb8eaedf02a6584d53e7f781eabe8eab4c6bed319fdfd"
end
priority "30"
def install
Dir.chdir "ds-#{version}"
inreplace "src/common.h", "fast_add_function", "add_function"
safe_phpize
system "./configure", "--prefix=#{prefix}", phpconfig, "--enable-ds"
system "make"
prefix.install "modules/#{extension}.so"
write_config_file
add_include_files
end
end