head	1.9;
access
	billh
	dalke;
symbols;
locks; strict;
comment	@# @;


1.9
date	94.09.25.22.41.06;	author billh;	state Exp;
branches;
next	1.8;

1.8
date	94.09.24.20.11.30;	author billh;	state Exp;
branches;
next	1.7;

1.7
date	94.09.23.00.52.28;	author billh;	state Exp;
branches;
next	1.6;

1.6
date	94.09.21.22.23.48;	author dalke;	state Exp;
branches;
next	1.5;

1.5
date	94.09.17.02.24.52;	author billh;	state Exp;
branches;
next	1.4;

1.4
date	94.09.14.03.52.08;	author billh;	state Exp;
branches;
next	1.3;

1.3
date	94.08.30.08.48.03;	author dalke;	state Exp;
branches;
next	1.2;

1.2
date	94.08.24.03.20.04;	author billh;	state Exp;
branches;
next	1.1;

1.1
date	94.08.24.03.10.37;	author billh;	state Exp;
branches;
next	;


desc
@@


1.9
log
@Updated due to more logical arrangement of library files, and to allow
for HPUX9 compilation.
@
text
@############################################################################
# RCS INFORMATION:
#
# 	$RCSfile: Makefile,v $
# 	$Author: billh $	$Locker: billh $		$State: Exp $
#	$Revision: 1.8 $	$Date: 1994/09/24 20:11:30 $
#
############################################################################
# DESCRIPTION:
#
# 			main Makefile
#		
############################################################################
# REVISION HISTORY:
#
# $Log: Makefile,v $
# Revision 1.8  1994/09/24  20:11:30  billh
# Put files for optional components in Makedata.options, and updated
# all make structure for this rearrangement.
#
# Revision 1.7  94/09/23  00:52:28  billh
# Put optional components in file 'Makedata.options'; added new files.
# 
# Revision 1.6  94/09/21  22:23:48  dalke
# added cavelib location
# 
# Revision 1.5  1994/09/17  02:24:52  billh
# Changed structure to provide 'optional components'.  Also changed
# names of library directories.
#
# Revision 1.4  94/09/14  03:52:08  billh
# Added '.IGNORE' target, to allow ci and co to skip over errors.
# 
# Revision 1.3  1994/08/30  08:48:03  dalke
# Added the UNC include and lib
#
# Revision 1.2  1994/08/24  03:20:04  billh
# Removed doc file references.
#
# Revision 1.1  1994/08/24  03:10:37  billh
# Initial revision
#
############################################################################

# machine to compile for
ARCH			= IRIX5

# name of executable
EXEC			= vmd

# current version of program
PROGVERSION		= 0.95

############################################################################
##################  no more configuration beyond this point  ###############
############################################################################

# makefile configuration
SHELL 			= /bin/sh
.SILENT:

#################################################################
# file which contains makefile dependencies (generated by make depend)
DEPENDFILE 		= Makedata.depend

# file which contains the listing of all source files
FILELIST		= Makedata.files

# file which contains the data for optional components
MAKEOPTIONS		= Makedata.options

# file with architecture-specific definitions
MAKEDATA		= Makedata.$(ARCH)

# where to put the object files
OBJDIR			= objfiles/$(ARCH)

# include makefile definitions, and optional component definitions
include $(MAKEDATA)
include $(MAKEOPTIONS)

# directories for object files, scripts, and different parts of code
SRCDIR 			= ../src
DOCDIR			= ../doc
PROTEINSDIR		= ../proteins
DATADIR			= ../data

# dirs for extra includes (except for OPTIONS, must have -I appended in front)
INCDIRS	= -I. $(OPTIONSINCDIRS) 

# dir for extra libs (except for OPTIONS, must have -l & -L appended in front)
LIBDIRS	= -L. $(OPTIONSLIBDIRS)
LIBS	= $(OPTIONSLIBS)

