Skip to content

Commit

Permalink
Merge pull request #198698 from Homebrew/pkgconf-migrations-r
Browse files Browse the repository at this point in the history
r*: migrate to `pkgconf`
  • Loading branch information
chenrui333 authored Nov 23, 2024
2 parents 55be551 + 113a821 commit 54d6a34
Show file tree
Hide file tree
Showing 36 changed files with 68 additions and 73 deletions.
2 changes: 1 addition & 1 deletion Formula/r/r.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class R < Formula
sha256 x86_64_linux: "6a984c21e657a33571022f0254219c0f220c225a9d39379f5e3240eedcd71188"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "cairo"
depends_on "gcc" # for gfortran
depends_on "gettext"
Expand Down
10 changes: 4 additions & 6 deletions Formula/r/r3.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,17 +32,15 @@ class R3 < Formula
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "jemalloc"
depends_on "pcre"

def install
system "./autogen.sh"
system "./configure", "--disable-debug",
"--disable-dependency-tracking",
"--disable-silent-rules",
"--prefix=#{prefix}",
"--with-malloc=jemalloc"
system "./configure", "--disable-silent-rules",
"--with-malloc=jemalloc",
*std_configure_args
system "make", "install"
end

Expand Down
2 changes: 1 addition & 1 deletion Formula/r/rabbitmq-c.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class RabbitmqC < Formula
end

depends_on "cmake" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "xmlto" => :build
depends_on "openssl@3"
depends_on "popt"
Expand Down
6 changes: 2 additions & 4 deletions Formula/r/rasqal.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class Rasqal < Formula
sha256 cellar: :any_skip_relocation, x86_64_linux: "2267d3f39fc7d088095d64bb6cf86f5fcad6c2a72fdd72dde8237cc910b123d1"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "raptor"

# Fix -flat_namespace being used on Big Sur and later.
Expand All @@ -38,9 +38,7 @@ class Rasqal < Formula
end

def install
system "./configure", "--prefix=#{prefix}",
"--with-html-dir=#{share}/doc",
"--disable-dependency-tracking"
system "./configure", "--with-html-dir=#{share}/doc", *std_configure_args
system "make", "install"
end
end
4 changes: 2 additions & 2 deletions Formula/r/rattler-build.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class RattlerBuild < Formula
sha256 cellar: :any_skip_relocation, x86_64_linux: "e30fa49f9291a7d3aa161e77e7a31eab390de8b2fbea90a985dfcea1f105c5ce"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "rust" => :build
depends_on "openssl@3"
depends_on "xz"
Expand Down Expand Up @@ -61,7 +61,7 @@ def install
- hello | grep "Hello World!"
YAML
system bin/"rattler-build", "build", "--recipe", "recipe/recipe.yaml"
assert_predicate testpath/"output/noarch/test-package-0.1.0-buildstring.conda", :exist?
assert_path_exists testpath/"output/noarch/test-package-0.1.0-buildstring.conda"

assert_match version.to_s, shell_output(bin/"rattler-build --version")
end
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/rdkit.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class Rdkit < Formula

depends_on "catch2" => :build
depends_on "cmake" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "postgresql@14" => [:build, :test]
depends_on "postgresql@17" => [:build, :test]
depends_on "boost"
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/recc.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class Recc < Formula
end

on_linux do
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "util-linux"
end

Expand Down
11 changes: 5 additions & 6 deletions Formula/r/redland.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ class Redland < Formula
sha256 x86_64_linux: "5439aed60715d12f7bce18e9292ce3301fc93b89cdb2eae2bd072a0a59a5fc6b"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "libtool"
depends_on "raptor"
depends_on "rasqal"
depends_on "sqlite"
Expand All @@ -47,12 +48,10 @@ class Redland < Formula
end

