Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37527512
en ru br
ALT Linux repos
5.0: 1.4.0-alt3.1.1
4.1: 1.4.0-alt2.M41.1
4.0: 1.4.0-alt2.M40.1
3.0: 1.3.2-alt4

Other repositories
Upstream:1.2.2

Group :: Emulators
RPM: dosemu

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

Name: dosemu
Version: 1.4.0
Release: alt3.1.1
Serial: 1
Packager: Grigory Batalov <bga at altlinux.ru>

Summary: The Linux DOS emulator
Summary(ru_RU.KOI8-R): Эмулятор DOS под Linux
License: GPL
Group: Emulators
Url: http://dosemu.sourceforge.net/

Source0: http://telia.dl.sourceforge.net/sourceforge/dosemu/%name-%version.tar

# icons from Mandrake

Source2: xdosemu.xpm
Source3: xdosemu-mini.xpm
Source4: xdosemu-large.xpm

# sources and precompiled fonts

Source9: dosemu-1.4.0-alt-fonts.tar

# default /etc/dosemu.users

Source13: dosemu.users

Patch: %name-%version-alt.patch

Obsoletes: dosemu-bin-nox
Conflicts: dosemu-freedos < 050405-alt3
Conflicts: dosemu-bin-x

# Automatically added by buildreq on Wed Sep 10 2008

BuildRequires: flex imake libX11-devel libICE-devel libSDL-devel libXext-devel libXxf86vm-devel libgpm-devel libslang-devel libsndfile-devel

%description
This package allows MS-DOS programs to be started in Linux. A virtual
machine (the DOS box) provides the necessary BIOS functions and emulates
most of the chip devices (e.g. timer, interrupt- and keyboard controler)
Documentation can be found in %_defaultdocdir/%name-%version and in the man
page, as well as in the sources.
You probably need dosemu-freedos package too.

%description -l ru_RU.KOI8-R
DOSEmu позволяет запускать программы MS-DOS под Linux. Виртуальная
машина (DOS) предоставляет необходимые функции BIOS и эмулирует
большинство устройств, таких как таймер, контроллеры прерываний
и клавиатуры. Документацию можно найти в %_defaultdocdir/%name-%version
и на страницах руководства (man). Как, впрочем, и в исходниках.
Вероятно, вам также понадобится пакет dosemu-freedos.

%package plugins-x-sdl
Summary: Dosemu X11 and SDL plugins
License: GPL
Group: Emulators
Requires: dosemu = %version-%release
Obsoletes: xdosemu
Obsoletes: dosemu-bin-x

%description plugins-x-sdl
The Linux DOS Emulator XFree86/Xorg and SDL plugins.

%package plugins-sound
Summary: Dosemu ALSA and Sndfile plugins
License: GPL
Group: Emulators
Requires: dosemu = %version-%release

%description plugins-sound
The Linux DOS Emulator ALSA and Sndfile plugins.

%prep
%setup -q

cp -f compiletime-settings.devel compiletime-settings
%patch -p1

sed -i -e "s!#[[:space:]]*\(\$_cli_timeout[[:space:]]*=[[:space:]]*\)(.*!\1(10)!g" etc/dosemu.conf
sed -i -e "s!#[[:space:]]*\(\$_ttylocks[[:space:]]*=[[:space:]]*\)\".*!\1\"/var/lock/serial\"!g" etc/dosemu.conf

# copy sources and precompiled VGA fonts

tar xf %SOURCE9 -C etc
gzip etc/*.pcf

# to avoid automatic autoreconf call

#touch configure.ac configure

%build
# TODO: why not try to disable these plugins?
sed -i -e "s! x off! x on!g" compiletime-settings
sed -i -e "s! plugin_sdl off! plugin_sdl on!g" compiletime-settings
%configure --with-pthreads
%make_build WAIT=no prefix=%_prefix

%install
# install itself
%make_install install DESTDIR=%buildroot prefix=%prefix \
     mandir=%_mandir docdir=%_defaultdocdir/%name-%version
# /var/lib/dosemu for custom DOS
mkdir -p %buildroot%_localstatedir/dosemu

# default /etc/dosemu.users

install -m644 %SOURCE13 %buildroot%_sysconfdir/dosemu.users
# copy icons
mkdir -p %buildroot{%_iconsdir,%_liconsdir,%_miconsdir}
install -m644 %SOURCE2 %buildroot%_iconsdir/xdosemu.xpm
install -m644 %SOURCE3 %buildroot%_miconsdir/xdosemu.xpm
install -m644 %SOURCE4 %buildroot%_liconsdir/xdosemu.xpm
# adjusting docs
#mv %buildroot%_sysconfdir/%name/global.conf %buildroot%_defaultdocdir/%name-%version
install -m644 doc/HP1100-cp866-fonts-HOWTO.txt %buildroot%_defaultdocdir/%name-%version/

# Menu entry for xdosemu

mkdir -p %buildroot%_menudir
cat >%buildroot%_menudir/xdosemu <<EOF
?package(%name-plugins-x-sdl):command="%_bindir/xdosemu" needs="X11" \
icon="xdosemu.xpm" section="Applications/Emulators" title="DOS emulator" \
longtitle="DOS emulator running under X"
EOF

# Be compatible with package upgrade

mv %buildroot%_datadir/%name/drive_z %buildroot%_datadir/%name/freedos
ln -s freedos %buildroot%_datadir/%name/drive_z
# Provide default autoexec.bat and config.sys
install -m644 dist/{autoexec.bat,config.sys} %buildroot%_datadir/%name/freedos/

%pre
# Prevent alternative update during older package removal
[ -f %_altdir/dosemu-bin-nox.xml ] && rm -f %_altdir/dosemu-bin-nox.xml ||:
[ -f %_altdir/dosemu-bin-x.xml ] && rm -f %_altdir/dosemu-bin-x.xml ||:

%post plugins-x-sdl
# (making fontlist)
if [ -x %_x11bindir/mkfontdir ]; then
  (cd %_datadir/dosemu/Xfonts; %_x11bindir/mkfontdir)
fi
%update_menus

%preun plugins-x-sdl
# (removing fontlist)
if [ $1 = "0" -a -f %_datadir/dosemu/Xfonts/fonts.dir ]; then
  rm -f %_datadir/dosemu/Xfonts/fonts.dir
fi

%postun plugins-x-sdl
%clean_menus

%files
%config(noreplace) %_sysconfdir/dosemu.conf
%config(noreplace) %_sysconfdir/dosemu.users
%config(noreplace) %_sysconfdir/global.conf
%exclude %_bindir/xdosemu*
%_bindir/*
%dir %_localstatedir/dosemu
%dir %_datadir/dosemu
%exclude %_datadir/dosemu/Xfonts
%_datadir/dosemu/*
%doc %_defaultdocdir/%name-%version
%exclude %_man1dir/xdosemu.*
%doc %_man1dir/*
%dir %_libdir/%name/
%_libdir/%name/libplugin_gpm.so
%_libdir/%name/libplugin_term.so

%files plugins-x-sdl
%_bindir/xdosemu*
%_menudir/xdosemu
%_libdir/%name/libplugin_sdl.so
%_libdir/%name/libplugin_X.so
%_datadir/dosemu/Xfonts
%_iconsdir/xdosemu.xpm
%_miconsdir/xdosemu.xpm
%_liconsdir/xdosemu.xpm
%doc %_man1dir/xdosemu.*

%files plugins-sound
%_libdir/%name/libplugin_alsa.so
%_libdir/%name/libplugin_sndfile.so

%changelog

Full changelog you can see here

 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin