# # Makefile for the GoAhead web server reference source base # for the Linux OS # # Copyright (c) GoAhead Software, Inc. 1995-2000 # # $Id: Makefile,v 1.2 2002/11/01 16:20:19 mmitchell Exp $ # all: compile TOPDIR=../../.. APP_DIR=$(TOPDIR)/application ARCH = libwebs.a ../../boottable/boottable.a ../../mib/mib.a ../../spidlib/spidlib.a NAME = webs # User Management switch UMSW = -DUSER_MANAGEMENT_SUPPORT # Digest Access switch #DASW = -DDIGEST_ACCESS_SUPPORT # # SSL switches # #You must uncomment this line to enable SSL #SSLPATCHFILE = ../websSSL.o # # Then uncomment these three lines if you are using the RSAREF library # and set them to the correct path. # # SSLINC = /RSASSL/library/include # SSLLIB = /RSASSL/library/lib/libsslc.a # SSLSW = -DWEBS_SSL_SUPPORT -I$(SSLINC) # # Or alternatively, # # Uncomment these three lines if you are using the OpenSSL library. # Change the value of SSLINC to the path where your OpenSSL header # files reside, and change the value of SSLLIB to the path to your # OpenSSL libssl.a and libcrypto.a. # #SSLINC = $(TOPDIR)/application/openssl/include/ #SSLLIB = $(TOPDIR)/application/openssl/libssl.a $(TOPDIR)/application/openssl/libcrypto.a #SSLSW = -DWEBS_SSL_SUPPORT -I$(SSLINC) -DOPENSSL # If-Modified-Support switches (requires math library, libm.a) # IFMODSW = -DWEBS_IF_MODIFIED_SUPPORT # IFMODLIB = /usr/lib/libm.a INCLUDE = -I$(APP_DIR)/mib/inc -I$(TOPDIR)/include -I$(TOPDIR)/include/plc-drv -I$(TOPDIR)/linux-2.6.10/include -I$(APP_DIR)/spidlib/inc -I$(APP_DIR)/boottable/inc -I$(INCDIR) -I$(APP_DIR)/agent/inc # Dependencies DEPEND_FILES = ./spidcom_functions.o ../asp.o ../balloc.o ../base64.o ../cgi.o ../default.o \ ../ejlex.o ../ejparse.o ../form.o \ ../h.o ../handler.o ../mime.o ../misc.o ../page.o \ ../ringq.o ../rom.o \ ../sock.o ../sockGen.o $(SSLPATCHFILE) \ ../security.o ../sym.o ../uemf.o ../url.o ../value.o \ ../md5c.o ../um.o ../umui.o ../websda.o ../emfdb.o \ ../webrom.o ../webs.o ../websuemf.o main.o EXTRA_CFLAGS = $(INCLUDE) -DWEBS -DUEMF -DOS="LINUX" -DLINUX $(DASW) $(UMSW) $(SSLSW) $(IFMODSW) $(HPSW) EXTRA_LDFLAGS = $(SSLLIB) $(IFMODLIB) -L$(APP_DIR)/openssl -lcrypto -lpthread ifeq ($(FROM_BUILDROOT),) CC = arm-uclinux-gcc AR = arm-uclinux-ar EXTRA_CFLAGS += -msoft-float -march=armv5 -mtune=arm926ejs EXTRA_LDFLAGS += -msoft-float -march=armv5 -Wl,-elf2flt='-s4k' endif compile: $(NAME) # # Build archive of objects # $(ARCH): $(DEPEND_FILES) $(AR) $(ARFLAGS) $(ARCH) $? # # Primary link # $(NAME): Makefile $(ARCH) $(CC) -o $(NAME) \ $(CFLAGS) $(EXTRA_CFLAGS) $(IFLAGS) \ main.o $(ARCH) $(LDFLAGS) $(EXTRA_LDFLAGS) #$(DEBUG) \ clean: rm -f $(NAME) $(DEPEND_FILES) rm -f $(NAME).gdb rm -f libwebs.a # $(ARCH) # # Dependencies # ./spidcom_functions.o: ./spidcom_functions.c ../wsIntrn.h ../webs.h ../ej.h ../ejIntrn.h ../uemf.h ../asp.o: ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../balloc.o: ../balloc.c ../uemf.h ../base64.o: ../base64.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../cgi.o: ../webs.h ../wsIntrn.h ../uemf.h ../default.o: ../default.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../ejlex.o: ../ejlex.c ../ej.h ../ejIntrn.h ../uemf.h ../ejparse.o: ../ejparse.c ../ej.h ../ejIntrn.h ../uemf.h ../emfdb.o: ../emfdb.h ../wsIntrn.h ../uemf.h ../form.o: ../form.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../h.o: ../h.c ../uemf.h ../handler.o: ../handler.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../md5c.o: ../md5.h ../wsIntrn.h ../uemf.h ../mime.o: ../mime.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../misc.o: ../misc.c ../uemf.h ../page.o: ../page.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../ringq.o: ../ringq.c ../uemf.h ../rom.o: ../rom.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../security.o: ../security.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../sock.o: ../sock.c ../uemf.h ../sockGen.o: ../sockGen.c ../uemf.h ../sym.o: ../sym.c ../uemf.h ../uemf.o: ../uemf.c ../uemf.h ../um.o: ../webs.h ../wsIntrn.h ../um.h ../uemf.h ../umui.o: ../webs.h ../wsIntrn.h ../um.h ../uemf.h ../url.o: ../url.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../value.o: ../value.c ../uemf.h ../webrom.o: ../webrom.c ../webs.h ../wsIntrn.h ../uemf.h ../webs.o: ../webs.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../websda.o: ../webs.h ../wsIntrn.h ../websda.h ../uemf.h ../websuemf.o: ../websuemf.c ../webs.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h ../websSSL.o: ../websSSL.c ../websSSL.h ../wsIntrn.h ../ej.h ../ejIntrn.h ../uemf.h main.o: main.c ../wsIntrn.h ../webs.h ../ej.h ../ejIntrn.h ../uemf.h # # Transition rules (add -o to put object in right directory) # .c.o: $(CC) -c $(DEBUG) $(CFLAGS) $(EXTRA_CFLAGS) $(IFLAGS) -o $@ $<