# -*- Makefile -*-

#------------------------------------------------------------------
# Makefile template for generating Makefiles with Perl utility
# makemake.pl
#------------------------------------------------------------------

# Top Directory of CODAS installation:
top_dir  = ../../../..

# Library directories. Index 1 and 2 are used for those binaries using
# original and GFI libraries.
lib_dir  =
lib_dir1 = $(top_dir)/lib/$(HOST)
lib_dir2 = $(top_dir)/gfi/lib/$(HOST)

# Directory for installing the binary:
bin_dir  = $(top_dir)/gfi/bin/$(HOST)

# Additionnal include directories:
inc_dir  =

# The target is determined from the content of the MMFile:
target   = bin

# Definition below are those found in the MMFile for the specified
# keyword.
src      =
obj      = no_obj
srcs     = con2db.c 
objs     = $(lib_dir1)/main_cnt.o con2db.o 
lib      = $(lib_dir)/no_lib
libs     = $(lib_dir2)/gfidb.a $(lib_dir2)/gfimisc.a $(lib_dir1)/use_db.a $(lib_dir1)/dbsource.a $(lib_dir1)/ioserv.a 
bin      = $(bin_dir)/con2db 
bins     =

#------------------------------------------------------------------

include $(top_dir)/makefile.dep
include $(top_dir)/gfi/make/$(HOST)/makefile.dep

#------------------------------------------------------------------

all: $(target)

bin: $(bin)

lib: $(lib)

obj: $(obj)

lclint:
	$(LCLINT) $(DFLAGS) $(INCLUDES) $(LCLFLAGS) $(src) $(srcs)

#------------------------------------------------------------------

$(bin): $(objs) $(libs)
	$(CCLINK) -o $@ $(objs) $(libs) $(LDLIBS)
	$(CHMOD) $(BIN_PERMISSION) $@

$(lib): $(objs)
	$(AR)     $@ $(objs)
	$(RANLIB) $@
	$(CHMOD) $(LIB_PERMISSION)  $@

#------------------------------------------------------------------

con2db.o: con2db.c con2db.h ../../../../include/geninc.h \
 ../../../../include/dbhost.h ../../../../include/common.h \
 ../../../../include/dbext.h ../../../../include/dbdcl.h \
 ../../../../include/mem_.h ../../../../include/unscale.h \
 ../../../../include/time_.h ../../../../include/sort.h \
 ../../../../include/scale.h ../../../../include/prtstruc.h \
 ../../../../include/prtarray.h ../../../../include/prtspecl.h \
 ../../../../include/posn.h ../../../../include/misc.h \
 ../../../../include/io_nc.h ../../../../include/io_.h \
 ../../../../include/find_def.h ../../../../include/mc0.h \
 ../../../../include/data_lst.h ../../../../include/data_id.h \
 ../../../../include/ioserv.h \
 ../../../../include/../gfi/src/plugs/ioserv.h \
 ../../../../include/dbsource.h ../../../../include/use_db.h \
 ../../../../include/pos_to_m.h ../../../../gfi/include/gfimisc.h \
 ../../../../gfi/include/../src/libs/misc/msg.h \
 ../../../../gfi/include/../src/libs/misc/pos.h \
 ../../../../gfi/include/gficnv.h \
 ../../../../gfi/include/../src/libs/misc/file.h \
 ../../../../gfi/include/../src/libs/misc/convert.h \
 ../../../../gfi/include/../src/libs/misc/io.h \
 ../../../../gfi/include/../src/libs/misc/misc.h \
 ../../../../gfi/include/../src/libs/misc/string.h \
 ../../../../gfi/include/../src/libs/misc/time.h \
 ../../../../gfi/include/../src/libs/misc/xoption.h \
 ../../../../gfi/include/gfidb.h \
 ../../../../gfi/include/../src/libs/db/access.h \
 ../../../../include/dbglo.h ../../../../include/dbinc.h \
 ../../../../gfi/include/../src/libs/db/manip.h \
 ../../../../gfi/include/../src/libs/db/xtract.h




