#pragma ident "@(#) makefile 2.0.4 2009.07.17,21:33"
# cw.mk
#		%Z% %M% %I% %D% %T%
#
#
# ロードモジュール名
TARGET	= cf
OFILES  = $(OBJ)/cmsfiler.o

SRC	= .
OBJ	= .
INCLUDE	= ../../ftx

LOAD = /home/cms/bin

CPP	= g++
CC	= gcc

# for Debug
#CFLAGS	= -g -X a -Wno-deprecated $(INC_OPT)

# for Release (-xcg92: use SPARC Version8 instructions.)
CPPFLAGS	= -O3
CFLAGS	= -ggdb -O3 -LANG=UTF-8

LDEXE	= ./

LINTFLAGS = -x $(INC_OPT) $(CDEFS)

$(LDEXE)/$(TARGET) : $(OFILES) ../../ftx/libftx.a
	$(CPP) $(CPPFLAGS) $(OFILES) -o $@ ../../ftx/libftx.a -lncursesw

$(OBJ)/cmsfiler.o : $(SRC)/cmsfiler.cc $(INCLUDE)/ftx.h $(INCLUDE)/filer.h ../../ftx/libftx.a
	$(CPP) -c $(CPPFLAGS) -o $@ $(SRC)/cmsfiler.cc

#cmsfiler: cmsfiler.c
#	gcc -I../libsubform -c cmsfiler.c
#	gcc -O -o cmsfiler cmsfiler.o ../libsubform/libsubform.a -lncursesw 

lint:	;
	lint $(LINTFLAGS) $(SRC)/userdisp.c

clean	:
	-rm -f $(OFILES) $(TARGET)

install	:
	cp -p $(LDEXE)cw $(LOAD)
