#
# This software is part of the Digital Fortran kit.
# Copyright (C) 1993,1997 Digital Equipment Corporation.
# All rights reserved.
#
# This software is furnished to you under a license by  Digital Equipment
# Corporation and must be used only in  accordance with the terms and conditions
# of that license,  and only with the inclusion of the above copyright notice.
#
# This software is provided as an example that demonstrates a particular
# feature/function of the licensed product. The software is not intended to
# provide a complete solution to any application problem but rather is provided
# as a teaching mechanism.
#
# Users may incorporate any part of this sample into their own source after 
# making appropriate changes to make it suitable for the intended application.
#
# This makefile builds CHAREXMP.EXE from CHAR.FOR using fsplit.
#

# Nmake macros for building Digital Fortran applications

!include <dfinc.mak>

objs = reverse.obj findsubs.obj

all: charexmp.exe

# Use fsplit to break CHAR.FOR into CHAREXMP.FOR, FINDSUBS.FOR and
# REVERSE.FOR
#
charexmp.for: char.for
    fsplit90 char.for

charexmp.exe: charexmp.for reverse.for findsubs.for charlib.lib
    $(FOR) $(fflags) charexmp.for /link $(lflags) charlib.lib

charlib.lib:  $(objs)
    $(libr) $(objs) /out:charlib.lib

reverse.obj:  reverse.for char.for
    $(FOR) $(fflags) reverse.for /c
		
findsubs.obj: findsubs.for char.for
    $(FOR) $(fflags) findsubs.for /c

run:
     call charexmp.exe

clean:
    -del charexmp.exe
    -del reverse.obj
    -del findsubs.obj
    -del charlib.lib
    -del charexmp.for
    -del reverse.for
    -del findsubs.for