# compiler and linker options
CFLAGS	= $(ARCH_COPTS)	$(INCDIRS)	-DARCH_$(ARCH)	$(OPTIONSDEFS)
LFLAGS	= $(ARCH_LOPTS)	$(LIBDIRS) 	$(LIBS)

############################### 
# list of source files ...
############################### 
include $(FILELIST)

############################### 
# Makefiles and other useful files needed in src directory
###############################

MAKEFILE_FILES	= \
		Makefile \
		$(FILELIST) \
		$(MAKEOPTIONS) \
		Makedata.HPUX9 \
		Makedata.IRIX5

EXTRA_FILES	= \
		$(ALL_EXTRA)

############################### 
# default rules 
###############################

.C.o:
	$(ECHO) "Compiling " $< " --> " $*.o " ..."; \
	$(CCPP) $(CFLAGS) -c $(SRCDIR)/$<

.c.o:
	$(ECHO) "Compiling " $< " --> " $*.o " ..."; \
	$(CC) $(CFLAGS) -c $(SRCDIR)/$<

###############################
# main target rule
###############################

all default:	$(EXEC)

#### executables

$(EXEC): $(ALL_OBJS)
	$(ECHO) "Compiling and Linking " $@@ " ..."; \
	$(CCPP) $(CFLAGS) -o $@@ $(ALL_OBJS) $(LFLAGS)

#### etc.

version:
	$(ECHO) "Updating version.h ..."; \
	if [ -f $@@.h ]; then $(DELETE) $@@.h; fi; \
	$(ECHO) \#define VERSION_MSG \"$(EXEC) for $(ARCH), version $(PROGVERSION) \(`date`\)\" > version.h

#################################################################
# includes dependencies
include $(DEPENDFILE)

###############################
# other useful make commands
###############################

depend: version
	echo "Creating " $(DEPENDFILE) " ..."; \
	if [ -f $(DEPENDFILE) ]; \
	  then $(MOVE) -f $(DEPENDFILE) $(DEPENDFILE).old; \
	fi; \
	touch $(DEPENDFILE); \
	if [ "$(ALL_CCPP_SRCS) " != " " ]; \
	  then $(CCPP) -M $(INCDIRS) $(ALL_CCPP_SRCS) \
	    | grep -v "/usr/include" >> $(DEPENDFILE); \
	fi; \
	if [ "$(ALL_CC_SRCS) " != " " ]; \
	  then $(CC) -M $(INCDIRS) $(ALL_CC_SRCS) \
	    | grep -v "/usr/include" >> $(DEPENDFILE); \
	fi

### latex the documentation
doc:
	$(ECHO) "Creating documentation ..." ; \
	$(CD) $(DOCDIR); \
	latex $(MAIN_DOC_FILES)

### RCS checkout targets:

co.doc:
#	$(ECHO) "Checking out documentation files ..." ; \
#	$(CD) $(DOCDIR); \
#	$(COCMD) $(DOC_FILES)

co.make:
	$(ECHO) "Checking out Makefiles ..." ; \
	$(COCMD) $(MAKEFILE_FILES)

co.src:
	$(ECHO) "Checking out $(ALL_RUNSCRPTS) source files ..."; \
	$(CD) $(SRCDIR); \
	$(COCMD) $(ALL_SRCS)

co.h co.include co.header:
	$(ECHO) "Checking out $(ALL_RUNSCRPTS) include files ..."; \
	$(CD) $(SRCDIR); \
	$(COCMD) $(ALL_H)

co.extra:
	$(ECHO) "Checking out all other needed files ..." ; \
	if [ "$(EXTRA_FILES)" != "" ]; then \
	  $(CD) $(SRCDIR); \
	  $(COCMD) $(EXTRA_FILES); \
	fi

co:	co.make co.src co.h co.doc co.extra
	make depend

locks:
	$(ECHO) "Currently locked RCS files: " ; \
	$(CD) RCS; \
	if [ "`rlog -L -R *,v`" != "" ]; then \
	  ls -alF `rlog -L -R *,v`; \
	fi

