Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 5 additions & 10 deletions .github/workflows/binary-gems.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,14 @@ jobs:
rcd_build:
name: Build
runs-on: ubuntu-latest
env:
RCD_IMAGE_VERSION: snapshot
# env:
# RCD_IMAGE_VERSION: snapshot
strategy:
fail-fast: false
matrix:
include:
- platform: "x64-mingw-ucrt"
- platform: "x64-mingw32"
- platform: "x86-mingw32"
- platform: "x86_64-linux"
- platform: "x86_64-linux-musl"
- platform: "aarch64-linux"
Expand Down Expand Up @@ -67,12 +66,8 @@ jobs:
matrix:
include:
- os: windows-latest
ruby: "3.4"
ruby: "4.0"
platform: "x64-mingw-ucrt"
- os: windows-latest
ruby: "3.2.9-1"
platform: "x86-mingw32"
PGVERSION: 10.20-1-windows
- os: windows-latest
ruby: "3.2"
platform: "x64-mingw-ucrt"
Expand All @@ -81,10 +76,10 @@ jobs:
ruby: "3.2"
platform: "x86_64-linux"
- os: ubuntu-24.04-arm
ruby: "3.4"
ruby: "4.0"
platform: "aarch64-linux"
- os: macos-latest
ruby: "3.4"
ruby: "4.0"
platform: "arm64-darwin"
- os: macos-15-intel
ruby: "3.4"
Expand Down
6 changes: 3 additions & 3 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# -*- ruby -*-

# Specify your gem's runtime dependencies in pg.gemspec
gemspec
# No pg gem, since "bundle package" fails on bundler-2.7+, if the extension isn't built
# gemspec

source "https://rubygems.org/"

Expand All @@ -13,7 +13,7 @@ end
group :test do
gem "bundler", ">= 1.16", "< 5.0"
gem "rake-compiler", "~> 1.0"
gem "rake-compiler-dock", "~> 1.10.0", git: "https://github.com/rake-compiler/rake-compiler-dock"
gem "rake-compiler-dock", "~> 1.11.0" #, git: "https://github.com/rake-compiler/rake-compiler-dock"
gem "rspec", "~> 3.5"
# "bigdecimal" is a gem on ruby-3.4+ and it's optional for ruby-pg.
# Specs should succeed without it, but 4 examples are then excluded.
Expand Down
5 changes: 3 additions & 2 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,8 @@ task 'gem:native:prepare' do
# Copy gem signing key and certs to be accessible from the docker container
mkdir_p 'build/gem'
sh "cp ~/.gem/gem-*.pem build/gem/ || true"
sh "bundle package --all"
sh "bundle config set cache_all false"
sh "bundle package"
begin
OpenSSL::PKey.read(File.read(File.expand_path("~/.gem/gem-private_key.pem")), ENV["GEM_PRIVATE_KEY_PASSPHRASE"] || "")
rescue OpenSSL::PKey::PKeyError
Expand All @@ -126,7 +127,7 @@ CrossLibraries.each do |xlib|
sudo apt-get update && sudo apt-get install -y bison flex &&
(cp build/gem/gem-*.pem ~/.gem/ || true) &&
bundle install --local &&
rake native:#{platform} pkg/#{$gem_spec.full_name}-#{platform}.gem MAKEFLAGS="-j`nproc` V=1" RUBY_CC_VERSION=#{RakeCompilerDock.ruby_cc_version("~>2.7", "~>3.0")}
rake native:#{platform} pkg/#{$gem_spec.full_name}-#{platform}.gem MAKEFLAGS="-j`nproc` V=1" RUBY_CC_VERSION=#{RakeCompilerDock.ruby_cc_version("~>4.0", "~>3.0")}
EOT
end
desc "Build the native binary gems"
Expand Down
4 changes: 2 additions & 2 deletions ext/extconf.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@
gem 'mini_portile2', '~>2.1'
require 'mini_portile2'

OPENSSL_VERSION = ENV['OPENSSL_VERSION'] || '3.5.2'
OPENSSL_VERSION = ENV['OPENSSL_VERSION'] || '3.6.0'
OPENSSL_SOURCE_URI = "http://www.openssl.org/source/openssl-#{OPENSSL_VERSION}.tar.gz"

KRB5_VERSION = ENV['KRB5_VERSION'] || '1.22.1'
KRB5_SOURCE_URI = "http://kerberos.org/dist/krb5/#{KRB5_VERSION[/^(\d+\.\d+)/]}/krb5-#{KRB5_VERSION}.tar.gz"

POSTGRESQL_VERSION = ENV['POSTGRESQL_VERSION'] || '17.6'
POSTGRESQL_VERSION = ENV['POSTGRESQL_VERSION'] || '18.1'
POSTGRESQL_SOURCE_URI = "http://ftp.postgresql.org/pub/source/v#{POSTGRESQL_VERSION}/postgresql-#{POSTGRESQL_VERSION}.tar.bz2"

class BuildRecipe < MiniPortile
Expand Down
Loading