]> git.pld-linux.org Git - packages/wine.git/blobdiff - wine.spec
- cdrom-segv patch is obsolete
[packages/wine.git] / wine.spec
index c73ba6f6642bf2015e79af0ce0fa8040f4bb806b..1f4f8cb253ead0e929624bb601a88b489d8d4654 100644 (file)
--- a/wine.spec
+++ b/wine.spec
@@ -1,35 +1,69 @@
+#
+# Conditional build:
+%bcond_without arts     # without arts support
+%bcond_without cups     # without CUPS printing support
+%bcond_without sane     # without TWAIN scanning support (through SANE)
+%bcond_with    pdf_docs # build pdf docs (missing BR)
+%bcond_with    html_docs # build html docs (jade fault ?)
+#
+# maybe TODO: alsa,jack,nas BRs/checks (see dlls/winmm/wine*)
 Summary:       Program that lets you launch Win applications
 Summary(es):   Ejecuta programas Windows en Linux
 Summary(pl):   Program pozwalajĀ±cy uruchamiaƦ aplikacje Windows
 Summary(pt_BR):        Executa programas Windows no Linux
 Name:          wine
-Version:       20020411
+Version:       20031016
 Release:       1
 License:       GPL
 Group:         Applications/Emulators
-Source0:       ftp://metalab.unc.edu/pub/Linux/ALPHA/wine/development/Wine-%{version}.tar.gz
+Source0:       http://dl.sf.net/wine/Wine-%{version}.tar.gz
+# Source0-md5: 67eed2fb7a86d805ec8fc4bcf7a04254
 Source1:       %{name}.init
 Source2:       %{name}.reg
 Source3:       %{name}.systemreg
 Source4:       %{name}.userreg
 Patch0:                %{name}-fontcache.patch
+Patch1:                %{name}-destdir.patch
+Patch2:                %{name}-ncurses.patch
+Patch3:                %{name}-ac-ksh.patch
+Patch4:                %{name}-binutils.patch
+Patch5:                %{name}-makedep.patch
+Patch6:                %{name}-dga.patch
+Patch7:                %{name}-winebuild.patch
 URL:           http://www.winehq.com/
-Exclusivearch: %{ix86}
+BuildRequires: OpenGL-devel
 BuildRequires: XFree86-devel
-BuildRequires: flex
+%{?with_arts:BuildRequires:    arts-devel}
 BuildRequires: bison
-BuildRequires: ncurses-devel
-BuildRequires: OpenGL-devel
+BuildRequires: chpax >= 0.20020901-2
+%{?with_cups:BuildRequires:    cups-devel}
+BuildRequires: docbook-dtd31-sgml
+BuildRequires: docbook-utils
+BuildRequires: flex
 BuildRequires: freetype-devel >= 2.0.5
-BuildRequires: chpax
+BuildRequires: libjpeg-devel
+BuildRequires: ncurses-devel
+%if %{with html_docs} || %{with pdf_docs}
+BuildRequires: openjade
+%endif
+%if %{with pdf_docs}
+BuildRequires: tetex-metafont
+BuildRequires: tetex-fonts-pazo
+BuildRequires: tetex-fonts-stmaryrd
+BuildRequires: tetex-fonts-type1-urw
+%endif
+%{?with_sane:BuildRequires:    sane-backends-devel}
 Requires:      OpenGL
+Requires(post):        /sbin/ldconfig
+Requires(post,preun):/sbin/chkconfig
+# link to wine/ntdll.dll.so, without any SONAME
+Provides:      libntdll.dll.so
+ExclusiveArch: %{ix86}
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define                _noautoreqdep           libGL.so.1 libGLU.so.1
 %define                no_install_post_strip   1
 
-%define                _prefix                 /usr/X11R6
-%define                _mandir                 %{_prefix}/man
 %define                _winedir                %{_datadir}/%{name}
 
 %description
@@ -85,64 +119,82 @@ Group:             Applications
 Requires:      %{name} = %{version}
 
 %description programs
-Wine - programs
+Wine - programs.
 
 %description programs -l pl
-Wine - programy
+Wine - programy.
+
+%package doc-pdf
+Summary:       Wine documentation in PDF
+Summary(pl):   Dokumentacja Wine w formacie PDF
+Group:         Documentation
+
+%description doc-pdf
+Wine documentation in PDF format.
+
+%description doc-pdf -l pl
+Dokumentacja Wine w formacie PDF.
 
 %prep
 %setup -q
-%patch -p1
+%patch0 -p1
+%patch1 -p1
+%patch2 -p1
+%patch3 -p1
+%patch4 -p0
+%patch5 -p1
+%patch6 -p1
+%patch7 -p1
 
 # turn off compilation of some tools