### cleanup target

clean:
	$(DELETE) *.o *.a *.bak *.depend.old *~ core
@


1.8
log
@Put files for optional components in Makedata.options, and updated
all make structure for this rearrangement.
@
text
@d6 1
a6 1
#	$Revision: 1.7 $	$Date: 94/09/23 00:52:28 $
d16 5
a20 1
# $Log:	Makefile,v $
d96 2
a97 2
CFLAGS	= $(INCDIRS) 	$(ARCH_COPTS)	-DARCH_$(ARCH)	$(OPTIONSDEFS)
LFLAGS	= $(LIBDIRS) 	$(LIBS) 	$(ARCH_LOPTS)
@


1.7
log
@Put optional components in file 'Makedata.options'; added new files.
@
text
@d5 2
a6 2
# 	$Author: dalke $	$Locker: billh $		$State: Exp $
#	$Revision: 1.6 $	$Date: 94/09/21 22:23:48 $
d17 3
d134 1
a134 1
$(EXEC): $(VMD_OBJS)
d136 1
a136 1
	$(CCPP) $(CFLAGS) -o $@@ $(VMD_OBJS) $(LFLAGS)
@


1.6
log
@added cavelib location
@
text
@d5 2
a6 2
# 	$Author: billh $	$Locker:  $		$State: Exp $
#	$Revision: 1.5 $	$Date: 1994/09/17 02:24:52 $
d16 4
a19 1
# $Log: Makefile,v $
a46 65
############################  optional components  #########################
# For each optional component that should be included in the final executable,
# uncomment the items in the corresponding section below.  For some
# components there are is than one version of the set of items; only uncomment
# one set of items per optional component.

#######################
# OPTIONAL COMPONENT 1: GUI library to use.
#	Exactly one version of the following sets of items must be uncommented.
#	This specifies the libraries used for the on-screen GUI with buttons,
#	menus, etc.
#######################

# FORMS version
GUIDEF			= -DVMDFORMS
GUIDIR			= /usr/local/forms
GUIINCDIR		= -I$(GUIDIR)/include
GUILIBDIR		= -L$(GUIDIR)/lib_$(ARCH)
GUILIB			= -lforms

#######################
# OPTIONAL COMPONENT 2: UNC Tracker library support
#	This may be commented out if not required.
#	This allows the use of many different spatial trackers with the
#	library developed at U. of North Carolina.  Without it, non-CAVE
#	tracking is not allowed.
#######################

UNCDEF			= -DVMDUNC
UNCDIR			= ../lib/unc
UNCINCDIR		= -I$(UNCDIR)/include
UNCLIBDIR		= -L$(UNCDIR)/lib_$(ARCH)
UNCLIB			= -ltracker -lquat

#######################
# OPTIONAL COMPONENT 3: EVL/NCSA CAVE support
#	This may be commented out if not required.
#	This will require access to the cave library and headers, and will
#	result in unique CAVE objects being used in the program.
#	Uncomment EITHER the NORMAL, or SIMULATOR version, or neither
#######################

# NORMAL definitions for CAVE support
#VMDCAVEDEF		= -DVMDCAVE
#CAVEDIR		= ../../cave.2.2.3
#CAVEINCDIR		= -I$(CAVEDIR)/include
#CAVELIBDIR		= -L$(CAVEDIR)/lib
#CAVELIB		= -lcave

# SIMULATOR definitions for CAVE support
VMDCAVEDEF		= -DVMDCAVE
CAVEDIR			= ../../cave.2.2.3
CAVEINCDIR		= -I$(CAVEDIR)/include
CAVELIBDIR		= -L$(CAVEDIR)/lib
CAVELIB			= -lcavesim5

#######################
# end of optional component selection
#######################

