]>
Commit | Line | Data |
---|---|---|
ac1d23c1 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_with glide2_sdk # build Glide2x_SDK here (normally built from Glide_V3.spec) | |
4 | # | |
4c49c243 | 5 | Summary: Glide runtime for 3Dfx Voodoo Graphics boards |
61beb790 | 6 | Summary(pl.UTF-8): Środowisko Glide dla kart 3Dfx Voodoo Graphics |
cf05b513 | 7 | Name: Glide_VG |
8 | Version: 2.46 | |
0c0bac19 | 9 | Release: 11 |
4c49c243 | 10 | License: 3DFX GLIDE Source Code General Public License |
edf0eec0 | 11 | Group: Libraries |
07dc9c23 | 12 | Source0: Glide%{version}.tar.gz |
0a60b64a | 13 | # Source0-md5: be7762636b46cb04b238a16f45cfcfa8 |
07dc9c23 | 14 | Patch0: %{name}-asm.patch |
63739d9f | 15 | Patch1: %{name}-opt.patch |
d98d2b0c | 16 | Patch2: %{name}-morearchs.patch |
4dc461ef | 17 | Patch3: %{name}-ioctl.patch |
fe94377d | 18 | Patch4: %{name}-soname.patch |
26652483 | 19 | Patch5: %{name}-C_brainos.patch |
0c0bac19 JB |
20 | Patch6: %{name}-format.patch |
21 | Patch7: %{name}-include.patch | |
ca5929e7 | 22 | URL: http://glide.sourceforge.net/ |
4df864eb | 23 | %ifarch %{ix86} |
d5e33c76 | 24 | BuildRequires: /usr/bin/gasp |
4df864eb | 25 | %endif |
ca5929e7 JB |
26 | BuildRequires: xorg-lib-libX11-devel |
27 | BuildRequires: xorg-lib-libXxf86dga-devel | |
28 | BuildRequires: xorg-lib-libXxf86vm-devel | |
e5c076fb | 29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
53af08fa | 30 | |
31 | %description | |
4c49c243 | 32 | This library allows the user to use a 3Dfx Interactive Voodoo Graphics |
edf0eec0 | 33 | card under Linux. |
3d6c707d | 34 | |
a216d7c4 JR |
35 | %description -l pl.UTF-8 |
36 | Ten pakiet pozwala na używanie kart 3Dfx Interactive Voodoo Graphics | |
4c49c243 JB |
37 | pod Linuksem. |
38 | ||
ac1d23c1 JB |
39 | %package devel |
40 | Summary: Development package for Glide 2.x built for Voodoo Graphics | |
41 | Summary(pl.UTF-8): Pakiet programistyczny dla Glide 2.x zbudowanego dla Voodoo Graphics | |
42 | Group: Development/Libraries | |
43 | Requires: %{name} = %{version}-%{release} | |
44 | Requires: Glide2x_SDK >= %{version} | |
3b38075b | 45 | Provides: Glide2x-devel = %{version} |
ac1d23c1 JB |
46 | |
47 | %description devel | |
48 | Development package for Glide 2.x built for 3Dfx Interactive Voodoo | |
49 | Graphics adapters. | |
50 | ||
51 | %description devel -l pl.UTF-8 | |
52 | Pakiet programistyczny dla Glide 2.x zbudowanego dla kart 3Dfx | |
53 | Interactive Voodoo Graphics. | |
54 | ||
53af08fa | 55 | %package -n Glide2x_SDK |
ac1d23c1 | 56 | Summary: Development files for Glide 2.x |
61beb790 | 57 | Summary(pl.UTF-8): Część Glide 2.x przeznaczona dla programistów |
cf05b513 | 58 | Group: Development/Libraries |
d20f55c8 | 59 | Conflicts: Glide_SDK |
53af08fa | 60 | |
61 | %description -n Glide2x_SDK | |
62 | This package includes the headers files, documentation, and test files | |
63 | necessary for developing applications that use the 3Dfx Interactive | |
64 | Voodoo Graphics, Voodoo Rush, or Voodoo2 card. | |
65 | ||
a216d7c4 JR |
66 | %description -n Glide2x_SDK -l pl.UTF-8 |
67 | Ten pakiet zawiera pliki nagłówkowe, dokumentację i pliki testowe | |
68 | potrzebne do tworzenia aplikacji używających kart 3Dfx Interactive | |
4c49c243 JB |
69 | Voodoo Graphics, Voodoo Rush lub Voodoo2. |
70 | ||
53af08fa | 71 | %prep |
cf05b513 | 72 | %setup -q -c |
63739d9f JB |
73 | %patch0 -p1 |
74 | %patch1 -p1 | |
d98d2b0c | 75 | %patch2 -p1 |
4dc461ef | 76 | %patch3 -p1 |
fe94377d | 77 | %patch4 -p1 |
26652483 | 78 | %patch5 -p1 |
0c0bac19 JB |
79 | %patch6 -p1 |
80 | %patch7 -p1 | |
53af08fa | 81 | chmod +x swlibs/include/make/ostype |
82 | ||
83 | %build | |
753c8420 | 84 | %{__make} -j1 -f makefile.unix \ |
c38e5d24 | 85 | CC="%{__cc}" \ |
d98d2b0c | 86 | CNODEBUG="%{rpmcflags} -fPIC %{!?debug:-fomit-frame-pointer} \ |
ca5929e7 | 87 | %{!?debug:-funroll-loops -fexpensive-optimizations -ffast-math}" \ |
d98d2b0c JB |
88 | %ifnarch %{ix86} |
89 | FX_GLIDE_CTRISETUP=1 | |
90 | %endif | |
53af08fa | 91 | |
92 | %install | |
93 | rm -rf $RPM_BUILD_ROOT | |
46c6bc1f | 94 | install -d $RPM_BUILD_ROOT{%{_libdir},%{_bindir}} |
53af08fa | 95 | |
96 | # Install the glibc 2.1 libraries normally | |
d8c27465 JB |
97 | install sst1/lib/libglide.so.2.46 $RPM_BUILD_ROOT%{_libdir} |
98 | ln -sf libglide.so.2.46 $RPM_BUILD_ROOT%{_libdir}/libglide.so.2 | |
99 | ln -sf libglide.so.2 $RPM_BUILD_ROOT%{_libdir}/libglide2x.so | |
403fc473 | 100 | ln -sf libglide.so.2 $RPM_BUILD_ROOT%{_libdir}/libglide.so |
d8c27465 JB |
101 | install swlibs/lib/libtexus.so.1.1 $RPM_BUILD_ROOT%{_libdir} |
102 | ln -sf libtexus.so.1.1 $RPM_BUILD_ROOT%{_libdir}/libtexus.so.1 | |
103 | ln -sf libtexus.so.1 $RPM_BUILD_ROOT%{_libdir}/libtexus.so | |
53af08fa | 104 | |
105 | # Install the executables | |
07dc9c23 JB |
106 | install swlibs/bin/texus $RPM_BUILD_ROOT%{_bindir} |
107 | install sst1/glide/tests/test00 $RPM_BUILD_ROOT%{_bindir}/test3Dfx | |
53af08fa | 108 | |
ac1d23c1 | 109 | %if %{with glide2_sdk} |
46c6bc1f JB |
110 | ### SDK |
111 | install -d $RPM_BUILD_ROOT%{_includedir}/glide \ | |
112 | $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/{tests,texus/examples} | |
113 | ||
53af08fa | 114 | # Install the headers |
cf05b513 | 115 | install swlibs/include/3dfx.h $RPM_BUILD_ROOT%{_includedir}/glide |
116 | install sst1/include/glide.h $RPM_BUILD_ROOT%{_includedir}/glide | |
117 | install sst1/include/glidesys.h $RPM_BUILD_ROOT%{_includedir}/glide | |
118 | install sst1/include/glideutl.h $RPM_BUILD_ROOT%{_includedir}/glide | |
119 | install sst1/include/sst1vid.h $RPM_BUILD_ROOT%{_includedir}/glide | |
120 | install sst1/include/gump.h $RPM_BUILD_ROOT%{_includedir}/glide | |
121 | install swlibs/include/linutil.h $RPM_BUILD_ROOT%{_includedir}/glide | |
122 | install swlibs/include/texus.h $RPM_BUILD_ROOT%{_includedir}/glide | |
53af08fa | 123 | |
124 | # Install the examples and their source | |
bb15827d JB |
125 | install sst1/glide/tests/makefile.distrib $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/tests/makefile |
126 | install sst1/glide/tests/*.3df $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/tests | |
127 | install sst1/glide/tests/test??.c $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/tests | |
128 | install sst1/glide/tests/tldata.inc $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/tests | |
129 | install sst1/glide/tests/tlib.[ch] $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/tests | |
130 | gzip -9nf $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/tests/*.3df | |
53af08fa | 131 | |
132 | # Install the texture tools source | |
bb15827d | 133 | install swlibs/texus/examples/makefile.distrib $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/texus/examples/makefile |
bb15827d | 134 | install swlibs/texus/examples/*.c $RPM_BUILD_ROOT%{_examplesdir}/glide2x-%{version}/texus/examples |
ac1d23c1 | 135 | %endif |
edf0eec0 | 136 | |
53af08fa | 137 | %clean |
138 | rm -rf $RPM_BUILD_ROOT | |
139 | ||
4c49c243 JB |
140 | %post -p /sbin/ldconfig |
141 | %postun -p /sbin/ldconfig | |
53af08fa | 142 | |
143 | %files | |
cf05b513 | 144 | %defattr(644,root,root,755) |
ca5929e7 | 145 | %doc glide_license.txt readme.txt |
cf05b513 | 146 | %attr(755,root,root) %{_bindir}/texus |
edf0eec0 | 147 | %attr(755,root,root) %{_bindir}/test3Dfx |
d8c27465 JB |
148 | %attr(755,root,root) %{_libdir}/libglide.so.2.46 |
149 | %attr(755,root,root) %ghost %{_libdir}/libglide.so.2 | |
edf0eec0 | 150 | %attr(755,root,root) %{_libdir}/libglide2x.so |
d8c27465 JB |
151 | %attr(755,root,root) %{_libdir}/libtexus.so.1.1 |
152 | %attr(755,root,root) %ghost %{_libdir}/libtexus.so.1 | |
edf0eec0 | 153 | %attr(755,root,root) %{_libdir}/libtexus.so |
53af08fa | 154 | |
ac1d23c1 JB |
155 | %files devel |
156 | %defattr(644,root,root,755) | |
157 | %attr(755,root,root) %{_libdir}/libglide.so | |
158 | ||
159 | %if %{with glide2_sdk} | |
53af08fa | 160 | %files -n Glide2x_SDK |
cf05b513 | 161 | %defattr(644,root,root,755) |
edf0eec0 | 162 | %doc docs/*.pdf |
cf05b513 | 163 | %{_includedir}/glide |
ac1d23c1 JB |
164 | %{_examplesdir}/glide2x-%{version} |
165 | %endif |