From c67e7c788f07f1b8f014272d832569a12ce5bac0 Mon Sep 17 00:00:00 2001 From: Andy Pfister Date: Tue, 19 Nov 2024 11:14:32 +0100 Subject: [PATCH] Bump OpenSSL to v3.4.0 Also bump the cache key to force a recompilation of freetds against the new OpenSSL version. --- .github/workflows/ci.yml | 14 +++++++------- CHANGELOG.md | 2 +- ext/tiny_tds/extconsts.rb | 2 +- tasks/ports.rake | 4 ++-- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1ad2aafe..0497589c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,10 +35,10 @@ jobs: uses: actions/cache@v4 with: path: ports - key: cross-compiled-${{ matrix.platform }}-${{ hashFiles('**/.ports_versions') }} + key: cross-compiled-v3-${{ matrix.platform }}-${{ hashFiles('**/.ports_versions') }} restore-keys: | - cross-compiled-${{ matrix.platform }}-${{ hashFiles('**/.ports_versions') }} - cross-compiled-${{ matrix.platform }}- + cross-compiled-v3-${{ matrix.platform }}-${{ hashFiles('**/.ports_versions') }} + cross-compiled-v3-${{ matrix.platform }}- - name: Build gem shell: bash @@ -351,10 +351,10 @@ jobs: uses: actions/cache@v4 with: path: ports - key: native-${{ hashFiles('**/.ports_versions') }} + key: native-v3-${{ hashFiles('**/.ports_versions') }} restore-keys: | - native-${{ hashFiles('* */.ports_versions') }} - native- + native-v3-${{ hashFiles('* */.ports_versions') }} + native-v3- - name: Build required libraries run: | @@ -394,7 +394,7 @@ jobs: uses: actions/cache@v4 with: path: ports - key: native-${{ hashFiles('**/.ports_versions') }} + key: native-v3-${{ hashFiles('**/.ports_versions') }} fail-on-cache-miss: true - name: Build gem diff --git a/CHANGELOG.md b/CHANGELOG.md index f95deac6..9761fbbb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,7 @@ * Drop support for SQL Server < 2017 * Drop support for FreeTDS < 1.0 * Raise error if FreeTDS is unable to sent command buffer to the server -* Use freetds v1.4.23 and libiconv v1.17 for Windows builds +* Use freetds v1.4.23, libiconv v1.17 and OpenSSL v3.4.0 for Windows builds ## 2.1.7 * Add Ruby 3.3 to the cross compile list diff --git a/ext/tiny_tds/extconsts.rb b/ext/tiny_tds/extconsts.rb index 19f9a133..64af1704 100644 --- a/ext/tiny_tds/extconsts.rb +++ b/ext/tiny_tds/extconsts.rb @@ -2,7 +2,7 @@ ICONV_VERSION = ENV['TINYTDS_ICONV_VERSION'] || "1.17" ICONV_SOURCE_URI = "http://ftp.gnu.org/pub/gnu/libiconv/libiconv-#{ICONV_VERSION}.tar.gz" -OPENSSL_VERSION = ENV['TINYTDS_OPENSSL_VERSION'] || '1.1.1s' +OPENSSL_VERSION = ENV['TINYTDS_OPENSSL_VERSION'] || '3.4.0' OPENSSL_SOURCE_URI = "https://www.openssl.org/source/openssl-#{OPENSSL_VERSION}.tar.gz" FREETDS_VERSION = ENV['TINYTDS_FREETDS_VERSION'] || '1.4.23' diff --git a/tasks/ports.rake b/tasks/ports.rake index 451267f7..1ab6bf96 100644 --- a/tasks/ports.rake +++ b/tasks/ports.rake @@ -48,10 +48,10 @@ namespace :ports do if libraries_to_compile[:openssl] # freetds doesn't have an option that will provide an rpath # so we do it manually - ENV['OPENSSL_CFLAGS'] = "-Wl,-rpath -Wl,#{libraries_to_compile[:openssl].path}/lib" + ENV['OPENSSL_CFLAGS'] = "-Wl,-rpath -Wl,#{libraries_to_compile[:openssl].path}/lib64" # Add the pkgconfig file with MSYS2'ish path, to prefer our ports build # over MSYS2 system OpenSSL. - ENV['PKG_CONFIG_PATH'] = "#{libraries_to_compile[:openssl].path.gsub(/^(\w):/i) { "/" + $1.downcase }}/lib/pkgconfig:#{ENV['PKG_CONFIG_PATH']}" + ENV['PKG_CONFIG_PATH'] = "#{libraries_to_compile[:openssl].path.gsub(/^(\w):/i) { "/" + $1.downcase }}/lib64/pkgconfig:#{ENV['PKG_CONFIG_PATH']}" libraries_to_compile[:freetds].configure_options << "--with-openssl=#{libraries_to_compile[:openssl].path}" end