OPTIONSDEFS		= $(GUIDEF)	$(UNCDEF)	$(CAVEDEF)
OPTIONSINCDIRS		= $(GUIINCDIR)	$(UNCINCDIR)	$(CAVEINCDIR)
OPTIONSLIBDIRS		= $(GUILIBDIR)	$(UNCLIBDIR)	$(CAVELIBDIR)
OPTIONSLIBS		= $(GUILIB)	$(UNCLIB)	$(CAVELIB)

d62 3
d71 1
a71 1
# include makefile definitions
d73 1
d103 2
a104 1
		Makedata.files \
@


1.5
log
@Changed structure to provide 'optional components'.  Also changed
names of library directories.
@
text
@d5 2
a6 2
# 	$Author: billh $	$Locker: billh $		$State: Exp $
#	$Revision: 1.4 $	$Date: 94/09/14 03:52:08 $
d16 5
a20 1
# $Log:	Makefile,v $
d88 1
a88 1
#CAVEDIR		= unknown
d91 1
a91 1
#CAVELIB		= unknown
d94 5
a98 5
#VMDCAVEDEF		= -DVMDCAVE
#CAVEDIR		= unknown
#CAVEINCDIR		= -I$(CAVEDIR)/include
#CAVELIBDIR		= -L$(CAVEDIR)/lib
#CAVELIB		= unknown
@


1.4
log
@Added '.IGNORE' target, to allow ci and co to skip over errors.
@
text
@d5 2
a6 2
# 	$Author: dalke $	$Locker: billh $		$State: Exp $
#	$Revision: 1.3 $	$Date: 1994/08/30 08:48:03 $
d16 4
a19 1
# $Log: Makefile,v $
d40 13
a52 1
# directory with GUI libraries
d54 5
a58 3
GUIINCDIR		= /usr/local/forms/include
GUILIBDIR		= /usr/local/forms/lib
GUILIB			= forms
d60 7
a66 6
# directory with tracker libraries
UNCINCDIR		= ../lib/unc/include
UNCLIBDIR		= ../lib/unc/lib_os5
UNCLIB			= tracker
UNCQUATLIB		= quat
##################  no more configuration beyond this line  ################
d68 41
a111 1
.IGNORE:
d135 2
a136 2
# directories for extra includes (must have -I appended in front)
INCDIRS	= -I. -I$(GUIINCDIR) -I$(UNCINCDIR)
d138 3
a140 3
# directories for extra libraries (must have -l and -L appended in front)
LIBDIRS	= -L. -L$(GUILIBDIR) -L$(UNCLIBDIR)
LIBS	= -l$(GUILIB) -l$(UNCLIB) -l$(UNCQUATLIB)
d143 1
a143 1
CFLAGS	= $(INCDIRS) 	$(ARCH_COPTS)	-DARCH_$(ARCH)	
@


1.3
log
@Added the UNC include and lib
@
text
@d5 2
a6 2
# 	$Author: billh $	$Locker: dalke $		$State: Exp $
#	$Revision: 1.2 $	$Date: 1994/08/24 03:20:04 $
d17 3
d53 1
@


1.2
log
@Removed doc file references.
@
text
@d5 2
a6 2
# 	$Author: billh $	$Locker: billh $		$State: Exp $
#	$Revision: 1.1 $	$Date: 1994/08/24 03:10:37 $
d17 3
d40 5
d74 1
a74 1
INCDIRS	= -I. -I$(GUIINCDIR)
d77 2
a78 2
LIBDIRS	= -L. -L$(GUILIBDIR)
LIBS	= -l$(GUILIB)
@


1.1
log
@Initial revision
@
text
@d5 2
a6 2
# 	$Author: billh $	$Locker:  $		$State: Exp $
#	$Revision: 1.4 $	$Date: 94/06/29 17:41:52 $
d16 4
a19 1
# $Log$
d157 3
a159 3
	$(ECHO) "Checking out documentation files ..." ; \
	$(CD) $(DOCDIR); \
	$(COCMD) $(DOC_FILES)
d175 1
a175 1
co.other co.extra:
d182 1
a182 1
co:	co.make co.src co.h co.doc co.other
@
