]> git.pld-linux.org Git - packages/dosemu.git/blob - dosemu.spec
- move binary sources to distfiles
[packages/dosemu.git] / dosemu.spec
1 # NOTE: if /dev/shm is mounted, it cannot be mounted with noexec
2 #
3 # Conditional build:
4 %bcond_with     static          # link statically
5 %bcond_with     AC
6 %bcond_without  htmldocs        # do not build documentation in HTML
7 %bcond_without  sdl             # SDL support
8 %bcond_without  x               # X support
9 %bcond_with     samba           # samba support
10 #
11 %define         smarthogver     0.1.0
12 %define         smbrel          01
13
14 Summary:        A DOS emulator
15 Summary(de.UTF-8):      DOS-Emulator
16 Summary(es.UTF-8):      Emulador DOS
17 Summary(fr.UTF-8):      Emulateur DOS
18 Summary(pl.UTF-8):      Emulator DOS-a
19 Summary(pt_BR.UTF-8):   Emulador DOS
20 Summary(tr.UTF-8):      DOS öykünümcüsü
21 Name:           dosemu
22 Version:        1.4.0
23 Release:        4%{?with_samba:.smb%{smbrel}}
24 License:        GPL v2
25 Group:          Applications/Emulators
26 Source0:        http://dl.sourceforge.net/dosemu/%{name}-%{version}.tgz
27 # Source0-md5:  0bba530637266f99d404ba15e3f118d4
28 #Source2:       %{name}-sys.tar.gz
29 Source3:        %{name}-PRZECZYTAJ_TO
30 Source4:        %{name}-README.PLD
31 Source5:        %{name}.desktop
32 Source6:        http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-pl-man-pages.tar.bz2
33 # Source6-md5:  7a8abf5c656e6b99bdd03a4783751895
34 Source7:        smarthog-%{smarthogver}.tgz
35 # Source7-md5:  a9f64e8e90382ac3426c39caecd7f64f
36 Patch0:         %{name}-man-pages.patch
37 Patch1:         %{name}-make-new.patch
38 Patch2:         %{name}-%{name}_conf.patch
39 Patch3:         %{name}-doSgmlTools.patch
40 Patch4:         %{name}-makehtml.patch
41 Patch5:         http://pascalek.pers.pl/files/projects/Samba4DosEmu/%{name}-1.4.0-samba-beta2.patch.gz
42 Patch6:         http://pascalek.pers.pl/files/projects/Samba4DosEmu/s4d-beta2-fix1.patch
43 Patch7:         %{name}-lpt4.patch
44 Patch8:         %{name}-Xquit.patch
45 Patch9:         %{name}-creat_mode.patch
46 URL:            http://www.dosemu.org/
47 %{?with_sdl:BuildRequires:      SDL-devel}
48 BuildRequires:  alsa-lib-devel >= 0.9
49 BuildRequires:  autoconf >= 2.59-9
50 BuildRequires:  bin86
51 BuildRequires:  bison
52 BuildRequires:  docbook-dtd30-sgml
53 BuildRequires:  docbook-style-dsssl
54 BuildRequires:  flex
55 %{?with_static:BuildRequires:   glibc-static}
56 BuildRequires:  gpm-devel
57 %{?with_samba:BuildRequires:    libcli_smb-devel}
58 BuildRequires:  libsndfile-devel
59 BuildRequires:  lynx
60 %{?with_htmldocs:BuildRequires: openjade}
61 %{?with_htmldocs:BuildRequires: perl-base}
62 %{?with_htmldocs:BuildRequires: sgml-tools}
63 BuildRequires:  slang-devel
64 %{?with_static:BuildRequires:   slang-static}
65 BuildRequires:  unzip
66 BuildRequires:  util-linux
67 %if %{with x}
68 %if !%{with AC}
69 BuildRequires:  xorg-app-bdftopcf
70 BuildRequires:  xorg-app-mkfontdir
71 BuildRequires:  xorg-lib-libX11-devel
72 BuildRequires:  xorg-lib-libXext-devel
73 BuildRequires:  xorg-lib-libXxf86vm-devel
74 %if %{with static}
75 BuildRequires:  xorg-lib-libX11-static
76 BuildRequires:  xorg-lib-libXext-static
77 BuildRequires:  xorg-lib-libXxf86vm-static
78 %endif
79 %endif
80 %if %{with AC}
81 BuildRequires:  X11-devel
82 %{?with_static:BuildRequires:   X11-static}
83 %endif
84 %endif
85 Obsoletes:      xdosemu
86 Conflicts:      dosemu-freedos-minimal < 2.0.33
87 Conflicts:      kernel < 2.0.28
88 Conflicts:      mtools < 3.6
89 ExclusiveArch:  %{ix86} %{x8664}
90 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
91
92 %define         _dosemudir      /var/lib/dosemu
93 %define         specflags       -fomit-frame-pointer
94
95 %description
96 Dosemu is a DOS emulator. Once you've installed dosemu, start the DOS
97 emulator by typing in the "dos" command.
98
99 You need to install dosemu if you use DOS programs and you want to be
100 able to run them on your GNU/Linux system. You may also need to
101 install the dosemu-freedos-* packages.
102
103 %description -l pl.UTF-8
104 Dosemu to Emulator systemu DOS. Po zainstalowaniu możesz go uruchomić
105 komendą "dos".
106
107 Jeśli korzystasz z dosowych programów i chciałbyś je uruchamiać na
108 twoim linuksowym systemie zainstaluj dosemu. Możesz też potrzebować
109 pakietów dosemu-freedos-*.
110
111 %description -l pt_BR.UTF-8
112 Essa é uma versão do emulador DOS que foi projetada para rodar em
113 sessões X Window. Oferece suporte para gráficos VGA bem como suporte
114 para mouse.
115
116 %package utils
117 Summary:        Utilities for dosemu
118 Summary(pl.UTF-8):      Programy pomocnicze do dosemu
119 Group:          Applications/Emulators
120 Requires:       %{name} = %{version}-%{release}
121
122 %description utils
123 Utilities for dosemu: dexeconfig, hdinfo, mkhdimage, mkfatimage16.
124
125 %description utils -l pl.UTF-8
126 Programy pomocnicze dla dosemu: dexeconfig, hdinfo, mkhdimage,
127 mkfatimage16.
128
129 %package SDL
130 Summary:        SDL plugin for dosemu
131 Summary(pl.UTF-8):      Wtyczka SDL dla dosemu
132 Group:          Libraries
133 Requires:       %{name} = %{version}-%{release}
134
135 %description SDL
136 SDL plugin for dosemu.
137
138 %description SDL -l pl.UTF-8
139 Wtyczka SDL dla dosemu.
140
141 %package X
142 Summary:        X plugin for dosemu
143 Summary(pl.UTF-8):      Wtyczka X dla dosemu
144 Group:          Libraries
145 Requires:       %{name} = %{version}-%{release}
146
147 %description X
148 X plugin for dosemu.
149
150 %description X -l pl.UTF-8
151 Wtyczka X dla dosemu.
152
153 %prep
154 %setup -q -a6 -a7
155
156 %patch0 -p1
157 %patch1 -p1
158 %patch2 -p1
159 %patch3 -p1
160 %patch4 -p1
161 %{?with_samba:%patch5 -p1}
162 %{?with_samba:%patch6 -p1}
163 %patch7 -p1
164 %patch8 -p1
165 %patch9 -p1
166
167 %build
168 OPTFLAGS="%{rpmcflags}"; export OPTFLAGS
169
170 ./mkpluginhooks enable plugin_keyboard off plugin_kbd_unicode on \
171 plugin_extra_charset on plugin_term on plugin_translate on plugin_demo off
172
173 %{__autoconf}
174 # configure2_13 must be used though because of ./default-configure
175
176 # non-X version
177 %configure2_13 \
178         %{?with_static:--enable-linkstatic} \
179         --enable-new-intcode \
180         --enable-aspi \
181         %{!?with_x:--without-x}
182
183 %{__make} \
184         WAIT=no
185
186 %{__make} -C man
187 mv -f man/dosemu.bin.1 man/dosemu.1
188 echo '.so dosemu.1' > man/dos.1
189 mv -f man/ru/dosemu.bin.1 man/ru/dosemu.1
190 echo '.so dosemu.1' > man/ru/dos.1
191
192 mv -f pl/man1/dos.1 pl/man1/dosemu.1
193 echo '.so dosemu.1' > pl/man1/dos.1
194 echo '.so dosemu.1' > pl/man1/xdosemu.1
195 echo '.so dosemu.1' > pl/man1/dosdebug.1
196
197 %if %{with htmldocs}
198 # documentation
199 %{__make} -C src/doc/DANG html
200 %{__make} -C src/doc/HOWTO html
201 %{__make} -C src/doc/README html
202
203 find src/doc -name "*.html" -exec cp -f '{}' doc/ ';'
204 %endif
205
206 %install
207 rm -rf $RPM_BUILD_ROOT
208 install -d $RPM_BUILD_ROOT{%{_bindir},%{_sysconfdir},%{_pixmapsdir},%{_desktopdir}} \
209         $RPM_BUILD_ROOT{%{_mandir}/man1,%{_mandir}/{pl,ru}/man1} \
210         $RPM_BUILD_ROOT%{_dosemudir}/bootdir/{dosemu,freedos/doc/fdkernel} \
211         $RPM_BUILD_ROOT%{_libdir}/dosemu
212
213 #%%{__make} install \
214 #       DESTDIR=$RPM_BUILD_ROOT
215
216 install bin/midid $RPM_BUILD_ROOT%{_bindir}/midid
217 install bin/dosemu.bin $RPM_BUILD_ROOT%{_bindir}/dosemu
218 ln -sf dosemu $RPM_BUILD_ROOT%{_bindir}/dos
219 %if %{with x}
220 ln -sf dosemu $RPM_BUILD_ROOT%{_bindir}/xdos
221 ln -sf dosemu $RPM_BUILD_ROOT%{_bindir}/xdosemu
222 ln -sf dosemu $RPM_BUILD_ROOT%{_bindir}/xdosexec
223 %endif
224
225 install bin/libplugin*.so  $RPM_BUILD_ROOT%{_libdir}/dosemu
226
227 install bin/{dosdebug,mkfatimage16} $RPM_BUILD_ROOT%{_bindir}
228 install src/tools/periph/{dexeconfig,hdinfo,mkhdimage} $RPM_BUILD_ROOT%{_bindir}
229 ln -sf dos $RPM_BUILD_ROOT%{_bindir}/dosexec
230
231 install etc/dosemu.xpm $RPM_BUILD_ROOT%{_pixmapsdir}
232 install etc/dosemu.users.example $RPM_BUILD_ROOT%{_sysconfdir}/dosemu.users
233 install etc/global.conf $RPM_BUILD_ROOT%{_dosemudir}/global.conf
234 install etc/dosemu.conf $RPM_BUILD_ROOT%{_sysconfdir}/dosemu.conf
235
236 install man/{dosemu.1,dosdebug.1,xdosemu.1,dos.1,mkfatimage16.1} $RPM_BUILD_ROOT%{_mandir}/man1
237 install pl/man1/{dosemu.1,dosdebug.1,xdosemu.1,dos.1} $RPM_BUILD_ROOT%{_mandir}/pl/man1
238 install man/ru/{dosemu.1,dosdebug.1,xdosemu.1,dos.1,mkfatimage16.1} $RPM_BUILD_ROOT%{_mandir}/ru/man1
239
240 install commands/*.com $RPM_BUILD_ROOT%{_dosemudir}/bootdir/dosemu
241 install commands/*.sys $RPM_BUILD_ROOT%{_dosemudir}/bootdir/dosemu
242 install smarthog-%{smarthogver}/*.exe   $RPM_BUILD_ROOT%{_dosemudir}/bootdir/dosemu
243 cp %{SOURCE3} PRZECZYTAJ_TO
244 cp %{SOURCE4} README.PLD
245 install %{SOURCE5} $RPM_BUILD_ROOT%{_desktopdir}
246
247 rm -f doc/{configuration,dosemu.lsm}
248
249 %clean
250 rm -rf $RPM_BUILD_ROOT
251
252 %files
253 %defattr(644,root,root,755)
254 %doc QuickStart COPYING ChangeLog* doc/* README.PLD
255 %lang(pl) %doc PRZECZYTAJ_TO
256 %dir %{_dosemudir}
257 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/dosemu.conf
258 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/dosemu.users
259 %config(noreplace) %verify(not md5 mtime size) %{_dosemudir}/global.conf
260 %attr(755,root,root) %{_bindir}/dos
261 %attr(755,root,root) %{_bindir}/dosdebug
262 %attr(755,root,root) %{_bindir}/dosemu
263 %attr(755,root,root) %{_bindir}/dosexec
264 %attr(755,root,root) %{_bindir}/midid
265 %dir %{_libdir}/dosemu
266 %{_libdir}/dosemu/libplugin_alsa.so
267 %{_libdir}/dosemu/libplugin_gpm.so
268 %{_libdir}/dosemu/libplugin_sndfile.so
269 %{_libdir}/dosemu/libplugin_term.so
270 %dir %{_dosemudir}/bootdir
271 %dir %{_dosemudir}/bootdir/dosemu
272 %{_dosemudir}/bootdir/dosemu/*
273 %{_mandir}/man1/d*
274 %lang(pl) %{_mandir}/pl/man1/d*
275 %lang(ru) %{_mandir}/ru/man1/d*
276 %{_pixmapsdir}/dosemu.xpm
277 %if %{with x}
278 %attr(755,root,root) %{_bindir}/xdos*
279 %{_mandir}/man1/xdosemu.1*
280 %lang(pl) %{_mandir}/pl/man1/xdosemu.1*
281 %lang(ru) %{_mandir}/ru/man1/xdosemu.1*
282 %{_desktopdir}/dosemu.desktop
283 %endif
284
285 %files utils
286 %defattr(644,root,root,755)
287 %attr(755,root,root) %{_bindir}/dexeconfig
288 %attr(755,root,root) %{_bindir}/hdinfo
289 %attr(755,root,root) %{_bindir}/mkhdimage
290 %attr(755,root,root) %{_bindir}/mkfatimage16
291 %{_mandir}/man1/mkfatimage16.1*
292 %lang(ru) %{_mandir}/ru/man1/mkfatimage16.1*
293
294 %if %{with sdl}
295 %files SDL
296 %defattr(644,root,root,755)
297 %attr(755,root,root) %{_libdir}/dosemu/libplugin_sdl.so
298 %endif
299
300 %if %{with x}
301 %files X
302 %defattr(644,root,root,755)
303 %attr(755,root,root) %{_libdir}/dosemu/libplugin_X.so
304 %endif
This page took 0.399433 seconds and 3 git commands to generate.