/[packages]/cauldron/wine/pristine/SPECS/wine.spec
ViewVC logotype

Annotation of /cauldron/wine/pristine/SPECS/wine.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 277554 - (hide annotations) (download)
Wed Aug 1 16:42:15 2012 UTC (11 years, 7 months ago) by anssi
Original Path: cauldron/wine/current/SPECS/wine.spec
File size: 15594 byte(s)
add suggests for wine-mono
1 ahmad 36061 %ifarch x86_64
2     %define wine wine64
3     %define mark64 ()(64bit)
4     %else
5     %define wine wine
6     %define mark64 %{nil}
7     %endif
8     %define lib_name_orig lib%{name}
9     %define lib_major 1
10     %define lib_name %mklibname %{name} %{lib_major}
11     %define lib_name_devel %{mklibname -d wine}
12    
13     # On 32-bit we have
14     # wine32 - those 32-bit binaries that are also used on 64-bit for 32-bit support
15     # wine - all other files (requires 'wine32')
16     # On 64-bit we have
17     # wine64 - all 64-bit files (suggests 'wine32')
18     # - Anssi 07/2010
19    
20 anssi 277554 # When altering these, make sure corresponding wine-gecko/wine-mono is
21     # submitted, or notify their maintainer about the new version:
22 dams 277515 %define gecko_version 1.7
23 anssi 277554 %define mono_version 0.0.4
24 anssi 188253
25 ahmad 36061 Name: wine
26 dams 277515 Version: 1.5.10
27 fwang 221865 %define pre 0
28 zezinho 177101 %define rel 1
29 ahmad 36061 %if %pre
30     Release: %mkrel 0.%pre.%rel
31     %define o_ver %version-%pre
32     %else
33     Release: %mkrel %rel
34     %define o_ver %version
35     %endif
36     Epoch: 1
37     Summary: WINE Is Not An Emulator - runs MS Windows programs
38     License: LGPLv2+
39     Group: Emulators
40     URL: http://www.winehq.com/
41 ahmad 103264 Source0: http://prdownloads.sourceforge.net/wine/%{name}-%{o_ver}.tar.bz2
42     Source1: http://prdownloads.sourceforge.net/wine/%{name}-%{o_ver}.tar.bz2.sign
43 ahmad 36061
44     # RH stuff
45 dams 277515 Source2: %{name}.init
46     Patch0: %{name}-1.0-rc3-fix-conflicts-with-openssl.patch
47     Patch1: %{name}-1.1.7-chinese-font-substitutes.patch
48 ahmad 36061 # (Anssi 05/2008) Adds:
49     # a: => /media/floppy (/mnt/floppy on 2007.1 and older)
50     # d: => $HOME (at config_dir creation time, not refreshed if $HOME changes;
51     # note that Wine also provides $HOME in My Documents)
52     # com4 => /dev/ttyUSB0 (replaces /dev/ttyS3)
53 dams 277515 Patch108: %{name}-mgaconf.patch
54 ahmad 36061
55     # (anssi) Wine needs GCC 4.4+ on x86_64 for MS ABI support. Note also that
56 anssi 96590 # 64-bit wine cannot run 32-bit programs without wine32.
57 ahmad 36061 %ifarch x86_64
58     BuildRequires: gcc >= 4.4
59     %endif
60 ahmad 101529 BuildRequires: bison flex
61 ahmad 71420 BuildRequires: gpm-devel
62     BuildRequires: perl-devel
63     BuildRequires: ncurses-devel
64     BuildRequires: cups-devel
65     BuildRequires: sane-devel
66     BuildRequires: lcms-devel
67     BuildRequires: autoconf
68     BuildRequires: docbook-utils docbook-dtd-sgml sgml-tools
69     BuildRequires: pulseaudio-devel
70 ahmad 36061 BuildRequires: libmpg123-devel
71     BuildRequires: openal-devel
72 ahmad 71420 BuildRequires: libalsa-devel
73 ahmad 36061 BuildRequires: gstreamer0.10-devel libgstreamer0.10-plugins-base-devel
74 ahmad 71420 BuildRequires: isdn4k-utils-devel
75     BuildRequires: glibc-static-devel
76     BuildRequires: chrpath
77     BuildRequires: ungif-devel xpm-devel
78     BuildRequires: tiff-devel
79     BuildRequires: librsvg
80     BuildRequires: imagemagick
81     BuildRequires: gphoto2-devel
82     BuildRequires: desktop-file-utils
83     BuildRequires: openldap-devel
84     BuildRequires: libxslt-devel
85     BuildRequires: dbus-devel
86 ahmad 110810 BuildRequires: valgrind-devel
87 ahmad 71420 BuildRequires: gsm-devel
88     BuildRequires: unixODBC-devel
89 ahmad 110810 BuildRequires: gnutls-devel
90 ahmad 36061 BuildRequires: prelink
91 ahmad 70893 BuildRequires: gettext-devel
92 ahmad 71420 BuildRequires: mesaglu-devel
93     BuildRequires: libv4l-devel
94     BuildRequires: libxcursor-devel libxcomposite-devel
95     BuildRequires: libxinerama-devel libxrandr-devel
96     BuildRequires: libx11-devel libxrender-devel
97     BuildRequires: libxext-devel libsm-devel
98     BuildRequires: fontforge fontconfig-devel freetype2-devel
99 ahmad 36061
100     %define desc Wine is a program which allows running Microsoft Windows programs \
101     (including DOS, Windows 3.x and Win32 executables) on Unix. It \
102     consists of a program loader which loads and executes a Microsoft \
103     Windows binary, and a library (called Winelib) that implements Windows \
104     API calls using their Unix or X11 equivalents. The library may also \
105     be used for porting Win32 code into native Unix executables.
106    
107     %ifarch x86_64
108     %package -n %{wine}
109     Summary: WINE Is Not An Emulator - runs MS Windows programs
110     Group: Emulators
111 dams 277515 Suggests: %{name}32 = %{epoch}:%{version}-%{release}
112     Suggests: %{name}64-gecko = %gecko_version
113 ahmad 36061 %else
114     # on 32-bit we always want wine32 package
115 dams 277515 Requires: %{name}32 = %{epoch}:%{version}-%{release}
116 ahmad 36061 %endif
117    
118     Provides: %{wine}-utils = %{epoch}:%{version}-%{release} %{wine}-full = %{epoch}:%{version}-%{release}
119     Provides: %{lib_name}-capi = %{epoch}:%{version}-%{release} %{lib_name}-twain = %{epoch}:%{version}-%{release}
120     Provides: %{lib_name} = %{epoch}:%{version}-%{release}
121     Provides: wine-bin = %{epoch}:%{version}-%{release}
122     Obsoletes: %{wine}-utils %{wine}-full %{lib_name}-capi %{lib_name}-twain
123     Obsoletes: %{lib_name} <= %{epoch}:%{version}-%{release}
124     Requires: xmessage
125     Suggests: sane-frontends
126     # wine dlopen's these, so let's add the dependencies ourself
127     Requires: libfreetype.so.6%{mark64} libasound.so.2%{mark64}
128 ahmad 72084 # wine needs to dlopen libfontconfig to make CJK fonts show correctly in winecfg
129     Requires: libfontconfig.so.1%{mark64}
130 ahmad 72093 Requires: libncurses.so.5%{mark64}
131 fwang 142563 Requires: libXrender.so.1%{mark64} libpng15.so.15%{mark64}
132 anssi 277554 # (Anssi) If not installed, wine pops up a dialog on first start proposing to
133     # download pre-built binaries (unlike wine-gecko, same wine-mono works with
134     # both wine and wine64):
135     Suggests: wine-mono = %mono_version
136 ahmad 36061 Requires(post): desktop-file-utils
137     Requires(postun): desktop-file-utils
138     Requires(post): desktop-common-data
139     Requires(postun): desktop-common-data
140     Requires(preun): rpm-helper
141     Requires(post): rpm-helper
142     %ifarch %{ix86}
143 dams 277515 Conflicts: %{name}64
144 ahmad 36061 %else
145 dams 277515 Conflicts: %{name}
146 ahmad 36061 %endif
147    
148     %description
149     %desc
150    
151     %ifarch x86_64
152     %description -n %{wine}
153     %desc
154    
155     This package contains the Win64 version of Wine. You need the wine32
156     package from the 32-bit repository to be able to run 32-bit applications.
157     %endif
158    
159     %ifarch %ix86
160     %package -n wine32
161     Summary: 32-bit support for Wine
162     Group: Emulators
163     # This is not an EVR-specific requirement, as otherwise on x86_64 urpmi could
164     # resolve the dependency to wine64 even on upgrades, and therefore replace
165     # wine+wine32 installation with a wine32+wine64 installation. - Anssi
166 dams 277515 Requires: %{name}-bin
167     Conflicts: %{name} < 1:1.2-0.rc7.1
168     Conflicts: %{name}64 < 1:1.2-0.rc7.1
169 ahmad 36061 # (Anssi) If wine-gecko is not installed, wine pops up a dialog on first
170     # start proposing to download wine-gecko from sourceforge, while recommending
171     # to use distribution packages instead. Therefore suggest wine-gecko here:
172 dams 277515 Suggests: %{name}-gecko = %gecko_version
173 ahmad 36061
174     %description -n wine32
175     Wine is a program which allows running Microsoft Windows programs
176     (including DOS, Windows 3.x and Win32 executables) on Unix.
177    
178     This package contains the files needed to support 32-bit Windows
179     programs.
180     %endif
181    
182     %package -n %{wine}-devel
183     Summary: Static libraries and headers for %{name}
184     Group: Development/C
185     Requires: %{wine} = %{epoch}:%{version}
186     Provides: %{lib_name_devel} = %{epoch}:%{version}-%{release}
187     Provides: %{lib_name_orig}-devel = %{epoch}:%{version}-%{release}
188     Obsoletes: %{lib_name_devel} <= %{epoch}:%{version}-%{release}
189     Obsoletes: %{mklibname -d wine 1} < %{epoch}:%{version}
190     %ifarch %{ix86}
191 dams 277515 Conflicts: %{name}64-devel
192 ahmad 36061 %else
193 dams 277515 Conflicts: %{name}-devel
194 ahmad 36061 %endif
195    
196     %description -n %{wine}-devel
197     Wine is a program which allows running Microsoft Windows programs
198     (including DOS, Windows 3.x and Win32 executables) on Unix.
199    
200     %{wine}-devel contains the libraries and header files needed to
201     develop programs which make use of wine.
202    
203     %prep
204     %setup -q -n %name-%o_ver
205     %patch1 -p0 -b .chinese
206     %patch108 -p1 -b .conf
207    
208 anssi 188253 GECKO_VERSION=$(sed -rn 's,^#define\s+GECKO_VERSION\s+"([^"]*)".*$,\1,p' dlls/appwiz.cpl/addons.c)
209 dams 277515 [ "$GECKO_VERSION" = "%gecko_version" ] || { echo %{name}-gecko version mismatch; exit 1; }
210 anssi 277554 MONO_VERSION=$(sed -rn 's,^#define\s+MONO_VERSION\s+"([^"]*)".*$,\1,p' dlls/appwiz.cpl/addons.c)
211     [ "$MONO_VERSION" = "%mono_version" ] || { echo wine-mono version mismatch; exit 1; }
212 anssi 188253
213 ahmad 36061 %build
214     %ifarch %ix86
215     # (Anssi 04/2008) bug #39604
216     # Some protection systems complain "debugger detected" with our
217     # -fomit-frame-pointer flag, so disable it.
218     export CFLAGS="%{optflags} -fno-omit-frame-pointer"
219     %endif
220    
221     # (Anssi 04/2008)
222     # If icotool is present, it is used to rebuild icon files. It is in contrib
223     # so we do not do that; this is here to ensure that installed icoutils does
224     # not change build behaviour.
225     export ICOTOOL=false
226    
227     autoreconf
228     %configure2_5x --with-x \
229     --with-pulse \
230     %ifarch x86_64
231     --enable-win64
232     %endif
233    
234     %make depend
235     %make
236    
237     %install
238     %makeinstall_std LDCONFIG=/bin/true
239    
240     # Danny: dirty:
241 dams 259841 #install -m755 tools/fnt2bdf -D %{buildroot}%{_bindir}/fnt2bdf
242 ahmad 36061
243     # Allow users to launch Windows programs by just clicking on the .exe file...
244     install -m755 %{SOURCE2} -D %{buildroot}%{_initrddir}/%{name}
245    
246     mkdir -p %{buildroot}%{_sysconfdir}/xdg/menus/applications-merged
247 zezinho 156874 cat > %{buildroot}%{_sysconfdir}/xdg/menus/applications-merged/%{_real_vendor}-%{name}.menu <<EOF
248 ahmad 36061 <!DOCTYPE Menu PUBLIC "-//freedesktop//DTD Menu 1.0//EN"
249     "http://www.freedesktop.org/standards/menu-spec/menu-1.0.dtd">
250     <Menu>
251     <Name>Applications</Name>
252     <Menu>
253     <Name>Tools</Name>
254     <Menu>
255     <Name>Emulators</Name>
256     <Menu>
257     <Name>Wine</Name>
258 zezinho 156874 <Directory>%{_real_vendor}-%{name}.directory</Directory>
259 ahmad 36061 <Include>
260     <Category>X-MandrivaLinux-MoreApplications-Emulators-Wine</Category>
261     </Include>
262     </Menu>
263     </Menu>
264     </Menu>
265     </Menu>
266     EOF
267    
268     mkdir -p %{buildroot}%{_datadir}/desktop-directories
269 zezinho 156874 cat > %{buildroot}%{_datadir}/desktop-directories/%{_real_vendor}-%{name}.directory <<EOF
270 ahmad 36061 [Desktop Entry]
271     Name=Wine
272     Icon=%{name}
273     Type=Directory
274     EOF
275    
276     mkdir -p %{buildroot}%{_datadir}/applications/
277     for i in winecfg:Configurator \
278     notepad:Notepad \
279     winefile:File\ Manager \
280     regedit:Registry\ Editor \
281     winemine:Minesweeper \
282     wineboot:Reboot \
283     "wineconsole cmd":Command\ Line \
284     "wine uninstaller:Wine Software Uninstaller";
285 zezinho 156874 do cat > %{buildroot}%{_datadir}/applications/%{_real_vendor}-%{name}-`echo $i|cut -d: -f1`.desktop << EOF
286 ahmad 36061 [Desktop Entry]
287     Name=`echo $i|cut -d: -f2`
288     Comment=`echo $i|cut -d: -f2`
289     Exec=`echo $i|cut -d: -f1`
290     Icon=%{name}
291     Terminal=false
292     Type=Application
293     Categories=X-MandrivaLinux-MoreApplications-Emulators-Wine;
294     EOF
295     done
296    
297     # Categories=Emulator does nothing and is added as a workaround to kde #27700
298     desktop-file-install --vendor="" \
299     --add-mime-type=application/x-zip-compressed \
300     --remove-mime-type=application/x-zip-compressed \
301     --add-category=Emulator \
302 dams 277515 --dir %{buildroot}%{_datadir}/applications %{buildroot}%{_datadir}/applications/%{name}.desktop
303 ahmad 36061
304     %ifarch x86_64
305     # fix the binary name
306 dams 277515 sed -i 's,Exec=wine ,Exec=wine64 ,' %{buildroot}%{_datadir}/applications/%{name}.desktop
307 ahmad 36061 %endif
308    
309     install -d %{buildroot}{%{_liconsdir},%{_iconsdir},%{_miconsdir}}
310    
311     # winecfg icon
312     convert dlls/user32/resources/oic_winlogo.ico[8] %{buildroot}%{_miconsdir}/%{name}.png
313     convert dlls/user32/resources/oic_winlogo.ico[7] %{buildroot}%{_iconsdir}/%{name}.png
314     convert dlls/user32/resources/oic_winlogo.ico[6] %{buildroot}%{_liconsdir}/%{name}.png
315    
316     # notepad icon
317     convert programs/notepad/notepad.ico[2] %{buildroot}%{_miconsdir}/notepad.png
318     convert programs/notepad/notepad.ico[7] %{buildroot}%{_iconsdir}/notepad.png
319     convert programs/notepad/notepad.ico[8] %{buildroot}%{_liconsdir}/notepad.png
320     # winefile icon
321     convert programs/winefile/winefile.ico[2] %{buildroot}%{_miconsdir}/winefile.png
322     convert programs/winefile/winefile.ico[8] %{buildroot}%{_iconsdir}/winefile.png
323     convert programs/winefile/winefile.ico[7] %{buildroot}%{_liconsdir}/winefile.png
324     # regedit icon
325     convert programs/regedit/regedit.ico[2] %{buildroot}%{_miconsdir}/regedit.png
326     convert programs/regedit/regedit.ico[8] %{buildroot}%{_iconsdir}/regedit.png
327     convert programs/regedit/regedit.ico[7] %{buildroot}%{_liconsdir}/regedit.png
328     # winemine icon
329     convert programs/winemine/winemine.ico[2] %{buildroot}%{_miconsdir}/winemine.png
330     convert programs/winemine/winemine.ico[8] %{buildroot}%{_iconsdir}/winemine.png
331     convert programs/winemine/winemine.ico[7] %{buildroot}%{_liconsdir}/winemine.png
332    
333     # wine uninstaller icon:
334     convert programs/msiexec/msiexec.ico[2] %{buildroot}%{_miconsdir}/msiexec.png
335     convert programs/msiexec/msiexec.ico[8] %{buildroot}%{_iconsdir}/msiexec.png
336     convert programs/msiexec/msiexec.ico[7] %{buildroot}%{_liconsdir}/msiexec.png
337    
338     # change the icons in the respective .desktop files, in order:
339 zezinho 156874 sed -i 's,Icon=%{name},Icon=notepad,' %{buildroot}%{_datadir}/applications/%{_real_vendor}-wine-notepad.desktop
340     sed -i 's,Icon=%{name},Icon=winefile,' %{buildroot}%{_datadir}/applications/%{_real_vendor}-wine-winefile.desktop
341     sed -i 's,Icon=%{name},Icon=regedit,' %{buildroot}%{_datadir}/applications/%{_real_vendor}-wine-regedit.desktop
342     sed -i 's,Icon=%{name},Icon=winemine,' %{buildroot}%{_datadir}/applications/%{_real_vendor}-wine-winemine.desktop
343     sed -i 's,Icon=%{name},Icon=msiexec,' "%{buildroot}%{_datadir}/applications/%{_real_vendor}-wine-wine uninstaller.desktop"
344 ahmad 36061
345     %ifarch x86_64
346     chrpath -d %{buildroot}%{_bindir}/{wine64,wineserver,wmc,wrc} %{buildroot}%{_libdir}/%{name}/*.so
347     %else
348     chrpath -d %{buildroot}%{_bindir}/{wine,wineserver,wmc,wrc} %{buildroot}%{_libdir}/%{name}/*.so
349     %endif
350    
351     %ifarch x86_64
352     cat > README.install.urpmi <<EOF
353     This is the Win64 version of Wine. This version can only be used to run
354     64-bit Windows applications as is. For running 32-bit Windows applications,
355     you need to also install the 'wine32' package from the 32-bit repository.
356     EOF
357     %endif
358    
359     %preun -n %{wine}
360     %_preun_service %{name}
361    
362     %post -n %{wine}
363     %_post_service %{name}
364    
365     %files -n %{wine}
366     %doc ANNOUNCE AUTHORS README
367     %ifarch x86_64
368     %doc README.install.urpmi
369 dams 277515 %{_bindir}/%{name}64
370     %{_bindir}/%{name}64-preloader
371 ahmad 36061 %endif
372     %{_initrddir}/%{name}
373     %{_bindir}/winecfg
374     %{_bindir}/wineconsole*
375     %{_bindir}/wineserver
376     %{_bindir}/wineboot
377     %{_bindir}/function_grep.pl
378     #%{_bindir}/wineprefixcreate
379     %{_bindir}/msiexec
380     %{_bindir}/notepad
381     %{_bindir}/regedit
382     %{_bindir}/winemine
383     %{_bindir}/winepath
384     %{_bindir}/regsvr32
385     %{_bindir}/winefile
386     %{_mandir}/man1/wine.1*
387     %lang(de) %{_mandir}/de.UTF-8/man1/wine.1*
388     %lang(de) %{_mandir}/de.UTF-8/man1/winemaker.1*
389     %lang(de) %{_mandir}/de.UTF-8/man1/wineserver.1*
390     %lang(fr) %{_mandir}/fr.UTF-8/man1/*
391 ahmad 103264 %lang(pl) %{_mandir}/pl.UTF-8/man1/wine.1*
392 ahmad 36061 %{_mandir}/man1/wineserver.1*
393     %{_mandir}/man1/msiexec.1*
394     %{_mandir}/man1/notepad.1*
395     %{_mandir}/man1/regedit.1*
396     %{_mandir}/man1/regsvr32.1*
397     %{_mandir}/man1/wineboot.1*
398     %{_mandir}/man1/winecfg.1*
399     %{_mandir}/man1/wineconsole.1*
400     %{_mandir}/man1/winecpp.1*
401     %{_mandir}/man1/winefile.1*
402     %{_mandir}/man1/winemine.1*
403     %{_mandir}/man1/winepath.1*
404     %dir %{_datadir}/%{name}
405     %{_datadir}/%{name}/generic.ppd
406     %{_datadir}/%{name}/%{name}.inf
407     %{_datadir}/%{name}/l_intl.nls
408     %{_datadir}/applications/*.desktop
409 zezinho 156874 %{_sysconfdir}/xdg/menus/applications-merged/%{_real_vendor}-%{name}.menu
410     %{_datadir}/desktop-directories/%{_real_vendor}-%{name}.directory
411 ahmad 36061 %dir %{_datadir}/wine/fonts
412     %{_datadir}/wine/fonts/*
413     %{_miconsdir}/*.png
414     %{_iconsdir}/*.png
415     %{_liconsdir}/*.png
416    
417     %ifarch %{ix86}
418     %files -n wine32
419     %{_bindir}/wine
420     %{_bindir}/wine-preloader
421     %endif
422    
423     %{_libdir}/libwine*.so.%{lib_major}*
424     %dir %{_libdir}/%{name}
425     %{_libdir}/%{name}/*.cpl.so
426     %{_libdir}/%{name}/*.drv.so
427     %{_libdir}/%{name}/*.dll.so
428     %{_libdir}/%{name}/*.exe.so
429     %{_libdir}/%{name}/*.acm.so
430     %{_libdir}/%{name}/*.ocx.so
431     %ifarch %{ix86}
432     %{_libdir}/%{name}/*.vxd.so
433     %{_libdir}/%{name}/*16.so
434     %endif
435     %{_libdir}/%{name}/*.tlb.so
436     %{_libdir}/%{name}/*.ds.so
437     %{_libdir}/%{name}/*.sys.so
438     %{_libdir}/%{name}/fakedlls
439    
440     %files -n %{wine}-devel
441     %{_libdir}/%{name}/*.a
442     %{_libdir}/libwine*.so
443     %{_libdir}/%{name}/*.def
444     %{_includedir}/*
445 dams 259841 #%{_bindir}/fnt2bdf
446 ahmad 36061 %{_bindir}/wmc
447     %{_bindir}/wrc
448     %{_bindir}/winebuild
449     %{_bindir}/winegcc
450     %{_bindir}/wineg++
451     %{_bindir}/winecpp
452     %{_bindir}/widl
453     %{_bindir}/winedbg
454     %{_bindir}/winemaker
455     %{_bindir}/winedump
456     %{_mandir}/man1/wmc.1*
457     %{_mandir}/man1/wrc.1*
458     %{_mandir}/man1/winebuild.1*
459     %{_mandir}/man1/winemaker.1*
460     %{_mandir}/man1/winedump.1*
461     %{_mandir}/man1/widl.1*
462     %{_mandir}/man1/winedbg.1*
463     %{_mandir}/man1/wineg++.1*
464     %{_mandir}/man1/winegcc.1*

  ViewVC Help
Powered by ViewVC 1.1.30