diff --git a/databases/rubygem-gitlab-pg_query/Makefile b/databases/rubygem-gitlab-pg_query/Makefile index ca6698e3ad36..f92397895da1 100644 --- a/databases/rubygem-gitlab-pg_query/Makefile +++ b/databases/rubygem-gitlab-pg_query/Makefile @@ -2,8 +2,8 @@ # $FreeBSD$ PORTNAME= gitlab-pg_query -PORTVERSION= 1.3.0 -PORTREVISION= 1 +PORTVERSION= 1.3.1 +PORTREVISION= 0 CATEGORIES= databases rubygems MASTER_SITES= RG diff --git a/databases/rubygem-gitlab-pg_query/distinfo b/databases/rubygem-gitlab-pg_query/distinfo index f8775c785407..303e69eae455 100644 --- a/databases/rubygem-gitlab-pg_query/distinfo +++ b/databases/rubygem-gitlab-pg_query/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1605910010 -SHA256 (rubygem/gitlab-pg_query-1.3.0.gem) = 98c66602fdf054dc57dff8b91925e57fa7b43015c9c699dc6f6d6de31fd27f77 -SIZE (rubygem/gitlab-pg_query-1.3.0.gem) = 35328 +TIMESTAMP = 1609489189 +SHA256 (rubygem/gitlab-pg_query-1.3.1.gem) = ef28bf4639a749db9efb8d9f5358bd1ff43e1039a2371c88b95b51e6658ecbe7 +SIZE (rubygem/gitlab-pg_query-1.3.1.gem) = 35328 diff --git a/databases/rubygem-gitlab-pg_query/files/patch-ext_pg__query_extconf.rb b/databases/rubygem-gitlab-pg_query/files/patch-ext_pg__query_extconf.rb index ad8932157df4..5189d50430f5 100644 --- a/databases/rubygem-gitlab-pg_query/files/patch-ext_pg__query_extconf.rb +++ b/databases/rubygem-gitlab-pg_query/files/patch-ext_pg__query_extconf.rb @@ -1,28 +1,35 @@ ---- ext/pg_query/extconf.rb.orig 2020-11-21 10:30:23 UTC +--- ext/pg_query/extconf.rb.orig 2021-01-01 08:22:43 UTC +++ ext/pg_query/extconf.rb -@@ -3,44 +3,12 @@ +@@ -4,53 +4,9 @@ require 'digest' require 'mkmf' require 'open-uri' --LIB_PG_QUERY_TAG = 'gitlab-10-1.0.3'.freeze +-LIB_PG_QUERY_TAG = '10-1.0.3'.freeze - workdir = Dir.pwd -libdir = File.join(workdir, 'libpg_query-' + LIB_PG_QUERY_TAG) gemdir = File.join(__dir__, '../..') -libfile = libdir + '/libpg_query.a' --unless File.exist?("#{workdir}/libpg_query.tar.gz") -- File.open("#{workdir}/libpg_query.tar.gz", 'wb') do |target_file| -- open("https://gitlab.com/gitlab-org/libpg_query/-/archive/#{LIB_PG_QUERY_TAG}/libpg_query-#{LIB_PG_QUERY_TAG}.tar.gz", 'rb') do |read_file| +-expected_sha256 = '1332761f31c198cb9825e6ccccda0b6a0e57daeb824870e8524df77f1592d149' +-filename = "#{workdir}/libpg_query.tar.gz" +- +-unless File.exist?(filename) +- File.open(filename, 'wb') do |target_file| +- URI.open('https://codeload.github.com/lfittl/libpg_query/tar.gz/' + LIB_PG_QUERY_TAG, 'rb') do |read_file| - target_file.write(read_file.read) - end - end +- +- checksum = Digest::SHA256.hexdigest(File.read(filename)) +- +- if checksum != expected_sha256 +- raise "SHA256 of #{filename} does not match: got #{checksum}, expected #{expected_sha256}" +- end -end -+abort "pgquery is missing" unless find_header('pg_query.h') -+abort "pgquery is missing" unless find_library('pg_query', 'pg_query_init') - +- -unless Dir.exist?(libdir) -- system("tar -xzf #{workdir}/libpg_query.tar.gz") || raise('ERROR') +- system("tar -xzf #{filename}") || raise('ERROR') -end - -unless Dir.exist?(libfile)