summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/drivers/emudummy.cpp
blob: 948be2f2987b4a99a43fc709a3f8d9b8b93feedf (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// license:BSD-3-Clause
// copyright-holders:Aaron Giles
/***************************************************************************

    emudummy.c

    Dummy driver file that references CPU devices which are in turn
    referenced by devices in libemu.a.

    The reason we need this is due to link ordering issues with gcc
    if the actual drivers being linked don't reference these CPU
    devices. Since we link libcpu first, if libemu needs stuff from
    libcpu that wasn't previously referenced, it will fail the link.

***************************************************************************/

#include "emu.h"
#include "cpu/mcs48/mcs48.h"
#include "cpu/z80/z80.h"


MACHINE_CONFIG_START( __dummy, driver_device )
	MCFG_CPU_ADD("dummy1", I8049, 1000000)
	MCFG_CPU_ADD("dummy2", I8748, 1000000)
	MCFG_CPU_ADD("dummy3", Z80, 1000000)
MACHINE_CONFIG_END


ROM_START( __dummy )
	ROM_REGION( 0x1000, "dummy1", ROMREGION_ERASEFF )
	ROM_REGION( 0x1000, "dummy2", ROMREGION_ERASEFF )
	ROM_REGION( 0x1000, "dummy3", ROMREGION_ERASEFF )
ROM_END


GAME( 1900, __dummy, 0, __dummy, 0, driver_device, 0, ROT0, "(none)", "Dummy", MACHINE_NO_SOUND )
.avail_in = (uInt)sourceLen; #ifdef MAXSEG_64K /* Check for source > 64K on 16-bit machine: */ if ((uLong)stream.avail_in != sourceLen) return Z_BUF_ERROR; #endif stream.next_out = dest; stream.avail_out = (uInt)*destLen; if ((uLong)stream.avail_out != *destLen) return Z_BUF_ERROR; stream.zalloc = (alloc_func)0; stream.zfree = (free_func)0; stream.opaque = (voidpf)0; err = deflateInit(&stream, level); if (err != Z_OK) return err; err = deflate(&stream, Z_FINISH); if (err != Z_STREAM_END) { deflateEnd(&stream); return err == Z_OK ? Z_BUF_ERROR : err; } *destLen = stream.total_out; err = deflateEnd(&stream); return err; } /* =========================================================================== */ int ZEXPORT compress (dest, destLen, source, sourceLen) Bytef *dest; uLongf *destLen; const Bytef *source; uLong sourceLen; { return compress2(dest, destLen, source, sourceLen, Z_DEFAULT_COMPRESSION); } /* =========================================================================== If the default memLevel or windowBits for deflateInit() is changed, then this function needs to be updated. */ uLong ZEXPORT compressBound (sourceLen) uLong sourceLen; { return sourceLen + (sourceLen >> 12) + (sourceLen >> 14) + (sourceLen >> 25) + 13; }