%define DATE 20020507 Summary: A Windows 16/32 bit emulator. Name: winex%{DATE} Version: 2.0.x Release: 16 Group: Applications/Emulators License: Aladdin Free Public License URL: http://www.transgaming.com/ Source: winex-%{DATE}-cvs.tar.bz2 Source2: winex.config #Source2: winex.userreg #Source3: winex.systemreg #Source2: winex.config # #(cd dlls/opengl32; ./make_opengl specs2 1.2) # # after winex20020507 no pasaran, mlya! And I don't know why :-/ # So we'll go by other way ;-) - look at winex.patch-opengl-speedup # new gl.spec and gl.tm from SGI not needed now. # # On my home Duron1200 GF4MX440 - Blue shift (HL'clone), Hazard Cource, at the begining # before this patch timerefresh show 180FPS under wine and 340FPS in native windoze # after patch and without -fPIC 330FPS and 337FPS with native glu32.dll under wine ;-) # Any comments? # Patch: winex.patch-opengl-speedup # # after --disable-debug & --disable-trace TRACE & WARN do stupid if() # remove it # Patch2: winex.patch-debug # # enable mouse & keyboad with DGA, not finished yet # Don't use DGA!!! # Patch3: winex.patch-dga # # Heroes III wants G:\\HMM3\\DATA\\filename.ext but has G:\\HMM3\\DATAfilename.ext :-) # Patch4: winex.patch-hmm3 Patch5: winex.patch-make Patch6: winex.patch-registry #Patch7: winex.patch-registry-hostname # # SeriousSam & SeriousSam-SE check opengl by if( exists( "$WINDOWSSYSTEMDIR/opengl32.dll")) # so touch it. Maybe it looks at registry and add record to winedefault.reg? # wglDescribePixelFormat return PFD_GENERIC_ACCELERATED but SSam expects PFD_SWAP_COPY or more. # kgm, I'm not sure about PFD_SWAP_COPY, but NV windriver return that on GF2MX, so ... # Patch8: winex.patch-SeriousSam # # Need for WarCraft III -opengl, already in winehq # Patch9: winex.patch-opengl-swap-buffers # # System Shock 2 # Patch10: winex.patch-sshock # # not needed now, used winex.patch-opengl-speedup # Patch11: winex.patch-make_opengl Buildroot: %{_tmppath}/%{name}-root ExclusiveArch: %{ix86} Prefix: /usr/local/winex%{DATE} Prereq: shadow-utils BuildRequires: docbook-utils autoconf253 flex bison #ipxutils %description While Wine is usually thought of as a Windows(TM) emulator, the Wine developers would prefer that users thought of Wine as a Windows compatibility layer for UNIX. This package includes a program loader, which allows unmodified Windows 3.1/95/NT binaries to run under Intel Unixes. Wine does not require MS Windows, but it can use native system .dll files if they are available. Accelerated opengl build %package devel Summary: Wine development environment. Group: System Environment/Libraries Requires: winex%{DATE} = %{version} %description devel Header and include files for developing applications with the Wine Windows(TM) emulation libraries. %package doc Summary: Wine documentation. Group: System Environment/Libraries Requires: winex%{DATE} = %{version} %description doc Documantations for Wine. %prep %setup -q -n wine find . -type d -name CVS |xargs rm -rf %patch -p1 %patch2 -p1 #%patch3 -p1 %patch4 -p1 %patch5 -p1 %patch6 -p1 #%patch7 -p1 %patch8 -p1 %patch9 -p1 %patch10 -p1 #%patch11 -p1 %build # kgm, conflict nvidia/GL/*.h and GL/glu.h #export EXTRAINCL="-I/usr/share/doc/NVIDIA_GLX-1.0/usr/include" # # -fPIC eats 10-15% FPS in Half-Life on Celeron566 # mv configure.ac configure.ac.original sed s/-fPIC// configure.ac.original > configure.ac export CC="gcc31" export CFLAGS="$RPM_OPT_FLAGS -mcpu=i686 -march=i686 -O2 -DNDEBUG -fomit-frame-pointer" autoconf-2.53 %configure \ --prefix=%{prefix} \ --bindir=%{prefix}/bin \ --libdir=%{prefix}/lib \ --includedir=%{prefix}/include \ --sysconfdir=%{prefix}/etc \ --with-x \ --enable-dll \ --disable-debug \ --disable-trace \ --enable-opengl # # # --enable-sdldrv make depend make (cd programs/regapi; make) make -C documentation wine-doc/index.html %install rm -rf $RPM_BUILD_ROOT %makeinstall \ bindir=${RPM_BUILD_ROOT}%{prefix}/bin \ libdir=${RPM_BUILD_ROOT}%{prefix}/lib \ sysconfdir=${RPM_BUILD_ROOT}%{prefix}/etc \ includedir=$RPM_BUILD_ROOT/usr/include/wine (cd ${RPM_BUILD_ROOT}%{prefix}/bin; ln -s wine regapi) cp programs/regapi/regapi.so ${RPM_BUILD_ROOT}%{prefix}/bin # Take care of wine and windows configuration files... mkdir -p ${RPM_BUILD_ROOT}%{prefix}/etc mkdir -p $RPM_BUILD_ROOT/usr/bin #install -c -m 0644 %{SOURCE2} $RPM_BUILD_ROOT%{prefix}/etc/wine.userreg #install -c -m 0644 %{SOURCE3} $RPM_BUILD_ROOT%{prefix}/etc/wine.systemreg #install -c documentation/samples/config $RPM_BUILD_ROOT%{prefix}/etc/config install -c -m 0644 %{SOURCE2} $RPM_BUILD_ROOT%{prefix}/etc/config install -c -m 0644 winedefault.reg $RPM_BUILD_ROOT%{prefix}/etc/winedefault.reg cat >$RPM_BUILD_ROOT%{prefix}/bin/create-windows-dir <\${rootdir}/disk/c/windows/system.ini < $RPM_BUILD_ROOT/usr/bin/winex%{DATE} echo >> $RPM_BUILD_ROOT/usr/bin/winex%{DATE} echo "WINEINSTDIR=/usr/local/winex"%{DATE} >> $RPM_BUILD_ROOT/usr/bin/winex%{DATE} cat >>$RPM_BUILD_ROOT/usr/bin/winex%{DATE} < \${WINEINI} if ! regapi setValue < \${WINEINSTDIR}/etc/winedefault.reg > /dev/null ; then rm -rf \${WINEINSTDIR}/etc/wineserver-\`hostname -f\` rm -f \${WINEINI} mv \${WINEINI}.original \${WINEINI} echo "Registry install failed." exit 1 fi sync rm -rf \${WINEINSTDIR}/etc/wineserver-\`hostname -f\` rm -f \${WINEINI} mv \${WINEINI}.original \${WINEINI} mv \${WINEINSTDIR}/etc/system.reg \${WINEINSTDIR}/etc/wine.systemreg mv \${WINEINSTDIR}/etc/userdef.reg \${WINEINSTDIR}/etc/wine.userreg rm -f \${WINEINSTDIR}/etc/user.reg WINEPREFIX=\${WINEPREFIXSAVE} [ x"\${*}" = "x" ] && exit 0 fi [ -z \${WINEPREFIX} ] && WINEPREFIX=~/.winex [ ! -d \${WINEPREFIX} ] && mkdir -p \${WINEPREFIX} export WINEPREFIX if [ -f \${WINEINSTDIR}/etc/cachedmetrics.\${DISPHOST}:\${DISPNUM}.\${DISPSCR} ]; then if [ \${WINEINSTDIR}/etc/cachedmetrics.\${DISPHOST}:\${DISPNUM}.\${DISPSCR} -nt \ \${WINEPREFIX}/cachedmetrics.\${DISPHOST}:\${DISPNUM}.\${DISPSCR} ]; then rm -f \${WINEPREFIX}/cachedmetrics.\${DISPHOST}:\${DISPNUM}.\${DISPSCR} ln -s \${WINEINSTDIR}/etc/cachedmetrics.\${DISPHOST}:\${DISPNUM}.\${DISPSCR} \ \${WINEPREFIX}/cachedmetrics.\${DISPHOST}:\${DISPNUM}.\${DISPSCR} fi fi wine \$* rm -rf \${WINEPREFIX}/wineserver-\`hostname -f\` EOF chmod 0755 $RPM_BUILD_ROOT/usr/bin/winex%{DATE} %clean rm -r $RPM_BUILD_ROOT %post groupadd -f gamer %{prefix}/bin/create-windows-dir winex%{DATE} %files %defattr(-,root,root) /usr/local/winex%{DATE}/lib/lib*.so* /usr/local/winex%{DATE}/bin/* /usr/local/winex%{DATE}/etc/* /usr/bin/* %files doc %{_mandir}/man?/* %doc ANNOUNCE BUGS ChangeLog DEVELOPERS-HINTS LICENSE* README* %doc AUTHORS WARRANTY *.reg %doc documentation/ChangeLog.OLD documentation/HOWTO-winelib %doc documentation/gui documentation/psdrv.reg documentation/shell32 %doc documentation/samples documentation/status %doc documentation/wine-doc documentation/samples documentation/status %doc programs/regapi/README %files devel %defattr(-,root,root) /usr/include/* %changelog * Sun May 26 2002 Serge Ryabchun 20020507 - add new gl.tm and gl.spec * Wed Nov 05 2001 Serge Ryabchun 20011107 - first build