#!/bin/sh

#
#	fabrication d'un makefile general Grif a partir d'un fichier Imakefile
#
#	usage:   
#	makemake	sans argument, genere un CommonMake simple
#	makemake	+ 1 argument qcq, genere un CommonMake avec dependances
#

mv CommonMake CommonMake.bak
if [ "`uname`" = "Linux" ]
then
    imake -DUseInstalled -I/usr/X11R6/lib/X11/config -s CommonMake
else
    imake -DUseInstalled -s CommonMake
fi
if [ $# -gt 0 ]
then
	(cd ../bin/SUN4;
	../../util/makedepend_src/makedepend -Z -f ../../makes/CommonMake \
	-I ../../include/h -I ../../include/f \
	-I ../../include/var -I ../.. \
	../../absimg/*.c ../../appli/*.c \
	../../base/*.c ../../compil/*.c \
	../../concimg/*.c ../../elemdocs/*.c \
	../../except/*.c ../../graphicsext/*.c \
	../../corr/*.c ../../index/*.c \
	../../physimg/*.c ../../schpiv/*.c ../../xtlkit/*.c \
	../../tools/*.c ../../graphicsext/bitmap/*.c \
	../../graphicsext/epsf/*.c ../../graphicsext/gif/*.c	 
	../../graphicsext/pixmap/*.c)
fi

