#		%Z% %M% %I% %D% %T%
#
#
# ロードモジュール名

SRC	= .
OBJ	= .
INCLUDE	= .

LOAD = /home/cms/exe/wsubform

CC	= gcc

# for Debug
#CFLAGS	= -ggdb -I../../curlib01

CFLAGS	= -O2 -g

LDEXE	= ./

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

wsubformHTML.o : wsubformHTML.c wsubformHTML.h
	$(CC) $(CFLAGS) -c wsubformHTML.c
	ar -rv libsubformHTML.a wsubformHTML.o

curlibHTML :
	$(CC) $(CFLAGS) -c curlibHTML.c


inputwin : inputwin.pgc wsubformHTML.c
	ecpg inputwin.pgc
	gcc -I/usr/local/pgsql/include -c inputwin.c
	gcc -O2 -static -o inputwin.cgi inputwin.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

inputwin2 : inputwin2.pgc wsubformHTML.c
	ecpg inputwin2.pgc
	gcc -I/usr/local/pgsql/include -c inputwin2.c
	gcc -O2 -static -o inputwin2.cgi inputwin2.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

kokyaku : kokyaku.pgc wsubformHTML.c
	ecpg kokyaku.pgc
	gcc -I/usr/local/pgsql/include -c kokyaku.c
	gcc -O2 -static -o kokyaku.cgi kokyaku.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

kokyaku_Fetch : kokyaku_Insert.pgc wsubformHTML.c
	ecpg kokyaku_Fetch.pgc
	gcc -I/usr/local/pgsql/include -c kokyaku_Fetch.c
	gcc -O2 -static -o kokyaku_Fetch.cgi kokyaku_Fetch.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

kokyaku_Insert : kokyaku_Insert.pgc wsubformHTML.c
	ecpg kokyaku_Insert.pgc
	gcc -I/usr/local/pgsql/include -c kokyaku_Insert.c
	gcc -O2 -static -o kokyaku_Insert.cgi kokyaku_Insert.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

kokyaku_Update : kokyaku_Update.pgc wsubformHTML.c
	ecpg kokyaku_Update.pgc
	gcc -I/usr/local/pgsql/include -c kokyaku_Update.c
	gcc -O2 -static -o kokyaku_Update.cgi kokyaku_Update.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

kokyaku_Delete : kokyaku_Delete.pgc wsubformHTML.c
	ecpg kokyaku_Delete.pgc
	gcc -I/usr/local/pgsql/include -c kokyaku_Delete.c
	gcc -O2 -static -o kokyaku_Delete.cgi kokyaku_Delete.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

yubin : yubin.pgc wsubformHTML.c
	ecpg yubin.pgc
	gcc -I/usr/local/pgsql/include -c yubin.c
	gcc -O2 -static -o yubin.fcgi yubin.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm -lfcgi

yubin_Fetch : yubin_Fetch.pgc wsubformHTML.c
	ecpg yubin_Fetch.pgc
	gcc -I/usr/local/pgsql/include -c yubin_Fetch.c
	gcc -O2 -static -o yubin_Fetch.cgi yubin_Fetch.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

yubin_Insert : yubin_Insert.pgc wsubformHTML.c
	ecpg yubin_Insert.pgc
	gcc -I/usr/local/pgsql/include -c yubin_Insert.c
	gcc -O2 -static -o yubin_Insert.cgi yubin_Insert.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

yubin_Update : yubin_Update.pgc wsubformHTML.c
	ecpg yubin_Update.pgc
	gcc -I/usr/local/pgsql/include -c yubin_Update.c
	gcc -O2 -static -o yubin_Update.cgi yubin_Update.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

yubin_Delete : yubin_Delete.pgc wsubformHTML.c
	ecpg yubin_Delete.pgc
	gcc -I/usr/local/pgsql/include -c yubin_Delete.c
	gcc -O2 -static -o yubin_Delete.cgi yubin_Delete.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

yubin_all : yubin_all.pgc wsubformHTML.c
	ecpg yubin_all.pgc
	gcc -I/usr/local/pgsql/include -c yubin_all.c
	gcc -O2 -static -o yubin_all.cgi yubin_all.o libsubformHTML.a -L/usr/local/pgsql/lib -lecpg -lpq -lpgtypes -lm