def install
system "./configure", "--disable-debug",
"--disable-dependency-tracking",
"--prefix=#{prefix}",
"--with-bdb=no",
system "./configure", "--with-bdb=no",
"--with-mysql=no",
"--with-sqlite=yes"
"--with-sqlite=yes",
*std_configure_args
system "make", "install"
end

Expand Down
8 changes: 3 additions & 5 deletions Formula/r/redshift.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,13 @@ class Redshift < Formula
end

depends_on "intltool" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "gettext"
depends_on "glib"

def install
args = %W[
--prefix=#{prefix}
args = %w[
--disable-silent-rules
--disable-dependency-tracking
--disable-geoclue
--disable-geoclue2
--with-systemduserunitdir=no
Expand All @@ -52,7 +50,7 @@ def install
end

system "./bootstrap" if build.head?
system "./configure", *args
system "./configure", *args, *std_configure_args
system "make", "install"
pkgshare.install "redshift.conf.sample"
end
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/redstore.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class Redstore < Formula
sha256 cellar: :any_skip_relocation, x86_64_linux: "f459a58381dd6067d033bb20eb4101af9136f5260796bd2daee07cf6365c3bde"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "raptor"
depends_on "rasqal"
depends_on "redland"
Expand Down
6 changes: 3 additions & 3 deletions Formula/r/redwax-tool.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@ class RedwaxTool < Formula
sha256 cellar: :any_skip_relocation, x86_64_linux: "5d5c0d21bc2469587576c4f1c97f65ab611e9e9f3deafa151d8dde7949ec12e3"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "apr"
depends_on "apr-util"
depends_on "openssl@3"

uses_from_macos "expat"

def install
system "./configure", *std_configure_args, "--disable-silent-rules", "--with-openssl"
system "./configure", "--disable-silent-rules", "--with-openssl", *std_configure_args
system "make", "install"
end

Expand Down Expand Up @@ -66,6 +66,6 @@ def install
assert_match s, output
end

assert_predicate testpath/"combined.pem", :exist?
assert_path_exists testpath/"combined.pem"
end
end
2 changes: 1 addition & 1 deletion Formula/r/retdec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class Retdec < Formula
depends_on "automake" => :build
depends_on "cmake" => :build
depends_on "libtool" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on macos: :catalina
depends_on "openssl@3"
depends_on "[email protected]"
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/rgbds.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class Rgbds < Formula

depends_on "bison" => :build
depends_on "cmake" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "rust" => :build
depends_on "libpng"

Expand Down
2 changes: 1 addition & 1 deletion Formula/r/riemann-client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class RiemannClient < Formula
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build

depends_on "json-c"
depends_on "openssl@3"
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/ripgrep.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class Ripgrep < Formula
end

depends_on "asciidoctor" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "rust" => :build
depends_on "pcre2"

Expand Down
14 changes: 7 additions & 7 deletions Formula/r/riscv64-elf-binutils.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class Riscv64ElfBinutils < Formula
sha256 x86_64_linux: "2d20f3c9e5b38bd284237023d75cd87e34224390064af224929fd51cf740e0a2"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "zstd"

uses_from_macos "zlib"
Expand All @@ -33,12 +33,12 @@ class Riscv64ElfBinutils < Formula
def install
target = "riscv64-elf"
system "./configure", "--target=#{target}",
"--prefix=#{prefix}",
"--libdir=#{lib}/#{target}",
"--infodir=#{info}/#{target}",
"--with-system-zlib",
"--with-zstd",
"--disable-nls"
"--prefix=#{prefix}",
"--libdir=#{lib}/#{target}",
"--infodir=#{info}/#{target}",
"--with-system-zlib",
"--with-zstd",
"--disable-nls"
system "make"
system "make", "install"
end
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/river.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class River < Formula
end

depends_on "cmake" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "rust" => :build
depends_on "openssl@3"

Expand Down
2 changes: 1 addition & 1 deletion Formula/r/rizin.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class Rizin < Formula

depends_on "meson" => :build
depends_on "ninja" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "capstone"
depends_on "libmagic"
depends_on "libzip"
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/rkflashtool.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class Rkflashtool < Formula
sha256 cellar: :any_skip_relocation, x86_64_linux: "c38a8b6e2f2f2b8dd7b437c07916c5624076f472392a2899fbb3c397c07bb4a3"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "libusb"

def install
Expand Down
6 changes: 5 additions & 1 deletion Formula/r/rmlint.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,16 @@ class Rmlint < Formula
end

depends_on "gettext" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "scons" => :build
depends_on "sphinx-doc" => :build
depends_on "glib"
depends_on "json-glib"

on_macos do
depends_on "gettext"
end

on_linux do
depends_on "elfutils"
depends_on "util-linux"
Expand Down
6 changes: 3 additions & 3 deletions Formula/r/rmw.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class Rmw < Formula

depends_on "meson" => :build
depends_on "ninja" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "canfigger"
depends_on "gettext"
# Slightly buggy with system ncurses
Expand All @@ -39,9 +39,9 @@ def install
file = testpath/"foo"
touch file
assert_match "removed", shell_output("#{bin}/rmw #{file}")
refute_predicate file, :exist?
refute_path_exists file
system bin/"rmw", "-u"
assert_predicate file, :exist?
assert_path_exists file
assert_match "/.local/share/Waste", shell_output("#{bin}/rmw -l")
assert_match "purging is disabled", shell_output("#{bin}/rmw -vvg")
end
Expand Down
4 changes: 2 additions & 2 deletions Formula/r/rojo.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class Rojo < Formula
sha256 cellar: :any_skip_relocation, x86_64_linux: "d455bb69759f1d0030ef0d1a7ee8a182f682eb169169c3c5084e0dca263ecc68"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "rust" => :build
depends_on "openssl@3"

Expand All @@ -33,7 +33,7 @@ def install

test do
system bin/"rojo", "init"
assert_predicate testpath/"default.project.json", :exist?
assert_path_exists testpath/"default.project.json"

assert_match version.to_s, shell_output(bin/"rojo --version")
end
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/rom-tools.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class RomTools < Formula
end

depends_on "asio" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "flac"
# Need C++ compiler and standard library support C++17.
depends_on macos: :high_sierra
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/root.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class Root < Formula

depends_on "cmake" => :build
depends_on "ninja" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "cfitsio"
depends_on "davix"
depends_on "fftw"
Expand Down
8 changes: 4 additions & 4 deletions Formula/r/rpki-client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class RpkiClient < Formula
sha256 x86_64_linux: "ba880cf10fd69db73ab54d1b861bb35ebbf15f91333bce53e9ab64dbdb739817"
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "libretls"
depends_on "openssl@3"
depends_on "rsync"
Expand All @@ -28,11 +28,11 @@ class RpkiClient < Formula
uses_from_macos "zlib"

def install
system "./configure", *std_configure_args,
"--with-rsync=#{Formula["rsync"].opt_bin}/rsync",
system "./configure", "--with-rsync=#{Formula["rsync"].opt_bin}/rsync",
"--disable-silent-rules",
"--sysconfdir=#{etc}",
"--localstatedir=#{var}"
"--localstatedir=#{var}",
*std_configure_args
system "make", "install"
end

Expand Down
2 changes: 1 addition & 1 deletion Formula/r/rrdtool.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class Rrdtool < Formula
depends_on "libtool" => :build
end

depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "cairo"
depends_on "glib"
depends_on "libpng"
Expand Down
2 changes: 1 addition & 1 deletion Formula/r/rsgain.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class Rsgain < Formula
end

depends_on "cmake" => :build
depends_on "pkg-config" => :build
depends_on "pkgconf" => :build
depends_on "ffmpeg"
depends_on "fmt"
depends_on "inih"
Expand Down
Loading

0 comments on commit 54d6a34

Please sign in to comment.