-sed -e "s|winetest||;s|avitools||" programs/Makefile.in > .tmp
+#sed -e "s|winetest \\\|\\\|;s|avitools||" programs/Makefile.in > .tmp
+sed -e "s|avitools||" programs/Makefile.in > .tmp
 mv -f .tmp programs/Makefile.in
 
 %build
-#aclocal
-#autoconf
+%{__aclocal}
+%{__autoconf}
+CPPFLAGS="-I/usr/include/ncurses"; export CPPFLAGS
+CFLAGS="%{rpmcflags} $CPPFLAGS"
 %configure \
-%{!?debug:     --disable-debug} \
-%{!?debug:     --disable-trace} \
+       %{!?debug:--disable-debug} \
+       %{!?debug:--disable-trace} \
        --enable-curses \
        --enable-opengl \
        --with-x
-
 %{__make} depend
 %{__make}
 %{__make} -C programs
+%{__make} -C programs/regapi
+
+cd documentation
+%if %{with html_docs}
+db2html wine-user.sgml
+db2html wine-devel.sgml
+db2html wine-faq.sgml
+db2html winelib-user.sgml
+%endif
 
-(cd documentation
-./db2html-winehq wine-user.sgml
-./db2html-winehq wine-devel.sgml
-./db2html-winehq winelib-user.sgml)
+%if %{with pdf_docs}
+db2pdf         wine-user.sgml
+db2pdf  wine-devel.sgml
+db2pdf  wine-faq.sgml
+db2pdf  winelib-user.sgml
+%endif
+cd -
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_mandir}/man1
-
-%{__make} install \
-       prefix=$RPM_BUILD_ROOT%{_prefix} \
-       exec-prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
-        bindir=$RPM_BUILD_ROOT%{_bindir} \
-       sbindir=$RPM_BUILD_ROOT%{_sbindir} \
-       sysconfdir=$RPM_BUILD_ROOT%{_sysconfdir} \
-       datadir=$RPM_BUILD_ROOT%{_datadir} \
-       includedir=$RPM_BUILD_ROOT%{_includedir}/wine \
-       libdir=$RPM_BUILD_ROOT%{_libdir} \
-       libexecdir=$RPM_BUILD_ROOT%{_libexecdir} \
-       localstatedir=$RPM_BUILD_ROOT%{_localstatedir} \
-       sharedstatedir=$RPM_BUILD_ROOT%{_sharedstatedir} \
-       mandir=$RPM_BUILD_ROOT%{_mandir} \
-       infodir=$RPM_BUILD_ROOT%{_infodir} \
-       dlldir=$RPM_BUILD_ROOT%{_libdir}/wine
-
-%{__make} -C programs install \
-       prefix=$RPM_BUILD_ROOT%{_prefix} \
-        bindir=$RPM_BUILD_ROOT%{_bindir}
-
-(cd $RPM_BUILD_ROOT%{_bindir}
-find -name '*.so' | sed 's|^.|%attr(755,root,root) %{_bindir}|; s|.so$||') > programs.list
+install -d $RPM_BUILD_ROOT{%{_mandir}/man1,%{_aclocaldir}}
+
+%{__make} install DESTDIR=$RPM_BUILD_ROOT
+%{__make} -C programs install DESTDIR=$RPM_BUILD_ROOT
+
+install programs/winhelp/hlp2sgml      $RPM_BUILD_ROOT%{_bindir}
+install tools/fnt2bdf                  $RPM_BUILD_ROOT%{_bindir}
+
+install aclocal.m4 $RPM_BUILD_ROOT%{_aclocaldir}/wine.m4
+#mv -f $RPM_BUILD_ROOT{/usr/X11R6/share/aclocal,%{_aclocaldir}}/wine.m4
 
 install -d $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d \
         $RPM_BUILD_ROOT%{_winedir}/windows/{system,Desktop,Favorites,Fonts} \
@@ -151,7 +203,7 @@ install -d $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d \
        $RPM_BUILD_ROOT%{_winedir}/windows/{Profiles/Administrator,Recent} \
        $RPM_BUILD_ROOT%{_winedir}/{"Program Files/Common Files","My Documents"}
 
-install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/wine
+install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/wine
 install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}
 install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}
 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}
@@ -171,8 +223,6 @@ vcr=mciviscd.drv
 MPEGVideo=mciqtz.drv
 EOF
 
-gzip -9nf README DEVELOPERS-HINTS ChangeLog BUGS AUTHORS ANNOUNCE
-
 %if %{?debug:0}%{!?debug:1}
 echo "Strip executable binaries and shared object files."
 filelist=`find $RPM_BUILD_ROOT -type f ! -regex ".*ld-[0-9.]*so.*"`
