summaryrefslogtreecommitdiffstats
path: root/drivers/misc/Makefile
blob: 1137f6e80ccc2c2f83d35cb751565aa45d7f2632 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#
# Makefile for the kernel miscellaneous drivers.
#
# Note! Dependencies are done automagically by 'make dep', which also
# removes any old dependencies. DON'T put your own dependencies here
# unless it's something special (ie not a .c file).
#
# Note 2! The CFLAGS definitions are now inherited from the
# parent makes..

SUB_DIRS     := 
MOD_SUB_DIRS := $(SUB_DIRS)
ALL_SUB_DIRS := $(SUB_DIRS)

L_TARGET := misc.a
MX_OBJS  :=
LX_OBJS  := 
MI_OBJS  :=
MIX_OBJS :=

ifeq ($(CONFIG_PARPORT),y)
  L_OBJS += parport_share.o parport_ieee1284.o
  ifeq ($(CONFIG_PROC_FS),y)
    L_OBJS += parport_procfs.o
  endif
  ifeq ($(CONFIG_PARPORT_PC),y)
    LX_OBJS += parport_pc.o
  else
    ifeq ($(CONFIG_PARPORT_PC),m)
      M_OBJS += parport_pc.o
    endif
  endif
  ifeq ($(CONFIG_PARPORT_AX),y)
    LX_OBJS += parport_ax.o
  else
    ifeq ($(CONFIG_PARPORT_AX),m)
      M_OBJS += parport_ax.o
    endif
  endif
  LX_OBJS += parport_init.o
else
  ifeq ($(CONFIG_PARPORT),m)
    MI_OBJS += parport_share.o parport_ieee1284.o
    ifneq ($(CONFIG_PROC_FS),n) 
      MI_OBJS += parport_procfs.o
    endif
    MIX_OBJS += parport_init.o
    M_OBJS += parport.o
  endif
  ifeq ($(CONFIG_PARPORT_PC),m)
    MX_OBJS += parport_pc.o
  endif
  ifeq ($(CONFIG_PARPORT_AX),m)
    MX_OBJS += parport_ax.o
  endif
endif

include $(TOPDIR)/Rules.make

# Special rule to build the composite parport.o module
parport.o: $(MI_OBJS) $(MIX_OBJS)
	$(LD) $(LD_RFLAG) -r -o $@ $(MI_OBJS) $(MIX_OBJS)