summaryrefslogtreecommitdiff
path: root/emulators/bochs/Makefile
blob: 7b952d915aad66b4445d1a37dfee0daf766dba79 (plain)
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# $NetBSD: Makefile,v 1.26 2003/02/07 04:00:33 fredb Exp $

DISTNAME=		bochs-2.0.2
CATEGORIES=		emulators
MASTER_SITES=		${MASTER_SITE_SOURCEFORGE:=bochs/}

MAINTAINER=		packages@netbsd.org
HOMEPAGE=		http://bochs.sourceforge.net/
COMMENT=		i386 machine emulator capable of running DOS/Windows

GNU_CONFIGURE=		yes
USE_GMAKE=		yes
# These options are not enabled by default because they can adversely impact
# performance. The number of processors can be either 1 (default), 2, or 4.
#CONFIGURE_ARGS+=	--enable-debugger --enable-disasm
#CONFIGURE_ARGS+=	--enable-processors=2
CONFIGURE_ARGS+=	--enable-cdrom
CONFIGURE_ARGS+=	--enable-ne2000
CONFIGURE_ARGS+=	--enable-sb16=dummy
CONFIGURE_ENV+=		CXXFLAGS="-I${X11BASE}/include ${CXXFLAGS}"
USE_X11=		yes

BOCHS_MAINDIR=		${PREFIX}/share/bochs
BOCHS_BIOSDIR=		${BOCHS_MAINDIR}/bios
BOCHS_FONTDIR=		${BOCHS_MAINDIR}/xfonts
BOCHS_DOCDIR=		${PREFIX}/share/doc/html/bochs
MESSAGE_SUBST+=		BOCHS_MAINDIR=${BOCHS_MAINDIR} \
			BOCHS_FONTDIR=${BOCHS_FONTDIR} \
			BOCHS_DOCDIR=${BOCHS_DOCDIR}

post-configure:
	${SED} -e 's@XXXPREFIXXXX@${PREFIX}@' \
		< ${WRKSRC}/.bochsrc > ${WRKSRC}/bochsrc

do-install:
	${INSTALL_DATA_DIR} ${BOCHS_BIOSDIR}
	${INSTALL_DATA} ${WRKSRC}/bios/BIOS-bochs-2-processors ${BOCHS_BIOSDIR}
	${INSTALL_DATA} ${WRKSRC}/bios/BIOS-bochs-4-processors ${BOCHS_BIOSDIR}
	${INSTALL_DATA} ${WRKSRC}/bios/BIOS-bochs-8-processors ${BOCHS_BIOSDIR}
	${INSTALL_DATA} ${WRKSRC}/bios/BIOS-bochs-latest ${BOCHS_BIOSDIR}
	${INSTALL_DATA} ${WRKSRC}/bios/VGABIOS-elpin-2.40 ${BOCHS_BIOSDIR}
	${INSTALL_DATA} ${WRKSRC}/bios/VGABIOS-elpin-LICENSE ${BOCHS_BIOSDIR}
	${INSTALL_DATA} ${WRKSRC}/bios/VGABIOS-lgpl-latest ${BOCHS_BIOSDIR}
	${INSTALL_DATA} ${WRKSRC}/bios/VGABIOS-lgpl-README ${BOCHS_BIOSDIR}
	${INSTALL_DATA_DIR} ${BOCHS_DOCDIR}
	${INSTALL_DATA} ${WRKSRC}/docs-html/00README ${BOCHS_DOCDIR}
	${INSTALL_DATA} ${WRKSRC}/docs-html/*.gif ${BOCHS_DOCDIR}
	${INSTALL_DATA} ${WRKSRC}/docs-html/*.html ${BOCHS_DOCDIR}
	${INSTALL_DATA} ${WRKSRC}/docs-html/*.txt ${BOCHS_DOCDIR}
	${INSTALL_DATA_DIR} ${BOCHS_FONTDIR}
	${INSTALL_DATA} ${WRKSRC}/font/hercules.bdf ${BOCHS_FONTDIR}
	${INSTALL_DATA} ${WRKSRC}/font/vga.bdf ${BOCHS_FONTDIR}
	${INSTALL_DATA} ${WRKSRC}/font/vga.pcf ${BOCHS_FONTDIR}
	${INSTALL_PROGRAM} ${WRKSRC}/bochs ${PREFIX}/bin
	${INSTALL_PROGRAM} ${WRKSRC}/bximage ${PREFIX}/bin
	${INSTALL_DATA} ${WRKSRC}/bochsrc ${PREFIX}/share/bochs
	${INSTALL_MAN} ${WRKSRC}/doc/man/*.1 ${PREFIX}/man/man1
	${INSTALL_MAN} ${WRKSRC}/doc/man/*.5 ${PREFIX}/man/man5
	${X11BASE}/bin/mkfontdir ${PREFIX}/share/bochs/xfonts

.include "../../mk/bsd.pkg.mk"