#*******************************************************************************
#
# University of Western Australia
# Department of Computer Science
# Copyright (c) University of Western Australia
#
# SYSTEM :              VIP
# RELEASE:		3
# SUBSYSTEM:            LIB
# MODULE:		lib Makefile		
# REVISION:             3.2
# AUTHOR:		CFF
# CREATION DATE:	16 August 1993
# REVISION DATE:	9/15/93
#
#*******************************************************************************
#
# REVISION LOG
#
# REVISION:		3.4
# DATE:			19 April 1994
# BY:			PK
# COMMENT:		Added more comments.
#
# REVISION:		3.3
# DATE:			7 April 1994
# BY:			BJR
# COMMENT:		Changed makefile to use environment variables
#			VIP_MACHINE and VIP_LIB_DIR
#			This makefile can be used for all unix builds.
#
# REVISION:		3.2
# DATE:			15 Sept 1993
# BY:			CFF
#
# REVISION:		3.1
# DATE:			16 August 1993
# BY:			CFF
#
# @(#)makefile.sun	3.2 9/15/93
#
#***************************************************************************/

# Section that you will need to edit for your own installation of VIP

# The main variables that you will have to set are:
# VIP_DIR
# VIP_MACHINE
# VIP_LIB_DIR

# We set VIP_MACHINE and VIP_LIB_DIR via environment variables to 
# automatically invoke the correct compilation depending on the 
# type of machine one is logged into.  If you are working on just 
# one architecture you may not wish to do this, nor will you need
# to have separate library subdirectories.

# REQUIRED ENVIRONMENT VARIABLES:

# VIP_MACHINE	SUN or DEC_ALPHA or LINUX
# VIP_LIB_DIR	sunlib or declib or linuxlib

# ========== libraries and headers ==========

VIP_DIR    = /home/decadence/staff/pk/vip
VISIONLIB  = $(VIP_DIR)/lib/libvip.a
INCLUDE    = -I$(VIP_DIR)/include  -I${OPENWINHOME}/include

LIBPATH   = -L$(LIB_DIR)

# Flags and Options

CC	= gcc
fla	= -O -Wall
#fla	= -g
CFLAGS  = $(INCLUDE) $(fla) -D$(VIP_MACHINE)
LDFLAGS = -lm

# Note that if you are not compiling in a Sun environment you may
# wish to comment out the object file rast.o from the list below
# as your machine may not have the Sun rasterfile headers needed.
# This only affects the programs vip2raster and raster2vip.

OBJECTS = \
	mapcolor.o \
	math.o \
	misc.o \
	oldvip.o \
	pm.o \
	ppmrgb.o \
	vector.o \
	vipcomplex.o \
	vipfreq.o \
	vipglobals.o \
	vipio.o \
	vipspat.o \
	vipcalib.o \
        vip1D.o \
        rast.o 



# ========== Building rules for Makefile ==========

$(VISIONLIB): $(OBJECTS)
	ar rv $(VISIONLIB) $(OBJECTS)
	ranlib $(VISIONLIB)
	chmod 664 $(VISIONLIB)
	chmod 664 $(OBJECTS)

clean :
	rm $(OBJECTS)




