Jak upravit Makefile
Michal Sviga
dama na centrum.cz
Úterý Prosinec 3 11:51:00 CET 2002
Mam zdrojovy kod ovladace Fasttrak.
V readme pisou, ze si mam upravit makefile dle meho systemu.
Mam Rh 8.0 a netusim co s tim.
Prikladam dodany makefile.
#
# Makefile for the Promise FastTrak Series device drivers.
# Promise Linux support team <support na promise.com.tw>
# Be ware to choose right parameters for your system.
# last modify: 2002/11/06
CC = gcc
LD = ld
#if ARM cross-compiler
#CC = arm-linux-gcc
#LD = arm-linux-ld
#most common case
INDEP386= -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i586 -DMODULE
#most common case including kernel version
DEP386 = -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i586 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h
#for SuSE, Turbolinux
SuSE_TB = -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe -mpreferred-stack-boundary=2 -march=i586 -DMODULE
#for Mandrake Linux
MDK = -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-common -fno-strict-aliasing -pipe -mpreferred-stack-boundary=2 -march=i586 -fno-merge-constants -DMODULE
#for kernel version 2.2.x SMP
#for kernel version 2.2.x UP, please remove -D__SMP__
SMP22x = -D__KERNEL__ -D__SMP__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe -fno-strength-reduce -march=i386 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h
ARM = -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -pipe -DCPU=arm -DMODULE
FT = wrapper.o fasttrak.o ftlog.o
.SUFFIXES: .c.o
###########################################
#choose a parameter for your system.
#default is INDEP386
.c.o: ; $(CC) $(INDEP386) -c $*.c
#.c.o: ; $(CC) $(DEP386) -c $*.c
#.c.o: ; $(CC) $(SuSE_TB) -c $*.c
#.c.o: ; $(CC) $(MDK) -c $*.c
#.c.o: ; $(CC) $(SMP22x) -c $*.c
#.c.o: ; $(CC) $(ARM) -c $*.c
###########################################
all : $(FT)
$(LD) -r -o FastTrak.o $(FT) ftlib.o ; rm -f fasttrak.o
clean :
rm -f FastTrak.o $(FT)
--
--
S pozdavem
Michal Sviga
e-mail: m na dama.cz
ICQ: 151650399
Další informace o konferenci Linux