source: projects/specs/branches/6/u/unixODBC/unixODBC-vl.spec @ 3409

Revision 3409, 11.0 KB checked in by iwaim, 13 years ago (diff)

unixODBC-2.2.14-2

Line 
1%define __libtoolize true
2
3%define _qt4_version %(pkg-config --modversion --silence-errors Qt 2>/dev/null || echo 4.7.2)
4%define _qt4_bindir %(pkg-config --variable bindir --silence-errors Qt 2>/dev/null || echo %{_libdir}/qt-%{_qt4_version}/bin)
5
6Name: unixODBC
7Summary: A complete ODBC Driver Manager for Linux
8Version: 2.2.14
9Release: 2%{?_dist_release}
10
11Group: System Environment/Libraries
12# Programs are GPL, libraries are LGPL, except News Server library is GPL.
13License: GPLv2+ and LGPLv2+
14URL: http://www.unixODBC.org/
15
16Source: http://www.unixODBC.org/%{name}-%{version}.tar.gz
17Source1: odbcinst.ini
18Source2: ODBCConfig.desktop
19Source3: DataManager.desktop
20Source4: conffile.h
21
22Patch1: depcomp.patch
23Patch2: multilib-config.patch
24Patch3: warning-cleanup.patch
25Patch6: export-symbols.patch
26Patch7: libtool-config.patch
27Patch8: so-version-bump.patch
28Patch9: keep-typedefs.patch
29Patch10: odbcint64-config.patch
30Patch11: enable-items.patch
31Patch12: isql-fixes.patch
32Conflicts: iodbc
33
34BuildRoot: %{_tmppath}/%{name}-%{version}-root
35BuildRequires: libX11-devel libXt-devel libXext-devel
36BuildRequires: qt4-devel qt-assistant-adp-devel readline-devel
37BuildRequires: automake autoconf libtool libtool-ltdl-devel bison flex
38BuildRequires: desktop-file-utils
39
40%description
41The unixODBC Project goals are to develop and promote unixODBC to
42be the definitive standard for ODBC on the Linux platform. This is to
43include GUI support for KDE.
44
45Install unixODBC if you'd like to access databases through ODBC. This
46package include drivers for PostgreSQL and local files.
47
48If you want to develop programs that will access data through ODBC,
49you'll also need to have the unixODBC package installed.
50
51%package devel
52Summary: Development files for programs which will use the unixODBC library.
53Group: Development/Libraries
54Requires: %{name} = %{version}-%{release}
55
56%description devel
57Install unixODBC if you'd like to access databases through ODBC drivers.
58
59If you want to develop programs that will access data through ODBC,
60you'll also need to install the unixODBC-devel (this) package.
61
62%package kde
63Summary: KDE DriverManager components for ODBC
64Group: System Environment/Libraries
65Requires: %{name} = %{version}-%{release}
66
67%description kde
68Components for the ODBCConfig and DataManager (KDE) Components of unixODBC.
69
70%prep
71%setup -q
72%patch1 -p1
73%patch2 -p1
74%patch3 -p1
75%patch6 -p1
76%patch7 -p1
77%patch8 -p1
78%patch9 -p1
79%patch10 -p1
80%patch11 -p1
81%patch12 -p1
82
83chmod 0644 Drivers/MiniSQL/*.c
84chmod 0644 Drivers/nn/*.c
85chmod 0644 Drivers/template/*.c
86chmod 0644 doc/ProgrammerManual/Tutorial/*.html
87chmod 0644 doc/lst/*
88chmod 0644 include/odbcinst.h
89
90# Blow away the embedded libtool and replace with build system's libtool.
91# (We will use the installed libtool anyway, but this makes sure they match.)
92rm -rf config.guess config.sub install-sh ltmain.sh libltdl
93# this hack is so we can build with either libtool 2.2 or 1.5
94libtoolize --install || libtoolize
95
96%build
97# pick up qt path
98export PATH="%{_qt4_bindir}:$PATH"
99# clean up old moc files
100(cd odbcinstQ4 && rm -f mC*.cpp)
101
102aclocal
103automake --add-missing
104autoconf
105
106# unixODBC 2.2.14 is not aliasing-safe
107CFLAGS="%{optflags} -fno-strict-aliasing"
108CXXFLAGS="$CFLAGS"
109export CFLAGS CXXFLAGS
110
111%configure --with-gnu-ld=yes --enable-threads=yes --enable-gui=yes --enable-drivers --enable-ltdllib --with-qt-programs="%{_qt4_bindir}" --with-qt-libraries="%{_qt4_libdir}" --with-qt-includes="%{_qt4_headerdir}"
112make all
113
114%install
115# pick up qt path
116export PATH="%{_qt4_bindir}:$PATH"
117
118rm -rf $RPM_BUILD_ROOT
119mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications
120mkdir -p $RPM_BUILD_ROOT%{_datadir}/pixmaps
121
122make DESTDIR=$RPM_BUILD_ROOT install
123cp %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}
124
125# install *.desktop files
126desktop-file-install --dir=$RPM_BUILD_ROOT%{_datadir}/applications %{SOURCE2}
127
128# package doesn't supply an icon for ODBCConfig, so use the one for DataManager
129cp DataManager/LinuxODBC.xpm $RPM_BUILD_ROOT%{_datadir}/pixmaps
130
131# multilib header hacks
132# we only apply this to known Red Hat multilib arches, per bug #181335
133case `uname -i` in
134  i386 | x86_64 | ppc | ppc64 | s390 | s390x | sparc | sparc64 )
135    mv $RPM_BUILD_ROOT%{_includedir}/unixodbc_conf.h $RPM_BUILD_ROOT%{_includedir}/unixodbc_conf_`uname -i`.h
136    rm -f unixodbc_conf.h
137    sed s/CONFFILE/unixodbc_conf/ %{SOURCE4} >unixodbc_conf.h
138    install -m 644 unixodbc_conf.h $RPM_BUILD_ROOT%{_includedir}
139    ;;
140  *)
141    ;;
142esac
143
144# remove obsolete Postgres drivers from the package (but not the setup code)
145rm -f $RPM_BUILD_ROOT%{_libdir}/libodbcpsql.so*
146
147# copy text driver documentation into main doc directory
148# currently disabled because upstream no longer includes text driver
149# mkdir -p doc/Drivers/txt
150# cp -pr Drivers/txt/doc/* doc/Drivers/txt
151
152# don't want to install doc Makefiles as docs
153#find doc -name 'Makefile*' | xargs rm
154
155# we do not want to ship static libraries
156rm -f $RPM_BUILD_ROOT%{_libdir}/*.a
157
158# remove unpackaged files from the buildroot
159rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
160rm -f $RPM_BUILD_ROOT%{_libdir}/libltdl.*
161rm -rf $RPM_BUILD_ROOT%{_datadir}/libtool
162
163%clean
164rm -rf $RPM_BUILD_ROOT
165
166%post -p /sbin/ldconfig
167
168%postun -p /sbin/ldconfig
169
170%post kde -p /sbin/ldconfig
171
172%postun kde -p /sbin/ldconfig
173
174%files
175%defattr(-,root,root)
176%doc README COPYING AUTHORS ChangeLog NEWS INSTALL doc
177%config(noreplace) %{_sysconfdir}/odbc*
178%{_bindir}/dltest
179%{_bindir}/isql
180%{_bindir}/iusql
181%{_bindir}/odbcinst
182%{_libdir}/libboundparam.so.*
183%{_libdir}/libesoobS.so.*
184%{_libdir}/libgtrtst.so.*
185%{_libdir}/libmimerS.so.*
186%{_libdir}/libnn.so.*
187%{_libdir}/libodbc.so.*
188%{_libdir}/libodbccr.so.*
189%{_libdir}/libodbcdrvcfg1S.so.*
190%{_libdir}/libodbcdrvcfg2S.so.*
191#%{_libdir}/libodbcextras.so.*
192%{_libdir}/libodbcinst.so.*
193%{_libdir}/libodbcminiS.so.*
194%{_libdir}/libodbcmyS.so.*
195%{_libdir}/libodbcnnS.so.*
196#%{_libdir}/libodbcpsql.so.*
197%{_libdir}/libodbcpsqlS.so.*
198#%{_libdir}/libodbctxt.so.*
199%{_libdir}/libodbctxtS.so.*
200%{_libdir}/liboplodbcS.so.*
201%{_libdir}/liboraodbcS.so.*
202%{_libdir}/libsapdbS.so.*
203%{_libdir}/libtdsS.so.*
204%{_libdir}/libtemplate.so.*
205
206%files devel
207%defattr(-,root,root)
208%{_bindir}/odbc_config
209%{_includedir}/*
210%{_libdir}/libboundparam.so
211%{_libdir}/libesoobS.so
212%{_libdir}/libgtrtst.so
213%{_libdir}/libmimerS.so
214%{_libdir}/libnn.so
215%{_libdir}/libodbc.so
216%{_libdir}/libodbccr.so
217%{_libdir}/libodbcdrvcfg1S.so
218%{_libdir}/libodbcdrvcfg2S.so
219#%{_libdir}/libodbcextras.so
220%{_libdir}/libodbcinst.so
221%{_libdir}/libodbcminiS.so
222%{_libdir}/libodbcmyS.so
223%{_libdir}/libodbcnnS.so
224#%{_libdir}/libodbcpsql.so
225%{_libdir}/libodbcpsqlS.so
226#%{_libdir}/libodbctxt.so
227%{_libdir}/libodbctxtS.so
228%{_libdir}/liboplodbcS.so
229%{_libdir}/liboraodbcS.so
230%{_libdir}/libsapdbS.so
231%{_libdir}/libtdsS.so
232%{_libdir}/libtemplate.so
233#{_libdir}/*.a
234#{_libdir}/*.la
235
236%files kde
237%defattr(-,root,root)
238%{_bindir}/ODBCConfig
239%{_datadir}/applications/ODBCConfig.desktop
240%{_datadir}/pixmaps/LinuxODBC.xpm
241%{_libdir}/libodbcinstQ*so
242%{_libdir}/libodbcinstQ*so.*
243
244%changelog
245* Tue Apr 12 2011 IWAI, Masaharu <iwai@alib.jp> 2.2.14-2
246- add --with-qt-includes option for configure
247
248* Sat Apr 09 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.2.14-1
249- updated to 2.2.14
250
251* Sat Sep 20 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.2.12-1
252- applied new versioning policy
253- removed *.la files from devel package
254
255* Sun Sep 02 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.2.12-0vl1
256- updated to 2.2.12
257- rebuilt with new toolchain
258
259* Thu Sep 07 2006 NAKAMURA Kenta <kenta@vinelinux.org> 2.2.11-0vl3
260- use installed libltdl
261- added unixODBC-2.2.11-symbols.patch and nortldglobal.patch
262
263* Sat Apr 29 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.2.11-0vl2
264- rebuilt with readline 5.1
265
266* Wed Aug 24 2005 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.2.11-0vl1
267- updated to 2.2.11
268- not libtoolize
269
270* Sat Sep 27 2003 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 2.2.5-0vl2
271- added Patch100 to fix typo in doc/Makefile.am from failure on compiling
272
273* Fri Jun  6 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.2.5-0vl1
274- source upgrade
275- remove patch (no need)
276- run libtoolize etc for VineSeed
277
278* Wed Feb 12 2003 Tomoya TAKA <taka@vinelinux.org> 2.2.4-0vl2
279- enable -kde subpackage on alpha, but still disable for Vine2.5/2.6
280
281* Sun Feb  9 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.2.4-0vl1
282- source upgrade
283- change spec to build both VineSeed and Vine2.5/2.6
284- add patch from rawhide 2.2.3-6
285
286* Sun Oct 13 2002 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.2.3-0vl2
287- Requires: libjpeg (not libjpeg-6b)
288
289* Sun Oct  6 2002 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.2.3-0vl1
290- source upgrade
291- add BuildPrereq: autoconf253 automake15
292- add PreReq: ldconfig
293- fix %files section and clean up spec
294- for unixODBC-kde package
295  - add Requires: unixODBC = %{version}
296  - add Requires: XFree86-libs qt freetype2 libjpeg-6b libmng libpng zlib
297  - delete .desktop files
298
299* Thu Apr  4 2002 AKIYAMA Kazuhito <akiyama@karen.servepics.com> 2.2.0-0vl2
300- rebuild with KDE3
301
302* Sat Feb 23 2002 Satoshi MACHINO <machino@vinelinux.org> 2.2.0-0vl1
303- updated unixODBC-2.2.0
304- fixed LinuxODBC.xpm and smallLinuxODBC.xpm dir
305
306* Wed Jan 30 2002 Tomoya TAKA <taka@vinelinux.org> 2.0.7-3vl2
307- remove -kde package on alpha
308
309* Fri Jan  4 2002 Akira TAGOH <tagoh@gnome.gr.jp> 2.0.7-3vl1
310- Rebuild for Vine.
311
312* Sun Jun 24 2001 Than Ngo <than@redhat.com>
313- rebuild against qt-2.3.1, kde-2.1.x
314
315* Fri Jun 15 2001 Trond Eivind Glomsrød <teg@redhat.com>
316- Better default odbcinst.ini
317- Minor cleanups
318
319* Wed Jun  6 2001 Trond Eivind Glomsrød <teg@redhat.com>
320- 2.0.7
321
322* Wed Apr 25 2001 Trond Eivind Glomsrød <teg@redhat.com>
323- Fix for isql segfault on EOF/ctrl-d exit
324
325* Fri Apr 20 2001 Trond Eivind Glomsrød <teg@redhat.com>
326- 2.0.6
327- add patch for 64 bit archs (dword shouldn't be "long int")
328
329* Wed Feb 28 2001 Trond Eivind Glomsrød <teg@redhat.com>
330- rebuild
331
332* Tue Nov 28 2000 Trond Eivind Glomsrød <teg@redhat.com>
333- 1.8.13
334
335* Tue Oct 10 2000 Trond Eivind Glomsrød <teg@redhat.com>
336- enable GUI now that we have KDE compiled with the standard
337  compiler
338- move the applnk entries to the KDE package
339
340* Thu Aug 24 2000 Nalin Dahyabhai <nalin@redhat.com>
341- add the missing shared libs to the non-devel package
342
343* Wed Aug 23 2000 Preston Brown <pbrown@redhat.com>
344- 1.8.12 fixes problems with the postgresql driver
345
346* Mon Jul 31 2000 Trond Eivind Glomsrød <teg@redhat.com>
347- disable KDE subpackage to avoid the mess that is C++ binary
348  compatibility
349
350* Wed Jul 12 2000 Prospector <bugzilla@redhat.com>
351- automatic rebuild
352
353* Fri Jun 30 2000 Florian La Roche <laroche@redhat.com>
354- improved QTDIR detection
355
356* Thu Jun 28 2000 Trond Eivind Glomsrød <teg@redhat.com>
357- 1.8.10
358- use %%{_tmppath}
359- update URL
360- including two missing libraries
361
362* Tue Jun 13 2000 Preston Brown <pbrown@redhat.com>
363- 1.8.9
364
365* Fri Jun 09 2000 Preston Brown <pbrown@redhat.com>
366- adopted for Winston, changed to Red Hat packaging standards
367
368* Tue Apr 18 2000 Murray Todd Williams <murray@codingapes.com>
369- added a unixODBC-devel RPM to the group, added KDE links and icons to system
370- all of which came from recommendations from Fredrick Meunier
371- <Fredrick.Meunier@computershare.com.au>
372
373* Mon Apr 17 2000 Murray Todd Williams <murray@codingapes.com>
374- unixODBC-1.8.7
375- moved install to $RPM_BUILD_ROOT so it didn't overrun existing files.
376
377
Note: See TracBrowser for help on using the repository browser.