11# SPEC file for dblink_plus
2- # Copyright(C) 2016 NIPPON TELEGRAPH AND TELEPHONE CORPORATION
2+ # Copyright(C) 2019 NIPPON TELEGRAPH AND TELEPHONE CORPORATION
33
4- %define _pgdir /usr/pgsql-9.6
4+ %define _pgdir /usr/pgsql-12
55%define _bindir %{_pgdir }/bin
66%define _libdir %{_pgdir }/lib
77%define _datadir %{_pgdir }/share/extension
8+ %define _bcdir %{_libdir }/bitcode/dblink_plus
9+ %define _bc_ind_dir %{_libdir }/bitcode
810
911## Set general information
1012Summary: PostgreSQL module to connect PostgreSQL/Oracle
1113Name: dblink_plus
12- Version: 1.0.2
14+ Version: 1.0.5
1315Release: 1%{?dist }
1416License: BSD
1517Group: Applications/Databases
@@ -21,21 +23,31 @@ Vendor: NIPPON TELEGRAPH AND TELEPHONE CORPORATION
2123AutoReqProv: no
2224
2325## We use postgresql-devel package
24- BuildRequires: postgresql96 -devel
25- Requires: postgresql96 -libs
26+ BuildRequires: postgresql12 -devel
27+ Requires: postgresql12 -libs
2628
2729## Description
2830%description
2931dblink_plus is a PostgreSQL module which supports connections to other databases.
3032It is similar to contrib/dblink except that it can connect to Oracle, MySQL and sqlite3.
3133
34+ Note that this package is available for only PostgreSQL 12.
35+
36+ %package llvmjit
37+ Requires: postgresql11-server, postgresql12-llvmjit
38+ Requires: dblink_plus = 1.0.5
39+ Summary: Just-in-time compilation support for dblink_plus
40+
41+ %description llvmjit
42+ Just-in-time compilation support for dblink_plus 1.0.5
43+
3244## prework
3345%prep
3446%setup -q -n %{name }-%{version }
3547
3648## Set variables for build environment
3749%build
38- USE_PGXS=1 make %{?_smp_mflags } MYSQL=0 SQLITE3=0
50+ USE_PGXS=1 make %{?_smp_mflags } MYSQL=0 SQLITE3=0 ORACLE=0
3951
4052## Set variables for install
4153%install
@@ -45,11 +57,14 @@ install -d %{buildroot}%{_libdir}
4557install -m 755 dblink_plus.so %{buildroot }%{_libdir }/dblink_plus.so
4658install -d %{buildroot }%{_datadir }
4759install -m 755 dblink_plus.sql %{buildroot }%{_datadir }/dblink_plus.sql
48- install -m 755 dblink_plus--1.0.2 .sql %{buildroot }%{_datadir }/dblink_plus--1.0.2 .sql
60+ install -m 755 dblink_plus--1.0.5 .sql %{buildroot }%{_datadir }/dblink_plus--1.0.5 .sql
4961install -m 755 dblink_plus.control %{buildroot }%{_datadir }/dblink_plus.control
5062install -m 755 uninstall_dblink_plus.sql %{buildroot }%{_datadir }/uninstall_dblink_plus.sql
5163install -m 755 COPYRIGHT %{buildroot }%{_datadir }/COPYRIGHT_dblink_plus
52-
64+ install -d %{buildroot }%{_bcdir }
65+ install -m 644 dblink.bc %{buildroot }%{_bcdir }/dblink.bc
66+ install -m 644 dblink_postgres.bc %{buildroot }%{_bcdir }/dblink_postgres.bc
67+ install -m 644 dblink_plus.index.bc %{buildroot }%{_bc_ind_dir }/dblink_plus.index.bc
5368
5469%clean
5570rm -rf %{buildroot }
@@ -58,12 +73,20 @@ rm -rf %{buildroot}
5873%defattr(755,root,root)
5974%{_libdir }/dblink_plus.so
6075%{_datadir }/dblink_plus.sql
61- %{_datadir }/dblink_plus--1.0.2 .sql
76+ %{_datadir }/dblink_plus--1.0.5 .sql
6277%{_datadir }/dblink_plus.control
6378%{_datadir }/uninstall_dblink_plus.sql
6479%{_datadir }/COPYRIGHT_dblink_plus
6580
81+ %files llvmjit
82+ %defattr(0644,root,root,0755)
83+ %{_bcdir }
84+ %defattr(0644,root,root)
85+ %{_bc_ind_dir }/dblink_plus.index.bc
86+
6687# History.
6788%changelog
68- * Thu Oct 13 2016 - NTT OSS Center <furutani.kaname@lab.ntt.co.jp> 1.0.2-1
69- initial packaging
89+ * Mon Nov 25 2019 - NTT OSS Center <keisuke.kuroda.3862@gmail.com> 1.0.5-1
90+ Support PG12.
91+ * Tue Jan 22 2019 - NTT OSS Center <tatsuro.yamada@lab.ntt.co.jp> 1.0.4-1
92+ Support PG11.
0 commit comments