# This Makefile is for making source code for a PC from source code
# for linux. It should be removed from NistDmisTestSuite2.0 before
# the Test Suite is distributed.

# The editing for isatty varies; this may be because of slightly
# different output from Sun and linux. Another form is:
# "/isatty/s/isatty( fileno(file) )/1/"

pcSource : 
	sed -e /hh/s/hh/h/g\
             linuxSun/source/debnf2pars.lex > windows/source/debnf2pars.lex
	sed -e /asses.hh/s/hh/h/\
             linuxSun/source/debnf2pars.y > windows/source/debnf2pars.y
	sed -e /hh/s/hh/h/g\
            -e /\<unistd.h\>/d\
            -e "/isatty/s/file ? (isatty( fileno(file) ) > 0) : 0/0/"\
            linuxSun/source/debnf2parsLex.cc > windows/source/debnf2parsLex.cpp
	sed /hh/s/hh/h/\
            linuxSun/source/debnf2parsYACC.cc > \
            windows/source/debnf2parsYACC.cpp
	cp linuxSun/source/debnf2parsYACC.hh \
            windows/source/debnf2parsYACC.h
	sed /hh/s/hh/h/\
            linuxSun/source/ebnfClasses.cc > windows/source/ebnfClasses.cpp
	cp linuxSun/source/ebnfClasses.hh windows/source/ebnfClasses.h
	cp linuxSun/source/generateMore.cc windows/source/generateMore.cpp
