9668dce936ef96e4e924c54c89062b8dee84c624
[packages/base.git] / Makefile.nhc98
1 THISPKG = base
2 SEARCH  = -I$(TOPDIR)/targets/$(MACHINE)
3
4 DIRS    = $(shell ${LOCAL}pkgdirlist ${THISPKG})
5
6 SRCS    = \
7         Data/Bits.hs Data/Bool.hs Data/Char.hs Data/Complex.hs \
8         Data/Either.hs Data/FiniteMap.hs Data/IORef.hs Data/Int.hs \
9         Data/Ix.hs Data/List.hs Data/Maybe.hs Data/PackedString.hs \
10         Data/Ratio.hs Data/Set.hs Data/Tuple.hs Data/Word.hs Data/Array.hs \
11         Data/HashTable.hs Data/Typeable.hs Data/Dynamic.hs \
12         Data/Monoid.hs Data/Tree.hs \
13         Control/Monad.hs Control/Monad/Fix.hs Control/Monad/Trans.hs \
14         Control/Arrow.hs Debug/Trace.hs \
15         NHC/SizedTypes.hs \
16         System/IO.hs System/IO/Error.hs System/IO/Unsafe.hs \
17         System/Environment.hs System/Exit.hs System/Locale.hs \
18         System/Directory.hs System/Mem.hs System/Cmd.hs System/Info.hs \
19         System/Console/GetOpt.hs System/Random.hs \
20         Foreign/Ptr.hs Foreign/StablePtr.hs Foreign/Storable.hs \
21         Foreign/ForeignPtr.hs Foreign/C/Types.hs \
22         Foreign/Marshal/Alloc.hs Foreign/Marshal/Array.hs \
23         Foreign/Marshal/Utils.hs Foreign/Marshal/Error.hs \
24         Foreign/Marshal/Pool.hs Foreign/Marshal.hs \
25         Foreign/C/String.hs Foreign/C/Error.hs Foreign/C.hs Foreign.hs \
26         Text/PrettyPrint/HughesPJ.hs Text/PrettyPrint.hs \
27         Text/Html/BlockTable.hs Text/Html.hs \
28         Text/Read.hs Text/Show.hs Text/Show/Functions.hs
29
30 #       [Data/Dynamic.hs] Data/Generics.hs Data/STRef.hs Data/Unique.hs
31 #       Control/Monad/Identity.hs
32 #       Debug/QuickCheck.hs
33 #       System/CPUTime.hsc System/Time.hsc
34 #       System/Mem.hs System/Mem/StableName.hs System/Mem/Weak.hs
35 #       System/Posix/Types.hs System/Posix/Signals.hsc
36 #       Text/ParserCombinators/ReadP.hs Text/ParserCombinators/ReadPrec.hs
37 #       Text/Read/Lex.hs
38 #       Text/Regex/* Text/Regex.hs
39
40
41 # Here are the main rules.
42 include ../Makefile.common
43
44 # some extra rules
45 NHC/SizedTypes.hs: NHC/SizedTypes.hs.cpp
46         $(CC) -E $< >$@
47
48 # Here are the dependencies.
49 $(OBJDIR)/Data/FiniteMap.$O: $(OBJDIR)/Data/Maybe.$O
50 $(OBJDIR)/Data/Set.$O: $(OBJDIR)/Data/Maybe.$O $(OBJDIR)/Data/FiniteMap.$O
51 $(OBJDIR)/Data/Array.$O: $(OBJDIR)/Data/Ix.$O
52 $(OBJDIR)/Data/Dynamic.$O: $(OBJDIR)/Data/HashTable.$O \
53         $(OBJDIR)/Data/Typeable.$O
54 $(OBJDIR)/Data/HashTable.$O: $(OBJDIR)/Control/Monad.$O
55 $(OBJDIR)/Data/Int.$O: $(OBJDIR)/NHC/SizedTypes.$O
56 $(OBJDIR)/Data/Word.$O: $(OBJDIR)/NHC/SizedTypes.$O
57 $(OBJDIR)/NHC/SizedTypes.$O: $(OBJDIR)/Data/Bits.$O
58 $(OBJDIR)/System/IO.$O: $(OBJDIR)/System/IO/Error.$O
59 $(OBJDIR)/System/Random.$O: $(OBJDIR)/Data/Char.$O $(OBJDIR)/Data/IORef.$O \
60         $(OBJDIR)/System/IO/Unsafe.$O
61 $(OBJDIR)/Debug/Trace.$O: $(OBJDIR)/System/IO.$O $(OBJDIR)/System/IO/Unsafe.$O
62 $(OBJDIR)/Control/Monad/Fix.$O: $(OBJDIR)/System/IO.$O
63 $(OBJDIR)/Control/Monad/Identity.$O: $(OBJDIR)/Control/Monad.$O \
64         $(OBJDIR)/Control/Monad/Fix.$O
65 $(OBJDIR)/Foreign/Marshal/Alloc.$O:  $(OBJDIR)/Data/Maybe.$O \
66         $(OBJDIR)/Foreign/Ptr.$O $(OBJDIR)/Foreign/Storable.$O \
67         $(OBJDIR)/Foreign/C/Types.$O
68 $(OBJDIR)/Foreign/Marshal/Array.$O:  $(OBJDIR)/Control/Monad.$O \
69         $(OBJDIR)/Foreign/Ptr.$O $(OBJDIR)/Foreign/Storable.$O \
70         $(OBJDIR)/Foreign/Marshal/Alloc.$O $(OBJDIR)/Foreign/Marshal/Utils.$O
71 $(OBJDIR)/Foreign/Marshal/Utils.$O:  $(OBJDIR)/Data/Maybe.$O \
72         $(OBJDIR)/Foreign/Ptr.$O $(OBJDIR)/Foreign/Storable.$O \
73         $(OBJDIR)/Foreign/Marshal/Alloc.$O $(OBJDIR)/Foreign/C/Types.$O
74 $(OBJDIR)/Foreign/Marshal/Error.$O: $(OBJDIR)/Foreign/Ptr.$O
75 $(OBJDIR)/Foreign/C/String.$O: $(OBJDIR)/Data/Word.$O $(OBJDIR)/Foreign/Ptr.$O \
76         $(OBJDIR)/Foreign/Marshal/Array.$O $(OBJDIR)/Foreign/C/Types.$O 
77
78 # C-files dependencies.
79 Data/FiniteMap.$C: Data/Maybe.$C
80 Data/Set.$C:       Data/Maybe.$C Data/FiniteMap.$C
81 Data/Array.$C:     Data/Ix.$C
82 Data/Dynamic.$C:   Data/HashTable.$C Data/Typeable.$C
83 Data/HashTable.$C: Control/Monad.$C
84 Data/Int.$C:       NHC/SizedTypes.$C
85 Data/Word.$C:      NHC/SizedTypes.$C
86 NHC/SizedTypes.$C: Data/Bits.$C
87 System/IO.$C:      System/IO/Error.$C
88 System/Random.$C:  Data/Char.$C Data/IORef.$C System/IO/Unsafe.$C
89 Debug/Trace.$C:    System/IO.$C System/IO/Unsafe.$C
90 Control/Monad/Fix.$C:      System/IO.$C
91 Control/Monad/Identity.$C: Control/Monad.$C Control/Monad/Fix.$C
92 Control/Monad/Trans.$C:    System/IO.$C
93 Foreign/Marshal/Alloc.$C:  Data/Maybe.$C Foreign/Ptr.$C Foreign/Storable.$C \
94         Foreign/C/Types.$C
95 Foreign/Marshal/Array.$C:  Control/Monad.$C Foreign/Ptr.$C Foreign/Storable.$C \
96         Foreign/Marshal/Alloc.$C Foreign/Marshal/Utils.$C
97 Foreign/Marshal/Utils.$C:  Data/Maybe.$C Foreign/Ptr.$C Foreign/Storable.$C \
98         Foreign/C/Types.$C Foreign/Marshal/Alloc.$C
99 Foreign/Marshal/Error.$C:  Foreign/Ptr.$C
100 Foreign/C/String.$C:       Data/Word.$C Foreign/Ptr.$C Foreign/C/Types.$C \
101         Foreign/Marshal/Array.$C
102