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