## ReadMe ## This is the Makefile to compile the AP MUX driver. ## 1. To compile for x86 platform( turn on both log and debug print output to /var/log/messages) ## make command: make PLATFORM=x86 ## 2. To compile for xscale platform ## (1) Neither log nor debug print output ## make command: make ## (2) Turn on log print output through ezxlog ## make command: make LOG=true ## (3) Turn on both log and debug print output through ezxlog ## make command: make DEBUG=true ## (4) Turn on log print output through printk(console) ## make command: make LOG=true PRINTK=true ## (5) Turn on both log and debug print output through printk(console) ## make command: make DEBUG=true PRINTK=true ## ## (6) Additional compile option: SEQ2=true ## compile option: SEQ2=true should only be used with BP MUX's corresponding compile option for another check sequence field ## (7) Additional compile option: SIG=true ## Compile option: SIG=true is used to send SIGUSR2 to aplogd when tapisrv is down. ## (8) Additional compile option: USB=true ## Compile option: USB=true is used to use MUX over USB. ## ##ifneq ($(USB),false) ## USB=true ##endif USB=false ifeq ($(PRODUCT),E680) USB=true endif ifeq ($(PRODUCT),E680I) USB=true endif ifeq ($(PRODUCT),A780) USB=true endif ##!!!!!!!! Turn on LOG for field test, should be removed after field test. ifneq ($(LOG),true) LOG=false endif PRINTK=true SIG=true ifeq ($(PLATFORM),x86) CFLAGS = gcc -D__KERNEL__ -I/usr/src/linux-2.4/include -I$(EZX_LINUX_BASE)/linux/linux-2.4.17/drivers/usb -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe -march=i686 -DMODULE -DMODVERSIONS -include /usr/src/linux-2.4/include/linux/modversions.h -DEXPORT_SYMTAB else CFLAGS = xscale_le-gcc -D__KERNEL__ -I$(EZX_LINUX_BASE)/linux/linux-2.4.17/include -I$(EZX_LINUX_BASE)/linux/linux-2.4.17/drivers/usb -I$(EZX_API_BASE)/aplog/aplogd -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -Uarm -fno-common -pipe -mapcs -mno-sched-prolog -mapcs-32 -D__LINUX_ARM_ARCH__=5 -mcpu=xscale -mtune=xscale -mshort-load-bytes -msoft-float -nostdinc -iwithprefix include -DKBUILD_BASENAME=mux_cli -DEXPORT_SYMTAB -DMODULE -DMODVERSIONS endif ifeq ($(PLATFORM),x86) CFLAGS += -DTS0710LOG -DTS0710DEBUG -DPRINT_OUTPUT_PRINTK else ifeq ($(DEBUG),true) CFLAGS += -DTS0710LOG -DTS0710DEBUG else ifeq ($(LOG),true) CFLAGS += -DTS0710LOG endif endif ifeq ($(PRINTK),true) CFLAGS += -DPRINT_OUTPUT_PRINTK endif endif ifeq ($(SEQ2),true) CFLAGS += -DTS0710SEQ2 endif ifneq ($(PLATFORM),x86) ifeq ($(SIG),true) CFLAGS += -DTS0710SIG endif endif ifeq ($(USB),true) CFLAGS += -DUSB_FOR_MUX endif all: ifneq ($(PLATFORM),x86) $(CFLAGS) -c mux_driver.c -o mux_cli.o endif clean: rm *.o -f