#/*
# * Bernoulli Compiler
# * Copyright (c) Cornell University
# * Department of Computer Science
# * 
# * Kamen Yotov (kamen@yotov.org)
# * 
# * $Source: C:/CVS/kyotov/kyotov/Research/BC/makefile,v $
# * $Revision: 1.12 $
# * $Date: 2003/02/23 18:30:01 $
# *
# * Revision 1.6  2002/07/21 10:45:44  kyotov
# * First version with check-in messages!
# */

!INCLUDE "makefile.mak"

time:
	time.exe "nmake build"

build: $(D)\Omega.dll $(D)\OmegaLIB.dll $(D)\XTensions.dll $(D)\BC.Core.ASTs.dll $(D)\BC.Core.Passes.dll $(D)\BC.Core.dll $(D)\BC.C.dll $(D)\BCC.exe $(D)\BXC.exe $(D)\XmlSignature.exe

!INCLUDE "copy.mak"
	
count:
	del count.data
	dir /s /b *.cs *.xml *.xsd makefile. *.mak *.txt > files.lst
	filter ".*" "@echo {0} & string+ \"string {0} \" >> count.data & filter \"^^(?!^^\s*({{^|}}\s*)\s*$$).*$$\" \"{{0}}\" /c < {0} > nul 2>> count.data" < files.lst > run.bat
	run.bat
	del files.lst run.bat
	
cleanall:
	pushd ASTs & nmake /NOLOGO clean & popd
	pushd Core & nmake /NOLOGO clean & popd
	pushd C & nmake /NOLOGO clean & popd
	pushd BCC & nmake /NOLOGO clean & popd
	pushd X & nmake /NOLOGO clean & popd
	pushd XmlSignature & nmake /NOLOGO clean & popd
	dir /s /b /ad debug*.* release*.* | $(FILTER) ".*" "@rd /s /q {0}" > clean.bat
	dir /s /b /ad bin*.* obj*.* | $(FILTER) ".*" "@rd {0}" >> clean.bat
	clean.bat
	del clean.bat
	del *.ncb
	attrib -H *.suo
	del *.suo

check:
	check C\Samples\issues1
	check C\Samples
