/[packages]/updates/5/mysql-workbench/current/SPECS/mysql-workbench.spec
ViewVC logotype

Contents of /updates/5/mysql-workbench/current/SPECS/mysql-workbench.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 100004 - (show annotations) (download)
Fri May 20 23:22:10 2011 UTC (12 years, 11 months ago) by dmorgan
Original Path: cauldron/mysql-workbench/current/SPECS/mysql-workbench.spec
File size: 6560 byte(s)
Obsolete old mysql-gui-tools
1 %define build_java 1
2 %define build_autotools 1
3 %define tartype gpl
4 %define Werror_cflags %nil
5 %define _disable_ld_no_undefined 1
6 # commandline overrides:
7 # rpm -ba|--rebuild --with 'xxx'
8 %{?_with_java: %{expand: %%global build_java 1}}
9 %{?_without_java: %{expand: %%global build_java 0}}
10 %{?_with_autotools: %{expand: %%global build_autotools 1}}
11 %{?_without_autotools: %{expand: %%global build_autotools 0}}
12
13 Summary: Extensible modeling tool for MySQL 5.x
14 Name: mysql-workbench
15 Group: Databases
16 Version: 5.2.33b
17 Release: %mkrel 1
18 License: GPL
19 URL: http://wb.mysql.com
20 # Upstream has a mirror redirector for downloads, so the URL is hard to
21 # represent statically. You can get the tarball by following a link from
22 # http://dev.mysql.com/downloads/workbench/
23 Source: http://gd.tuwien.ac.at/db/mysql/Downloads/MySQLGUITools/%{name}-%{tartype}-%{version}-src.tar.gz
24 # don't build extension, use system one
25 # !!! This patch use versioned soname (libmysqlcppconn.so.5) !!!
26 Patch1: %{name}-5.2.33b-cppconn.patch
27 Patch2: %{name}-5.2.33b-ctemplate.patch
28 Patch3: %{name}-5.2.33b-tinyxml.patch
29 Patch4: %{name}-5.2.33b-mysql55.patch
30 Patch6: mysql-workbench-gpl-5.2.31-mga-fix-ifconfig.patch
31 # only needed when we update to gcc-4.6
32 #Patch5: %{name}-5.2.30-gcc.patch
33 Obsoletes: mysql-workbench-oss < 5.2.30
34 Provides: mysql-workbench-oss
35 Obsoletes: mysql-gui-tools < 5.1
36 Provides: mysql-gui-tools
37 BuildRequires: autoconf2.5
38 BuildRequires: boost-devel >= 1.35.0
39 BuildRequires: cairo-devel
40 BuildRequires: cairomm-devel
41 BuildRequires: ctemplate-devel >= 0.91
42 BuildRequires: expat-devel
43 BuildRequires: fdupes
44 BuildRequires: file
45 BuildRequires: freetype2-devel >= 2.1.10
46 BuildRequires: gettext
47 BuildRequires: gettext-devel
48 BuildRequires: glib2-devel
49 BuildRequires: glibmm2.4-devel
50 BuildRequires: glitz-devel
51 BuildRequires: gtk2-devel
52 BuildRequires: gtkhtml-3.14-devel
53 BuildRequires: gtkmm2.4-devel >= 2.6
54 BuildRequires: imagemagick
55 BuildRequires: libext2fs-devel
56 BuildRequires: libfcgi-devel
57 BuildRequires: libfontconfig-devel
58 BuildRequires: libglade2.0-devel >= 2.5
59 BuildRequires: libgnome2-devel
60 BuildRequires: libgnomeprint-devel >= 2.2.0
61 BuildRequires: libpng-devel
62 BuildRequires: libsigc++2.0-devel
63 BuildRequires: libslang-devel
64 BuildRequires: libtool
65 BuildRequires: libuuid-devel
66 BuildRequires: libx11-devel
67 BuildRequires: libxext-devel
68 BuildRequires: libxml2-devel
69 BuildRequires: libxrender-devel
70 BuildRequires: libzip-devel
71 BuildRequires: lua5.1-devel
72 BuildRequires: mesagl-devel
73 BuildRequires: mesaglu-devel
74 BuildRequires: mysql-connector-c++-devel
75 BuildRequires: mysql-devel >= 5.0
76 BuildRequires: ncurses-devel
77 BuildRequires: openssl-devel
78 BuildRequires: pcre-devel >= 5.0
79 BuildRequires: pixman-devel >= 0.11.2
80 BuildRequires: pkgconfig
81 BuildRequires: python-devel
82 BuildRequires: readline-devel
83 BuildRequires: scintilla-devel
84 BuildRequires: termcap-devel
85 BuildRequires: sqlite3-devel
86 BuildRequires: libgnome-keyring-devel
87 BuildRequires: tinyxml-devel
88 %if %{build_java}
89 BuildRequires: junit
90 BuildRequires: eclipse-ecj
91 BuildRequires: gcj-tools
92 BuildRequires: jpackage-utils
93 %endif
94 # requires mysql-client (for mysqldump and mysql cmdline client)
95 Requires: mysql-client
96 Requires: gnome-keyring
97 Requires: python-paramiko
98 Requires: python-pexpect
99
100 %description
101 MySQL Workbench is modeling tool that allows you to design and generate MySQL
102 databases graphically.
103
104 MySQL Workbench requires OpenGL and a 3D accelerated graphics card with at
105 least 16MB of memory.
106
107 %prep
108
109 %setup -q -n mysql-workbench-gpl-5.2.33-src
110 %patch1 -p0 -b .cppconn
111 %patch2 -p0 -b .ctemplate
112 %patch3 -p0 -b .tinyxml
113 %patch4 -p0 -b .mysql55
114 %patch6 -p0 -b .ifconfig
115
116 #%patch5 -p1 -b .gcc46
117
118 # lib64 fix
119 perl -pi -e "s|/lib/|/%{_lib}/|g" frontend/linux/workbench/program.cpp
120
121 # other small fixes
122 #touch po/POTFILES.in
123
124 # ctemplete is now ctemplate and not google anymore
125 for i in `grep -Rl google .`; do
126 sed -i 's/google/ctemplate/g' $i;
127 done
128
129 %build
130 #export CPPFLAGS="$CPPFLAGS `pkg-config --cflags scintilla`"
131
132 %if %{build_autotools}
133 NOCONFIGURE=yes ./autogen.sh
134 %endif
135 %define _disable_ld_no_undefined 1
136 #export CXXFLAGS="$RPM_OPT_FLAGS -fpermissive"
137 %configure2_5x --disable-static --disable-debug
138
139 # antibork
140 #find -type f -name Makefile | xargs perl -pi -e "s|-Wl,--as-needed||g"
141
142 # use the shared libs
143 #find -type f -name Makefile | xargs perl -pi -e "s|%{_libdir}/python%{pyver}/config/libpython%{pyver}.a|-lpython%{pyver}|g"
144
145 %make
146
147 %install
148 rm -rf %{buildroot}
149
150 %makeinstall_std
151
152 # construct a clean and correct wrapper
153 cat > %{buildroot}%{_bindir}/mysql-workbench << EOF
154 #!/bin/bash
155 export LD_LIBRARY_PATH="%{_libdir}/mysql-workbench:\$LD_LIBRARY_PATH"
156 export MWB_DATA_DIR="%{_datadir}/mysql-workbench"
157 export MWB_LIBRARY_DIR="%{_datadir}/mysql-workbench/libraries"
158 export MWB_MODULE_DIR="%{_libdir}/mysql-workbench/modules"
159 export MWB_PLUGIN_DIR="%{_libdir}/mysql-workbench/plugins"
160 export DBC_DRIVER_PATH="%{_libdir}/mysql-workbench"
161 %{_bindir}/mysql-workbench-bin \$*
162 EOF
163
164 # fix some menu entries and stuff...
165 install -d %{buildroot}%{_miconsdir}
166 install -d %{buildroot}%{_iconsdir}
167 install -d %{buildroot}%{_liconsdir}
168
169 install -d %{buildroot}%{_datadir}/applications
170 rm -f %{buildroot}%{_datadir}/applications/MySQLWorkbench.desktop
171 cat > %{buildroot}%{_datadir}/applications/mysql-workbench.desktop << EOF
172 [Desktop Entry]
173 Name=MySQL Workbench
174 Comment=MySQL Database Design Tool
175 Exec=%{_bindir}/mysql-workbench
176 Terminal=false
177 Type=Application
178 Icon=mysql-workbench
179 Categories=Database;Office;
180 EOF
181
182 # make some icons
183 convert %{buildroot}%{_datadir}/mysql-workbench/images/MySQLWorkbench-48.png -resize 16x16 %{buildroot}%{_miconsdir}/mysql-workbench.png
184 convert %{buildroot}%{_datadir}/mysql-workbench/images/MySQLWorkbench-48.png -resize 32x32 %{buildroot}%{_iconsdir}/mysql-workbench.png
185 convert %{buildroot}%{_datadir}/mysql-workbench/images/MySQLWorkbench-48.png -resize 48x48 %{buildroot}%{_liconsdir}/mysql-workbench.png
186
187 # cleanup
188 rm -f %{buildroot}%{_libdir}/mysql-workbench/*.*a
189 rm -f %{buildroot}%{_libdir}/mysql-workbench/lib*.so
190 rm -f %{buildroot}%{_libdir}/mysql-workbench/modules/*.*a
191 rm -f %{buildroot}%{_libdir}/mysql-workbench/plugins/*.*a
192
193 %clean
194 rm -rf %{buildroot}
195
196 %files
197 %defattr(-,root,root)
198 %doc COPYING ChangeLog README
199 %{_bindir}/*
200 %{_libdir}/mysql-workbench/lib*.so.*
201 %{_libdir}/mysql-workbench/modules
202 %{_libdir}/mysql-workbench/plugins
203 %{_datadir}/mysql-workbench
204 %{_datadir}/applications/mysql-workbench.desktop
205 %{_iconsdir}/mysql-workbench.png
206 %{_liconsdir}/mysql-workbench.png
207 %{_miconsdir}/mysql-workbench.png

  ViewVC Help
Powered by ViewVC 1.1.30