Commit f8c74020 authored by CeRiAl's avatar CeRiAl

initial commit of dosbox 0.74

The DOSBox Team
Sjoerd v.d. Berg <harekiet>
Peter Veenstra <qbix79>
Ulf Wohlers <finsterr>
Tommy Frssman <fanskapet>
Dean Beeler <canadacow>
Sebastian Strohhcker <c2woody>
Ralf Grillenberger <h-a-l-9000>
nick_without_<> @
This diff is collapsed.
This diff is collapsed.
Things needed for compilation.
The Simple DirectMedia Library available at
The dll distributed with the windows version of DOSBox is slightly
modified. You can find the changes in the sourcepackage of DOSBox
(src/platform/sdl-win32.diff). If you want the patched sourcetree
send us an email. (see README)
Licensed under LGPL
Note that only version 1.2 and its subversions (1.2.8, 1.2.13 etc.)
are currently supported.
Curses (optional)
If you want to enable the debugger you need a curses library.
ncurses should be installed on just about every unix distro.
For win32 get pdcurses at
License: Open source
Libpng (optional)
Needed for the screenshots.
For win32 get libpng from
See for more details.
License: Open Source
Zlib (optional)
Needed by libpng.
For win32 get libz (rename to zlib) from
See for more details.
License: Open Source
SDL_Net (optional)
For modem/ipx support. Get it from
Licensed under LGPL
For compressed audio on diskimages. (optional)
This is for cue/bin cdrom images with compressed (mp3/ogg) audio tracks.
Get it from
Licenced under LGPL
for Alsa support under linux. Part of the linux kernel sources
Licensed under LGPL
If you want compile from the CVS under a unix system, you'll also need
automake (>=1.6), autoconf(>=2.50). Should be available at
For building on unix systems.
If you are building from the cvs run ./ first before doing the following.
1. ./configure
2. make
In step 1 you could add the following switches:
enables the internal debugger. --enable-debug=heavy enables even more
debug options. DOSBox should then be run from a xterm and when the sdl-
window is active press alt-pause to enter the debugger.
enables some memory increasing inlines. This greatly increases
compiletime for maybe a increase in speed.
disables the emulated fpu. Although the fpu emulation code isn't
finished and isn't entirely accurate it's advised to leave it on.
disables the assembly fpu core. Although relatively new the x86 fpu
core has more accuracy then the regular fpu core.
disables the dynamic x86 specific cpu core. Although it might be
be a bit unstable, it can greatly improve the speed of dosbox on x86
Please note that this option on x86 will result in a different
dynamic/recompiling cpu core being compiled then the default.
For more information see the option --disable-dynrec
disables the recompiling cpu core. Currently x86 and x86_64 only.
You can activate this core on x86 by disabling the dynamic-x86 core.
disables all dynamic cores. (same effect as
--disable-dynamic-x86 --disable-dynrec)
disables OpenGL-support (output mode that can be selected in the
DOSBox configuration file).
disables unaligned memory access.
Check the src subdir for the binary.
NOTE: If capslock and numlock appear to be broken. open
src/ints/bios_keyboard.cpp and go to line 30 and read there how to fix it.
Build instructions for VC++6
Don't use VC++ 6: it creates faulty code in core_normal.cpp
Later Visual Studio versions work fine (vs2003/.net, vs2005, vs2008)
# Main Makefile for DOSBox
SUBDIRS = src include docs visualc_net
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
We would like to thank:
Vlad R. of the vdmsound project for excellent sound blaster info.
Tatsuyuki Satoh of the Mame Team for making an excellent FM emulator.
Jarek Burczynski for the new OPL3 emulator.
Ken Silverman for his work on an OPL2 emulator.
The Bochs and DOSemu projects which I used for information.
FreeDOS for ideas in making my shell.
Pierre-Yves Gérardy for hosting the old Beta Board.
Colin Snover for hosting our forum.
Sourceforge for hosting our homepage and other development tools.
Mirek Luza, for his moderation of the forums.
eL_Pusher, DosFreak and MiniMax for their moderation of VOGONS forum.
crazyc, gulikoza, M-HT for their work on the dynrec core.
Jantien for the version management.
Shawn, Johannes and Marcus for creating the MAC OS X version.
Jochen for creating the OS/2 version.
Ido Beeri for the icon.
ripsaw8080 for his hard debugging work.
GOG Team for the splash screen.
All the people who submitted a bug.
The Beta Testers.
This diff is collapsed.
This diff is collapsed.
echo "Generating build information using aclocal, autoheader, automake and autoconf"
echo "This may take a while ..."
# Regenerate configuration files.
automake --include-deps --add-missing --copy
echo "Now you are ready to run ./configure."
echo "You can also run ./configure --help for extra features to enable/disable."
This diff is collapsed.
/* Generated from by autoheader. */
* Copyright (C) 2002-2010 The DOSBox Team
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* GNU Library General Public License for more details.
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
/* Define if building universal (internal helper macro) */
/* Compiling on BSD */
#undef BSD
/* Determines if the compilers supports always_inline attribute. */
/* Determines if the compilers supports fastcall attribute. */
/* Define to 1 to use inlined memory functions in cpu core */
/* Define to 1 to enable internal debugger, requires libcurses */
#undef C_DEBUG
/* Define to 1 if you want serial passthrough support (Win32, Posix and OS/2).
/* Define to 1 to use x86 dynamic cpu core */
#undef C_DYNAMIC_X86
/* Define to 1 to use recompiling cpu core. Can not be used together with the
dynamic-x86 core */
#undef C_DYNREC
/* Define to 1 to enable floating point emulation */
#undef C_FPU
/* Define to 1 to use a x86 assembly fpu core */
#undef C_FPU_X86
/* Determines if the compilers supports attributes for structures. */
/* Determines if the compilers supports __builtin_expect for branch
prediction. */
/* Define to 1 if you have the mprotect function */
/* Define to 1 to enable heavy debugging, also have to enable C_DEBUG */
/* Define to 1 to enable IPX over Internet networking, requires SDL_net */
#undef C_IPX
/* Define to 1 to enable internal modem support, requires SDL_net */
#undef C_MODEM
/* Define to 1 to use opengl display output support */
#undef C_OPENGL
/* Define to 1 to enable SDL_sound support */
#undef C_SDL_SOUND
/* Define to 1 if you have setpriority support */
/* Define to 1 to enable screenshots, requires libpng */
#undef C_SSHOT
/* The type of cpu this target has */
/* Define to 1 to use a unaligned memory access */
/* define to 1 if you have XKBlib.h and X11 lib */
#undef C_X11_XKB
/* libm doesn't include powf */
/* struct dirent has d_type */
/* environ can be included */
/* environ can be linked */
/* Define to 1 to use ALSA for MIDI */
#undef HAVE_ALSA
/* Define to 1 if you have the <ddraw.h> header file. */
/* Define to 1 if you have the <inttypes.h> header file. */
/* Define to 1 if you have the `asound' library (-lasound). */
/* Define to 1 if you have the <memory.h> header file. */
/* Define to 1 if you have the <netinet/in.h> header file. */
/* Define to 1 if you have the <pwd.h> header file. */
#undef HAVE_PWD_H
/* Define to 1 if you have the <stdint.h> header file. */
/* Define to 1 if you have the <stdlib.h> header file. */
/* Define to 1 if you have the <strings.h> header file. */
/* Define to 1 if you have the <string.h> header file. */
/* Define to 1 if you have the <sys/socket.h> header file. */
/* Define to 1 if you have the <sys/stat.h> header file. */
/* Define to 1 if you have the <sys/types.h> header file. */
/* Define to 1 if you have the <unistd.h> header file. */
/* Compiling on GNU/Linux */
#undef LINUX
/* Compiling on Mac OS X */
#undef MACOSX
/* Compiling on OS/2 EMX */
#undef OS2
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
/* Define to the full name of this package. */
/* Define to the full name and version of this package. */
/* Define to the one symbol short name of this package. */
/* Define to the home page for this package. */
/* Define to the version of this package. */
/* The size of `int *', as computed by sizeof. */
/* The size of `unsigned char', as computed by sizeof. */
/* The size of `unsigned int', as computed by sizeof. */
/* The size of `unsigned long', as computed by sizeof. */
/* The size of `unsigned long long', as computed by sizeof. */
/* The size of `unsigned short', as computed by sizeof. */
/* Define to 1 if you have the ANSI C header files. */
/* Define to 1 if your <sys/time.h> declares `struct tm'. */
/* Version number of package */
#undef VERSION
/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
significant byte first (like Motorola and SPARC, unlike Intel). */
# if defined __BIG_ENDIAN__
# endif
# endif
/* Define to empty if `const' does not conform to ANSI C. */
#undef const
/* Define to `__inline__' or `__inline' if that's what the C compiler
calls it, or to nothing if 'inline' is not supported under any name. */
#ifndef __cplusplus
#undef inline
/* Define to `unsigned int' if <sys/types.h> does not define. */
#undef size_t
/* Define to `int` if you don't have socklen_t */
#undef socklen_t
#define INLINE inline __attribute__((always_inline))
#define INLINE inline
#define DB_FASTCALL __attribute__((fastcall))
#define GCC_ATTRIBUTE(x) __attribute__ ((x))
#define GCC_ATTRIBUTE(x) /* attribute not supported */
#define GCC_UNLIKELY(x) __builtin_expect((x),0)
#define GCC_LIKELY(x) __builtin_expect((x),1)
#define GCC_UNLIKELY(x) (x)
#define GCC_LIKELY(x) (x)
typedef double Real64;
# error "sizeof (unsigned char) != 1"
typedef unsigned char Bit8u;
typedef signed char Bit8s;
# error "sizeof (unsigned short) != 2"
typedef unsigned short Bit16u;
typedef signed short Bit16s;
typedef unsigned int Bit32u;
typedef signed int Bit32s;
typedef unsigned long Bit32u;
typedef signed long Bit32s;
# error "can't find sizeof(type) of 4 bytes!"
typedef unsigned long Bit64u;
typedef signed long Bit64s;
typedef unsigned long long Bit64u;
typedef signed long long Bit64s;
# error "can't find data type of 8 bytes"
#if SIZEOF_INT_P == 4
typedef Bit32u Bitu;
typedef Bit32s Bits;
typedef Bit64u Bitu;
typedef Bit64s Bits;
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
# Main Makefile for DOSBox
man_MANS = dosbox.1
This diff is collapsed.
Some notes about porting DOSBox to systems with certain restrictions,
like handheld devices.
- depending on where you start off with the port, assure that the
config.h entries are correct/exhausting, like GCC_ATTRIBUTE is
required (struct packing) but is undefined if you base the port
on msvc sources which have a special config.h
If memory is a constraint:
- in paging.h out-comment the USE_FULL_TLB define to enable special
TLB linking code that uses less memory
drawback: none (the code is not heavily tested though)
gain: reduces memory requirements about ~15mb
- in render.h lower the scaler integration:
drawback: complex scalers and the scaler cache are disabled,
be sure to test if this affects speed!
with define RENDER_USE_ADVANCED_SCALERS==0 most simple
scalers are disabled as well, some graphics modes won't
work due to reduced cache sizes
- in dos_system.h reduce the drive cache entries:
#define MAX_OPENDIRS 256
drawback: some apps might not work with large directory trees
gain: ~1mb per mounted drive
- remove the GUS emulation (gus.cpp, especially GUSRam[1024*1024] )
drawback: no gravis ultrasound
gain: reduces memory requirements about 1mb
- reduce the size of the emulated graphics memory:
see the memory sizing in SVGA_Setup_*, especially the defaults
in vga_s3.cpp's SVGA_Setup_S3Trio
drawback: some graphics modes won't work then
gain: reduces memory requirements
TODO: fully check this, introduce hard limits
If speed is a constraint:
- see if the simple core is faster, possibly remove the normal core
set the simple core as default
drawback: one game is known to not work with the simple core;
the simple core does only work for games which don't use paging
(when paging is requested the normal core is used automatically)
gain: the simple core should be somewhat faster
TODO: add possibility to easily remove the normal core, use fullcore fallback
- raise the default frameskip value
drawback: minor graphics smoothness loss for some games (video playback)
gain: reduces graphics load
Starting with version 0.65, DOSBox allows you to create movies out of screen
To record a movie, you have to press CTRL-ALT-F5.
To stop/end the recording, you have to press CTRL-ALT-F5 again.
To play the recorded movie, you need a movie player which can handle the
ZMBV codec. MS Windows users can find this codec in the start menu entry of
DOSBox. Users of Linux and other OSes should look for a movie player that
uses the ffmpeg libary (you may need to update or ask your distribution to
Q: During the display of the movies the sound is lagging.
A: Check your display properties to see whether your refresh rate is set to
at least 70 hz. Try playing the movie in virtualdub (
Q: Why does the resulting movie consist of multiple files?
A: Each time the game changes resolution, DOSBox creates a new movie file,
because a movie file can only contain one resolution.
Q: Can I set the cycles higher than my PC can handle during recording?
A: Yes. During recording, the game might play slowly and stuttering, but the
resulting movie should play at the intended speed and have no stuttering.
Q: CTRL-ALT-F5 switches to the console under linux.
A: 1. Start DOSBox like this: dosbox -startmapper
2. Click on Video, click on Add
3. Press the key you want (for example scroll lock or printscreen)
4. Click exit.
5. You can make movies by pressing scroll lock or whichever key you
Q: The colours are wrong and I'm using 64 bit windows
A: Look here:
This diff is collapsed.
noinst_HEADERS = \
bios.h \
bios_disk.h \
callback.h \
cpu.h \
cross.h \
control.h \
debug.h \
dma.h \
dos_inc.h \
dos_system.h \
dosbox.h \
fpu.h \
hardware.h \
inout.h \
joystick.h \
ipx.h \
ipxserver.h \
keyboard.h \
logging.h \
mapper.h \
mem.h \
mixer.h \
modules.h \
mouse.h \
paging.h \
pic.h \
programs.h \
render.h \
regs.h \
render.h \
serialport.h \
setup.h \
shell.h \
support.h \
timer.h \
vga.h \
This diff is collapsed.
* Copyright (C) 2002-2010 The DOSBox Team