From aa2269cbd053e6940d9542b05f9ba3425a6d05a81edf330d983f2d9e6caceb60 Mon Sep 17 00:00:00 2001 From: Michael Vetter Date: Wed, 20 Mar 2024 07:57:32 +0000 Subject: [PATCH] - bsc#1221709: Fix build with gcc14 Add unixODBC-gcc14.patch OBS-URL: https://build.opensuse.org/package/show/server:database/unixODBC?expand=0&rev=81 --- unixODBC-gcc14.patch | 31 +++++++++++++++++++++++++++++++ unixODBC.changes | 6 ++++++ unixODBC.spec | 5 ++++- 3 files changed, 41 insertions(+), 1 deletion(-) create mode 100644 unixODBC-gcc14.patch diff --git a/unixODBC-gcc14.patch b/unixODBC-gcc14.patch new file mode 100644 index 0000000..94e76dc --- /dev/null +++ b/unixODBC-gcc14.patch @@ -0,0 +1,31 @@ +Upstream: 249bfcc511e89431b910ce2c62ae0b62bb9cc214 +Index: unixODBC-2.3.12/Drivers/Postgre7.1/info.c +=================================================================== +--- unixODBC-2.3.12.orig/Drivers/Postgre7.1/info.c ++++ unixODBC-2.3.12/Drivers/Postgre7.1/info.c +@@ -1779,14 +1779,14 @@ char *table_name; + char index_name[MAX_INFO_STRING]; + short fields_vector[8]; + char isunique[10], isclustered[10]; +-SDWORD index_name_len, fields_vector_len; ++SQLLEN index_name_len, fields_vector_len; + TupleNode *row; + int i; + HSTMT hcol_stmt; + StatementClass *col_stmt, *indx_stmt; + char column_name[MAX_INFO_STRING], relhasrules[MAX_INFO_STRING]; + char **column_names = 0; +-Int4 column_name_len; ++SQLLEN column_name_len; + int total_columns = 0; + char error = TRUE; + ConnInfo *ci; +@@ -2136,7 +2136,7 @@ HSTMT htbl_stmt; + StatementClass *tbl_stmt; + char tables_query[STD_STATEMENT_LEN]; + char attname[MAX_INFO_STRING]; +-SDWORD attname_len; ++SQLLEN attname_len; + char pktab[MAX_TABLE_LEN + 1]; + Int2 result_cols; + diff --git a/unixODBC.changes b/unixODBC.changes index 231a876..cf685dc 100644 --- a/unixODBC.changes +++ b/unixODBC.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Mar 20 07:56:32 UTC 2024 - Michael Vetter + +- bsc#1221709: Fix build with gcc14 + Add unixODBC-gcc14.patch + ------------------------------------------------------------------- Tue Feb 20 15:44:12 UTC 2024 - Dominique Leuenberger diff --git a/unixODBC.spec b/unixODBC.spec index 682b6dc..71b2191 100644 --- a/unixODBC.spec +++ b/unixODBC.spec @@ -1,7 +1,7 @@ # # spec file for package unixODBC # -# Copyright (c) 2023 SUSE LLC +# Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -28,6 +28,8 @@ Source1: baselibs.conf Source2: unixODBC-rpmlintrc Patch0: unixODBC-paths.patch Patch1: unixODC-etc-location.patch +# bsc#1221709 gh#157 +Patch2: unixODBC-gcc14.patch BuildRequires: automake BuildRequires: bison BuildRequires: gcc-c++ @@ -66,6 +68,7 @@ Includes for ODBC development (based on unixODBC). %setup -q %patch -P 0 %patch -P 1 -p1 +%patch -P 2 -p1 chmod -x NEWS README doc/*.html doc/*.gif Drivers/README