#
# file:     Imakefile
# author:   Wes Barris
# date:     4/22/92
# purpose:  Imakefile for Desi application
#
# copyright info:
#
#    @Copyright 1992
#    Research Equipment Inc. dba Minnesota Supercomputer Center
#
# RESTRICTED RIGHTS LEGEND
#
# Use, duplication, or disclosure of this software and its documentation
# by the Government is subject to restrictions as set forth in subdivision
# { (b) (3) (ii) } of the Rights in Technical Data and Computer Software
# clause at 52.227-7013.
#
#include "Motif.tmpl"

              TARGET = desi
               CLASS = Desi
             SUBDIRS = Umsc SelfM Image
                  CC = cc
                 PSW = pswrap
         CDEBUGFLAGS = -g
#if OSMajorVersion <= 4
           CCOPTIONS = -prototypes -float -fullwarn -woff 2
#else
           CCOPTIONS = -prototypes -float -fullwarn
#endif
            INCLUDES = -I.
       PROTO_DEFINES = -DFUNCPROTO -DNARROWPROTO
      DESI_LIBRARIES = -LSelfM -lSe -LUmsc -lLlist -LImage -lfastimg
        GL_LIBRARIES = -lXirisw -ldps -limage -lgl_s -lm
     MOTIF_LIBRARIES = $(XMLIB) $(XMPLIB) $(XMULIB)
     LOCAL_LIBRARIES = $(DESI_LIBRARIES) $(GL_LIBRARIES) $(MOTIF_LIBRARIES)
             LCOPTS1 = -cckr -Wf,-XNf15000 -Wf,-XNd15000 -Wf,-XNp15000 -c -I/usr/include/DPS
             LCOPTS2 = $(CDEBUGFLAGS) -c

SRCS	= \
	about.c \
	alignMenu.c \
	back.c \
	bboard.c \
	centerMenu.c \
	cmapObject.c \
	colorMenu.c \
	cursors.c \
	decPanel.c \
	editMenu.c \
	fileMenu.c \
	fontMenu.c \
	glcallbacks.c \
	grid.c \
	imageObject.c \
	icon.c \
	justifyMenu.c \
	main.c \
	menuBar.c \
	objectMenu.c \
	PSutils.c \
	prefMenu.c \
	record.c \
	sizeMenu.c \
	spaceMenu.c \
	styleMenu.c \
	textMenu.c \
	textObject.c \
	viewMenu.c \
	windowOps.c

OBJS	= $(SRCS:.c=.o) stringutils.o

# $(OBJS)    : $(TARGET).h proto.h
# main.o     : fallback.h
fallback.h : $(CLASS).ad
	./mkfallback < $(CLASS).ad > fallback.h

stringutils.o: stringutils.psw
	$(PSW) -o stringutils.c stringutils.psw
	$(CC) $(LCOPTS1) stringutils.c

PSutils.o: PSutils.c
	$(CC) $(LCOPTS2) PSutils.c

#makefiles::
#	for i in $(SUBDIRS);\
#	do \
#		echo "making Makefile in $$i..."; \
#		cd $(PWD)/$$i; xmkmf; \
#	done
libs::
	for i in $(SUBDIRS);\
	do \
		echo "making in $$i..."; \
		cd $(PWD)/$$i; make; \
	done

MakefileSubdirs($(SUBDIRS))
NormalProgramTarget($(TARGET), $(OBJS), , $(LOCAL_LIBRARIES), $(SYSLIBS) )
AllTarget($(TARGET))
DependTarget()
