# Micro-X - X server for DOS
# Copyright (C) 1993 StarNet Communications Corp.
#
# 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
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU 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.
# 
# StarNet Communications Corp.
# 550 Lakeside Dr. #3
# Sunnyvale CA 94086 US
# http://www.starnet.com
# x-dos@starnet.com

.SUFFIXES: .drv

MFLAGS=/MX /T

all:    data.exe \
        aheadb.drv ati3.drv ati4.drv everex.drv genoa.drv \
	headland.drv stdvga.drv trident0.drv trident1.drv \
	tseng3.drv tseng4.drv vesa.drv vesa2.drv wdc00.drv wdc1a.drv

aheadb.drv: aheadb.exe
aheadb.exe: aheadb.obj
aheadb.obj: aheadb.asm ccopy2.asm
ati3.drv: ati3.exe
ati3.exe: ati3.obj
ati3.obj: ati3.asm ccopy1.asm
ati4.drv: ati4.exe
ati4.exe: ati4.obj
ati4.obj: ati4.asm ccopy1.asm
everex.drv: everex.exe
everex.exe: everex.obj
everex.obj: everex.asm ccopy1.asm
genoa.drv: genoa.exe
genoa.exe: genoa.obj
genoa.obj: genoa.asm ccopy2.asm
headland.drv: headland.exe
headland.exe: headland.obj
headland.obj: headland.asm ccopy1.asm
oak.drv: oak.exe
oak.exe: oak.obj
oak.obj: oak.asm ccopy2.asm
tseng3.drv: tseng3.exe
tseng3.exe: tseng3.obj
tseng3.obj: tseng3.asm ccopy2.asm
tseng4.drv: tseng4.exe
tseng4.exe: tseng4.obj
tseng4.obj: tseng4.asm ccopy2.asm
trident0.drv: trident0.exe
trident0.exe: trident0.obj
trident0.obj: trident0.asm ccopy1.asm
trident1.drv: trident1.exe
trident1.exe: trident1.obj
trident1.obj: trident1.asm ccopy1.asm
stdvga.drv: stdvga.exe
stdvga.exe: stdvga.obj
stdvga.obj: stdvga.asm
vesa.drv: vesa.exe
vesa.exe: vesa.obj
vesa.obj: vesa.asm vesacopy.asm
vesa2.drv: vesa2.exe
vesa2.exe: vesa2.obj
vesa2.obj: vesa2.asm vesacopy.asm
wdc00.drv: wdc00.exe
wdc00.exe: wdc00.obj
wdc00.obj: wdc00.asm ccopy1.asm
wdc1a.drv: wdc1a.exe
wdc1a.exe: wdc1a.obj
wdc1a.obj: wdc1a.asm ccopy1.asm

.asm.obj:
	data.exe > date.asm
	masm $(MFLAGS) $*,$*,$*;

.obj.exe: 
	link $*;

.exe.drv: 
	exe2bin $*.exe $*.drv
	-del $<

data.exe: data.c
	cl /AL /c data.c
	link $* ;
clean:
	rm *.obj
	rm *.drv
	rm *.exe
	rm *.lst
