remove empty dir
[ghc-hetmet.git] / rts / dotnet / Makefile
1 #
2 # .NET interop for GHC.
3 #
4 #  (c) 2003, sof.
5
6 TOP=../..
7 include $(TOP)/mk/boilerplate.mk
8
9 all :: Invoker.dll Invoke.o
10
11 #
12 # To compile the dotnet interop bits, you need to have the
13 # .NET Framework SDK or VS.NET installed. The following
14 # apps are used:
15
16 MCPP=cl
17 TLBEXP=tlbexp
18 REGASM=regasm
19 GACUTIL=gacutil
20
21 Invoker.dll : Invoker.obj 
22         $(MCPP) /LD /clr /o Invoker.dll Invoker.obj
23         $(TLBEXP) Invoker.dll
24         $(REGASM) Invoker.dll
25         $(GACUTIL) /i Invoker.dll
26
27 Invoker.obj : Invoker.cpp Invoker.h
28         $(MCPP) /LD /clr /c Invoker.cpp
29
30 CLEAN_FILES += $(wildcard *.obj *.dll *.tlb)
31
32 # ToDo: 
33 #   - switch to /ir (i.e., copy it into the GAC.)
34 #   - sort out installation story.
35
36 # drop the assembly
37 remove : 
38         $(GACUTIL) /u Invoker
39
40 #
41 # NOTE: For DotnetCc a version of gcc later than gcc-2.95 is
42 #       required (I'm using the gcc-3.2 snapshot that comes with mingw-2)
43 #
44 ifeq "$(DotnetCc)" ""
45 DotnetCc=$(CC)
46 endif
47 DotnetCcOpts=$(CC_OPTS) $(DOTNET_EXTRA_CC_OPTS)
48 SRC_CC_OPTS += -I$(TOP)/includes
49
50 Invoke.o : Invoke.c 
51         $(DotnetCc) $(DotnetCcOpts) -c $< -o $@ 
52
53 include $(TOP)/mk/target.mk