SHA256
1
0
forked from pool/wine

new baselibs.conf method imported

OBS-URL: https://build.opensuse.org/package/show/Emulators/wine?expand=0&rev=120
This commit is contained in:
Marcus Meissner 2012-01-30 13:03:24 +00:00 committed by Git OBS Bridge
parent a28b7309e4
commit 2e901e6e7d
2 changed files with 100 additions and 105 deletions

15
baselibs.conf Normal file
View File

@ -0,0 +1,15 @@
wine
+^/usr/bin/wine$
+^/usr/bin/wine-preloader$
requires "libX11.so.6"
requires "libXext.so.6"
requires "libXcursor.so.1"
requires "libXi.so.6"
requires "libXxf86vm.so.1"
requires "libXrender.so.1"
requires "libXrandr.so.2"
requires "libXinerama.so.1"
requires "libXcomposite.so.1"
requires "libGL.so.1"
requires "libGLU.so.1"
wine-devel

190
wine.spec
View File

@ -15,7 +15,6 @@
# Please submit bugfixes or comments via http://bugs.opensuse.org/ # Please submit bugfixes or comments via http://bugs.opensuse.org/
# #
%bcond_with hal %bcond_with hal
Name: wine Name: wine
@ -70,6 +69,7 @@ Source2: http://kegel.com/wine/wisotool
Source3: README.SuSE Source3: README.SuSE
Source4: wine.desktop Source4: wine.desktop
Source5: ubuntuwine.tar.bz2 Source5: ubuntuwine.tar.bz2
Source7: baselibs.conf
# SUSE specific patches # SUSE specific patches
# - currently none, but add them here # - currently none, but add them here
Patch0: susepatches.patch Patch0: susepatches.patch
@ -78,13 +78,22 @@ Recommends: wine-mp3
Recommends: dosbox Recommends: dosbox
Conflicts: wine-gecko < 1.3 Conflicts: wine-gecko < 1.3
%ifarch %ix86 x86_64 %ifarch x86_64
Requires: wine-32bit = %version Requires: wine-32bit = %version
%endif %endif
# for winetricks: # for winetricks:
Requires: unzip cabextract Requires: unzip cabextract
%ifarch x86_64 %ifarch x86_64
Requires: libX11.so.6()(64bit) libXext.so.6()(64bit) libXcursor.so.1()(64bit) libXi.so.6()(64bit) libXxf86vm.so.1()(64bit) libXrender.so.1()(64bit) libXrandr.so.2()(64bit) libXinerama.so.1()(64bit) libXcomposite.so.1()(64bit) libGL.so.1()(64bit) libGLU.so.1()(64bit) libxslt.so.1()(64bit) libncurses.so.6()(64bit) libfreetype.so.6()(64bit) libfontconfig.so.1()(64bit) libcups.so.2()(64bit) Requires: libX11.so.6()(64bit) libXext.so.6()(64bit) libXcursor.so.1()(64bit) libXi.so.6()(64bit) libXxf86vm.so.1()(64bit) libXrender.so.1()(64bit) libXrandr.so.2()(64bit) libXinerama.so.1()(64bit) libXcomposite.so.1()(64bit) libGL.so.1()(64bit) libGLU.so.1()(64bit) libxslt.so.1()(64bit) libncurses.so.6()(64bit) libfreetype.so.6()(64bit) libfontconfig.so.1()(64bit) libcups.so.2()(64bit)
%else
%ifarch %ix86
Requires: libXcursor.so.1 libXi.so.6 libXxf86vm.so.1 libXrender.so.1 libXrandr.so.2 libXinerama.so.1 libXcomposite.so.1 libxslt.so.1 libncurses.so.6 libfreetype.so.6 libcrypto.so.1.0.0 libssl.so.1.0.0 libfontconfig.so.1 libcups.so.2 libpng14.so.14
%if 0%{?suse_version} < 1210
Requires: libgnutls.so.26
%else
Requires: libgnutls.so.28
%endif
%endif
%endif %endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRoot: %{_tmppath}/%{name}-%{version}-build
@ -96,33 +105,13 @@ libraries.
It is not necessary to have a Windows installation to run WINE. It is not necessary to have a Windows installation to run WINE.
Refer to /usr/share/doc/packages/wine/README.SuSE. There is more Refer to %{_datadir}/doc/packages/wine/README.SuSE. There is more
documentation available in that directory. Read 'man wine' for further documentation available in that directory. Read 'man wine' for further
information. information.
You can invoke wine by entering 'wine program.exe'. Configure it by You can invoke wine by entering 'wine program.exe'. Configure it by
running 'winecfg'. running 'winecfg'.
%ifarch %ix86
%package 32bit
Summary: The 32bit runtime system of Wine
Group: System/Emulators/PC
# requires either 32bit or 64bit wine
Requires: wine = %version
# lib dependencies that are dynamically loaded
Requires: libXcursor.so.1 libXi.so.6 libXxf86vm.so.1 libXrender.so.1 libXrandr.so.2 libXinerama.so.1 libXcomposite.so.1 libxslt.so.1 libncurses.so.6 libfreetype.so.6 libcrypto.so.1.0.0 libssl.so.1.0.0 libfontconfig.so.1 libcups.so.2 libpng14.so.14
%if 0%{?suse_version} < 1210
Requires: libgnutls.so.26
%else
Requires: libgnutls.so.28
%endif
%description 32bit
This package contains the 32bit runtime environment (libraries, DLLs, EXEs) of Wine.
It is required to run Win32 binaries. It requires either the 32bit or 64bit
"wine" environment to work.
%endif
%package devel %package devel
Summary: files for wine development Summary: files for wine development
@ -132,8 +121,6 @@ Group: System/Emulators/PC
This RPM contains the header files and development tools for the WINE This RPM contains the header files and development tools for the WINE
libraries. libraries.
%prep %prep
%setup -q %setup -q
%patch0 -p1 %patch0 -p1
@ -148,8 +135,8 @@ cat VERSION
export RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-fomit-frame-pointer//'` export RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-fomit-frame-pointer//'`
%endif %endif
# keep just for susepatches with configure changes # keep just for susepatches with configure changes
autoconf #autoconf
autoheader -I include #autoheader -I include
CFLAGS="$RPM_OPT_FLAGS" \ CFLAGS="$RPM_OPT_FLAGS" \
%configure \ %configure \
--with-x \ --with-x \
@ -158,77 +145,78 @@ CFLAGS="$RPM_OPT_FLAGS" \
%endif %endif
--verbose --verbose
cat config.log
grep "have_x=yes" config.log || exit 1 grep "have_x=yes" config.log || exit 1
grep SONAME_ config.status # generate baselibs.conf
%ifarch %ix86
echo "# autogenerated in .spec file" >%SOURCE7
echo "%name" >> %SOURCE7
echo " +^/usr/bin/wine\$" >> %SOURCE7
echo " +^/usr/bin/wine-preloader\$" >> %SOURCE7
echo " +^/usr/lib/wine/fakedlls" >> %SOURCE7
grep SONAME_ config.log
grep SONAME_ config.log|grep -v 'so"'|sed -e 's/^.*\(".*"\).*$/ requires \1/;'|sort -u >>%SOURCE7
echo "%name-devel" >> %SOURCE7
cat %SOURCE7
%endif
make %{?jobs:-j%jobs} all make %{?jobs:-j%jobs} all
%install %install
make install DESTDIR=$RPM_BUILD_ROOT make install DESTDIR=%{buildroot}
# install desktop file # install desktop file
install -d $RPM_BUILD_ROOT/usr/share/applications/ install -d %{buildroot}%{_datadir}/applications/
%suse_update_desktop_file %{SOURCE4} Emulator %suse_update_desktop_file %{SOURCE4} Emulator
install -m 0644 %SOURCE4 $RPM_BUILD_ROOT/usr/share/applications/ install -m 0644 %SOURCE4 %{buildroot}%{_datadir}/applications/
install -m 0755 %SOURCE1 $RPM_BUILD_ROOT/usr/bin/ install -m 0755 %SOURCE1 %{buildroot}%{_bindir}/
install -m 0755 %SOURCE2 $RPM_BUILD_ROOT/usr/bin/ install -m 0755 %SOURCE2 %{buildroot}%{_bindir}/
mv $RPM_BUILD_ROOT/%{_mandir}/de.UTF-8 $RPM_BUILD_ROOT/%{_mandir}/de mv %{buildroot}/%{_mandir}/de.UTF-8 %{buildroot}/%{_mandir}/de
mv $RPM_BUILD_ROOT/%{_mandir}/fr.UTF-8 $RPM_BUILD_ROOT/%{_mandir}/fr mv %{buildroot}/%{_mandir}/fr.UTF-8 %{buildroot}/%{_mandir}/fr
mv $RPM_BUILD_ROOT/%{_mandir}/pl.UTF-8 $RPM_BUILD_ROOT/%{_mandir}/pl mv %{buildroot}/%{_mandir}/pl.UTF-8 %{buildroot}/%{_mandir}/pl
tar xjf %{SOURCE5} tar xjf %{SOURCE5}
# Copied from Ubuntu Wine out of debian.diff # Copied from Ubuntu Wine out of debian.diff
# https://launchpad.net/~ubuntu-wine/+archive/ppa/+packages # https://launchpad.net/~ubuntu-wine/+archive/ppa/+packages
# taken on 1.2rc2 time. # taken on 1.2rc2 time.
cd ubuntuwine cd ubuntuwine
install -d $RPM_BUILD_ROOT/etc/xdg/menus/applications-merged install -d %{buildroot}%{_sysconfdir}/xdg/menus/applications-merged
install -c -m 644 wine.menu $RPM_BUILD_ROOT/etc/xdg/menus/applications-merged install -c -m 644 wine.menu %{buildroot}%{_sysconfdir}/xdg/menus/applications-merged
# Install application-specific desktop files # Install application-specific desktop files
install -d $RPM_BUILD_ROOT/usr/share/applications install -d %{buildroot}%{_datadir}/applications
install -c -m 644 *.desktop $RPM_BUILD_ROOT/usr/share/applications/ install -c -m 644 *.desktop %{buildroot}%{_datadir}/applications/
install -d $RPM_BUILD_ROOT/usr/share/desktop-directories/ install -d %{buildroot}%{_datadir}/desktop-directories/
install -c -m 644 *.directory $RPM_BUILD_ROOT/usr/share/desktop-directories/ install -c -m 644 *.directory %{buildroot}%{_datadir}/desktop-directories/
# Install icons # Install icons
install -d $RPM_BUILD_ROOT/usr/share/icons/hicolor/scalable/apps/ install -d %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/
install -c -m 644 *.svg $RPM_BUILD_ROOT/usr/share/icons/hicolor/scalable/apps/ install -c -m 644 *.svg %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/
cd .. cd ..
%fdupes -s $RPM_BUILD_ROOT %fdupes -s %{buildroot}
%ifarch %ix86
%post 32bit -p /sbin/ldconfig
%postun 32bit -p /sbin/ldconfig
%else
%post -p /sbin/ldconfig %post -p /sbin/ldconfig
%postun -p /sbin/ldconfig %postun -p /sbin/ldconfig
%endif
%files %files
%defattr(-,root,root) %defattr(-,root,root)
%doc ANNOUNCE AUTHORS LICENSE LICENSE.OLD README* %doc ANNOUNCE AUTHORS LICENSE LICENSE.OLD README*
/usr/bin/function_grep.pl %{_bindir}/function_grep.pl
/usr/bin/msiexec %{_bindir}/msiexec
/usr/bin/notepad %{_bindir}/notepad
/usr/bin/regedit %{_bindir}/regedit
/usr/bin/regsvr32 %{_bindir}/regsvr32
/usr/bin/wineboot %{_bindir}/wineboot
/usr/bin/winecfg %{_bindir}/winecfg
/usr/bin/wineconsole %{_bindir}/wineconsole
/usr/bin/winedbg %{_bindir}/winedbg
/usr/bin/winefile %{_bindir}/winefile
/usr/bin/winemine %{_bindir}/winemine
/usr/bin/winepath %{_bindir}/winepath
/usr/bin/wineserver %{_bindir}/wineserver
/usr/bin/winetricks %{_bindir}/winetricks
/usr/bin/wisotool %{_bindir}/wisotool
/usr/share/wine %{_datadir}/wine
/usr/share/applications/wine.desktop %{_datadir}/applications/wine.desktop
%doc %{_mandir}/man1/wine.1* %doc %{_mandir}/man1/wine.1*
%doc %{_mandir}/man1/winedbg.1* %doc %{_mandir}/man1/winedbg.1*
%doc %{_mandir}/man1/wineserver.1* %doc %{_mandir}/man1/wineserver.1*
@ -248,34 +236,26 @@ cd ..
%doc %{_mandir}/man1/winefile.1.* %doc %{_mandir}/man1/winefile.1.*
%doc %{_mandir}/man1/winemine.1.* %doc %{_mandir}/man1/winemine.1.*
%doc %{_mandir}/man1/winepath.1.* %doc %{_mandir}/man1/winepath.1.*
%dir /etc/xdg/menus/ %dir %{_sysconfdir}/xdg/menus/
%dir /etc/xdg/menus/applications-merged %dir %{_sysconfdir}/xdg/menus/applications-merged
%config /etc/xdg/menus/applications-merged/*.menu %config %{_sysconfdir}/xdg/menus/applications-merged/*.menu
/usr/share/applications/*.desktop %{_datadir}/applications/*.desktop
%dir /usr/share/desktop-directories/ %dir %{_datadir}/desktop-directories/
/usr/share/desktop-directories/*.directory %{_datadir}/desktop-directories/*.directory
%dir /usr/share/icons/hicolor %dir %{_datadir}/icons/hicolor
%dir /usr/share/icons/hicolor/scalable %dir %{_datadir}/icons/hicolor/scalable
%dir /usr/share/icons/hicolor/scalable/apps %dir %{_datadir}/icons/hicolor/scalable/apps
/usr/share/icons/hicolor/scalable/apps/*.svg %{_datadir}/icons/hicolor/scalable/apps/*.svg
%if 0%{?suse_version} > 1120
%ifarch %ix86 %ifarch %ix86
%{_bindir}/wine
%files 32bit %{_bindir}/wine-preloader
%defattr(-,root,root)
%endif
%endif
%ifarch %ix86
/usr/bin/wine
/usr/bin/wine-preloader
%endif %endif
%ifarch ppc %ifarch ppc
/usr/bin/wine %{_bindir}/wine
%endif %endif
%ifarch x86_64 %ifarch x86_64
/usr/bin/wine64 %{_bindir}/wine64
/usr/bin/wine64-preloader %{_bindir}/wine64-preloader
%endif %endif
%{_libdir}/wine/*.so %{_libdir}/wine/*.so
%{_libdir}/lib*.so.* %{_libdir}/lib*.so.*
@ -286,15 +266,15 @@ cd ..
%files devel %files devel
%defattr(-,root,root) %defattr(-,root,root)
%{_includedir}/wine %{_includedir}/wine
/usr/bin/widl %{_bindir}/widl
/usr/bin/winebuild %{_bindir}/winebuild
/usr/bin/winecpp %{_bindir}/winecpp
/usr/bin/winedump %{_bindir}/winedump
/usr/bin/wineg++ %{_bindir}/wineg++
/usr/bin/winegcc %{_bindir}/winegcc
/usr/bin/winemaker %{_bindir}/winemaker
/usr/bin/wmc %{_bindir}/wmc
/usr/bin/wrc %{_bindir}/wrc
%{_libdir}/wine/*.def %{_libdir}/wine/*.def
%{_libdir}/wine/*.a %{_libdir}/wine/*.a
%{_libdir}/lib*.so %{_libdir}/lib*.so
@ -307,6 +287,6 @@ cd ..
%doc %{_mandir}/man1/wmc.1* %doc %{_mandir}/man1/wmc.1*
%doc %{_mandir}/man1/wrc.1* %doc %{_mandir}/man1/wrc.1*
# /usr/share/aclocal/wine.m4 # %{_datadir}/aclocal/wine.m4
%changelog %changelog