@@ -188,7 +238,24 @@ if [ -n "$elfsharedlist" ]; then
 fi
 %endif
 
-/sbin/chpax -p $RPM_BUILD_ROOT%{_bindir}/wine
+/sbin/chstk -e $RPM_BUILD_ROOT%{_bindir}/wine
+
+programs="notepad progman regedit regsvr32 uninstaller wineconsole winefile winemine winepath winhelp wcmd"
+
+BZZZ=`pwd`
+rm -f files.so;                touch files.so
+rm -f files.programs;  touch files.programs
+cd $RPM_BUILD_ROOT%{_libdir}/wine
+for f in *.so; do
+       echo "%attr(755,root,root) %{_libdir}/wine/$f" >>$BZZZ/files.so
+done
+cd -
+for p in $programs; do
+       echo "%attr(755,root,root) %{_bindir}/$p" >> files.programs
+       echo "%attr(755,root,root) %{_libdir}/wine/$p.exe.so" >> files.programs
+       grep -v "$p\.exe\.so$" files.so > files.so.
+       mv -f files.so. files.so
+done
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -210,38 +277,61 @@ fi
 
 %postun -p /sbin/ldconfig
 
-%files
+%files -f files.so
 %defattr(644,root,root,755)
-%doc *.gz
-%doc documentation/wine-user
+%doc README DEVELOPERS-HINTS ChangeLog BUGS AUTHORS ANNOUNCE
+%doc documentation/samples
+%if %{with html_docs}
+%doc documentation/wine-{faq,user}
+%endif
 %attr(755,root,root) %{_bindir}/wine
-%attr(755,root,root) %{_bindir}/winebuild
-%attr(755,root,root) %{_bindir}/winemaker
-%attr(755,root,root) %{_bindir}/wineserver
+%attr(755,root,root) %{_bindir}/wineboot
+%attr(755,root,root) %{_bindir}/winecfg
 %attr(755,root,root) %{_bindir}/wineclipsrv
+%attr(755,root,root) %{_bindir}/winedbg
 %attr(755,root,root) %{_bindir}/winelauncher
+%attr(755,root,root) %{_bindir}/wineserver
 %attr(755,root,root) %{_bindir}/wineshelllink
-%attr(755,root,root) %{_bindir}/winedump
-%attr(755,root,root) %{_bindir}/wrc
-%attr(755,root,root) %{_bindir}/wmc
-%attr(755,root,root) %{_bindir}/fnt2bdf
-%attr(755,root,root) %{_bindir}/function_grep.pl
 %attr(755,root,root) %{_libdir}/*.so*
-%{_libdir}/wine
-%{_mandir}/man[15]/*
+%dir %{_libdir}/wine
+%{_mandir}/man1/wine.*
+%{_mandir}/man5/wine.conf.*
 %config(noreplace) %{_sysconfdir}/wine.reg
 %config(missingok) %{_sysconfdir}/wine.systemreg
 %config(missingok) %{_sysconfdir}/wine.userreg
 %attr(754,root,root) %{_sysconfdir}/rc.d/init.d/wine
 %{_winedir}
 
-%files programs -f programs.list
+%files programs -f files.programs
 %defattr(644,root,root,755)
-%attr (755,root,root) %{_bindir}/hlp2sgml
-%{_bindir}/*.so
 
 %files devel
 %defattr(644,root,root,755)
+%if %{with html_docs}
 %doc documentation/{wine-devel,winelib-user,HOWTO-winelib}
+%endif
+%attr(755,root,root) %{_bindir}/fnt2bdf
+%attr(755,root,root) %{_bindir}/function_grep.pl
+%attr(755,root,root) %{_bindir}/hlp2sgml
+%attr(755,root,root) %{_bindir}/widl
+%attr(755,root,root) %{_bindir}/winebuild
+%attr(755,root,root) %{_bindir}/winedump
+%attr(755,root,root) %{_bindir}/wineg++
+%attr(755,root,root) %{_bindir}/winegcc
+%attr(755,root,root) %{_bindir}/winemaker
+%attr(755,root,root) %{_bindir}/winewrap
+%attr(755,root,root) %{_bindir}/wmc
+%attr(755,root,root) %{_bindir}/wrc
 %{_includedir}/wine
 %{_libdir}/*.a
+%{_mandir}/man1/winemaker.*
+%{_mandir}/man1/winebuild.*
+%{_mandir}/man1/wmc.*
+%{_mandir}/man1/wrc.*
+%{_aclocaldir}/*.m4
+
+%if %{with pdf_docs}
+%files doc-pdf
+%defattr(644,root,root,755)
+%doc documentation/*.pdf
+%endif
This page took 0.050881 seconds and 4 git commands to generate.